3D blood vessel visualization method and device based on shape coding hybrid rendering
Through hybrid rendering technology based on shape coding, blood vessel shape and intensity information are used to distinguish vascular and non-vascular structures, and express tissue and organ contour information, solving the problems of structural resolution and information balance in the existing technology, and achieving high-quality 3D blood vessels. Visualization and interactive frame rates.
Patent Information
- Application Number
- CN202210184149.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-24
- Publication Date
- 2024-08-27
- Estimated Expiration
- 2042-02-24
AI Technical Summary
Existing 3D blood vessel visualization technology has difficulty distinguishing different structures with similar intensity ranges, and it is difficult to balance vascular structure and non-vascular structure information, resulting in poor visualization quality.
A hybrid rendering method based on shape encoding is used to define 2D feature space encoding opacity optical attributes through blood vessel shape information and intensity information, combined with the GPU ray casting algorithm to distinguish blood vessels and non-vascular structures in blood vessel direct volume rendering, and through the local gradient vector and The sight direction angle analysis expresses the contour information of tissues and organs, and the rendering results are fused to highlight the vascular structure and lesion information of interest.
It effectively highlights the blood vessel structure in 3D images, while expressing tissue and organ information around blood vessels, clearly conveying complex spatial relationships, and supporting interactive frame rate 3D blood vessel visualization.
Smart Images

Figure CN114581579B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of medical image processing, and in particular to a 3D blood vessel visualization method based on shape coding hybrid rendering, and a 3D blood vessel visualization device based on shape coding hybrid rendering. Background Art
[0002] Some blood vessels have different structures with similar intensity ranges, so they are difficult to distinguish, which leads to poor quality of 3D blood vessel visualization based on direct volume rendering. In addition, the information of various tissues and organs around blood vessels is conducive to the analysis and interpretation of the overall structure of blood vessels, while the current 3D blood vessel visualization technology has the problem of how to balance the information of vascular structure and non-vascular structure. Summary of the invention
[0003] In order to overcome the defects of the prior art, the technical problem to be solved by the present invention is to provide a 3D blood vessel visualization method based on shape coding hybrid rendering, which can effectively express the tissue and organ information around the blood vessels without interfering with the blood vessel visualization while highlighting the blood vessel structure of interest in the 3D image, clearly convey the complex spatial relationship in the 3D angiography image, and support 3D blood vessel visualization with interactive frame rate.
[0004] The technical solution of the present invention is: the 3D blood vessel visualization method based on shape coding hybrid rendering comprises the following steps:
[0005] (1) The opacity optical properties are encoded in the 2D feature space defined by the vascular shape information and the intensity information, and a 2D transfer function based on the vascular shape features and the intensity features is constructed. The GPU ray casting algorithm is used to effectively distinguish the vascular and non-vascular structures in the vascular direct volume rendering, realize the classification of multiple tissue structures, and emphasize the vascular structures of interest in the vascular direct volume rendering.
[0006] (2) By analyzing the relationship between the local gradient vector and the angle of the sight direction, the contour information of the tissues and organs around the blood vessels in the 3D angiography image is expressed in the non-photorealistic rendering, the unnecessary details in the 3D angiography image are reduced, and the contour features of the tissues and organs around the blood vessels are enhanced;
[0007] (3) Based on the vascular shape information, the rendering results of realistic rendering and direct volume rendering are fused to highlight the vascular structure and lesion information of interest in the hybrid rendering results, and to improve the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels;
[0008] In step (3), a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering:
[0009]
[0010] Where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values.
[0011] The present invention firstly utilizes the 2D feature space defined by the vascular shape information and the intensity information to encode the opacity optical property, realizes the classification of multiple tissue structures, and emphasizes the vascular structure of interest in the direct vascular volume rendering; secondly, by analyzing the relationship between the local gradient vector and the sight direction angle, the contour information of the tissues and organs around the blood vessels in the 3D angiography image is expressed in the non-realistic rendering, and unnecessary detail information is removed; finally, based on the vascular shape information, the rendering results of the realistic rendering and the direct volume rendering are fused, so as to highlight the vascular structure and lesion information of interest in the hybrid rendering result, and enhance the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels; therefore, while highlighting the vascular structure of interest in the 3D image, the tissue and organ information around the blood vessels that does not interfere with the vascular visualization is effectively expressed, the complex spatial relationship in the 3D angiography image is clearly conveyed, and the 3D vascular visualization with interactive frame rate is supported.
[0012] A 3D blood vessel visualization device based on shape coding hybrid rendering is also provided, which includes:
[0013] A vascular direct volume rendering module, which is configured to encode opacity optical properties using a 2D feature space defined by vascular shape information and intensity information, construct a 2D transfer function based on vascular shape features and intensity features, and achieve effective distinction between vascular and non-vascular structures in vascular direct volume rendering based on a GPU ray casting algorithm, achieve multi-tissue structure classification, and emphasize vascular structures of interest in vascular direct volume rendering;
[0014] A blood vessel non-realistic rendering module is configured to express the contour information of tissues and organs around blood vessels in 3D angiography images in non-realistic rendering by analyzing the relationship between local gradient vectors and the angle of sight direction, thereby reducing unnecessary details in 3D angiography images and enhancing the contour features of tissues and organs around blood vessels;
[0015] A fusion module configured to fuse the rendering results of photorealistic rendering and direct volume rendering based on the vascular shape information, thereby highlighting the vascular structure and lesion information of interest in the hybrid rendering result and improving the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels;
[0016] In the fusion module, a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering:
[0017]
[0018] Where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 It is a structural schematic diagram of a 3D blood vessel visualization method based on shape coding hybrid rendering according to the present invention.
[0020] Figure 2 Figure 2 is a transfer function design diagram. (a) Transfer function based on intensity, (b) Transfer function based on blood vessel shape information.
[0021] Figure 3 It is a GPU ray casting blood vessel direct volume rendering flowchart.
[0022] Figure 4 The gradient calculation and the relationship between the gradient direction and the view direction are shown. (a) 3×3×3 gradient operator for gradient calculation based on linear regression, (b) the relationship between the gradient direction and the view direction in the volume data. DETAILED DESCRIPTION
[0023] like Figure 1 As shown, the 3D blood vessel visualization method based on shape coding hybrid rendering includes the following steps:
[0024] (1) The opacity optical properties are encoded in the 2D feature space defined by the vascular shape information and the intensity information, and a 2D transfer function based on the vascular shape features and the intensity features is constructed. The GPU ray casting algorithm is used to effectively distinguish the vascular and non-vascular structures in the vascular direct volume rendering, realize the classification of multiple tissue structures, and emphasize the vascular structures of interest in the vascular direct volume rendering.
[0025] (2) By analyzing the relationship between the local gradient vector and the angle of the sight direction, the contour information of the tissues and organs around the blood vessels in the 3D angiography image is expressed in the non-photorealistic rendering, the unnecessary details in the 3D angiography image are reduced, and the contour features of the tissues and organs around the blood vessels are enhanced;
[0026] (3) Based on the vascular shape information, the rendering results of realistic rendering and direct volume rendering are fused to highlight the vascular structure and lesion information of interest in the hybrid rendering results, and to improve the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels;
[0027] In step (3), a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering:
[0028]
[0029] Where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values.
[0030] The present invention firstly utilizes the 2D feature space defined by the vascular shape information and the intensity information to encode the opacity optical property, realizes the classification of multiple tissue structures, and emphasizes the vascular structure of interest in the direct vascular volume rendering; secondly, by analyzing the relationship between the local gradient vector and the sight direction angle, the contour information of the tissues and organs around the blood vessels in the 3D angiography image is expressed in the non-realistic rendering, and unnecessary detail information is removed; finally, based on the vascular shape information, the rendering results of the realistic rendering and the direct volume rendering are fused, so as to highlight the vascular structure and lesion information of interest in the hybrid rendering result, and enhance the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels; therefore, while highlighting the vascular structure of interest in the 3D image, the tissue and organ information around the blood vessels that does not interfere with the vascular visualization is effectively expressed, the complex spatial relationship in the 3D angiography image is clearly conveyed, and the 3D vascular visualization with interactive frame rate is supported.
[0031] The 3D blood vessel visualization method of the present invention is completed by modifying the core steps of the GPU ray casting volume rendering algorithm. By tracing rays passing through the volume data in the GPU fragment shader, hybrid rendering based on shape coding is realized. The pseudo code of this method is shown in Table 1.
[0032] Table 1
[0033]
[0034] Preferably, in step (1), for any point X, the 2D transfer function based on the blood vessel shape feature and the intensity feature is:
[0035]
[0036] in, is the standard intensity transfer function, It is a transfer function based on the blood vessel shape information.
[0037] The distinction between vascular structures and non-vascular structures can be achieved by analyzing the relationship between the eigenvalues of the Hessian matrix at each point in the angiography image. In addition, the Gaussian scale space of the image is often used to analyze and detect vascular structures of different scales. The function f(X) represents the intensity distribution function of the 3D image, X = [x, y, z] T When the scale is s, the 3×3 Hessian matrix of f(X) at point X can be expressed as:
[0038]
[0039] Where G(X,s)=(2πs 2 ) -3 / 2 exp(-X T X / 2s2 ) represents a 3D Gaussian function, and * represents convolution. Each X can be decomposed by eigenvalue eig H(X,s) to obtain the eigenvalues of the Hessian matrix, which are λ1, λ2, and λ3. The three eigenvalues are sorted according to the size of the absolute value (|λ1|≤|λ2|≤|λ3|), and the corresponding eigenvectors are e1, e2, and e3. The positive and negative signs and sizes of the Hessian eigenvalues can be used to detect vascular structures that are independent of direction and based on the shape and relative brightness relationship between the foreground and background. Sato et al. summarized the relationship that must be maintained between the Hessian eigenvalues when detecting structures of different shapes.
[0040] Vascular structures mainly include vascular lesions such as thin straight blood vessels, curved blood vessels, vascular bifurcations and aneurysms, which are typical tubular structures. Therefore, the condition for point X to be in the vascular area is that the value of λ1 is very small (ideally zero), and the values of λ2 and λ3 are large and have the same positive and negative signs. Both λ2 and λ3 are negative numbers, indicating that the target structure is bright and the background is dim. When both are positive numbers, the situation is just the opposite. e1 indicates the direction of the vascular structure, in which the local intensity change is the smallest, while e2 and e3 constitute the basis of the orthogonal plane. Function It represents the Hessian-based shape detection acting on 3D images, which can be expressed as In terms of the vascular structure in the 3D image, it can be expressed as This function can selectively amplify tubular structures in the image. In CTA and MRA, vascular structures usually have higher intensity values than background areas. This prior information related to the imaging method can be used as a consistency check, that is, the vascular response appearing in the darker area will be discarded and the response of non-vascular structures will be suppressed. Therefore, vascular enhancement needs to find structures where λ2 and λ3 are both negative and meet the above conditions.
[0041] The shape response of the blood vessel is measured by the similarity measure function There are some problems with existing similarity measures, such as poor and uneven responses in areas with different vessel diameters, varying contrast, bifurcations, tumors, etc. In order to improve the robustness to low eigenvalues and produce a more uniform response on different vascular structures, the similarity measure used in this paper is:
[0042]
[0043] Among them, λ ρ Indicates that the value of λ3 is regularized at each scale s:
[0044]
[0045] Where τ is a threshold parameter with a value range of [0,1]. The above similarity measurement is performed at each scale s, and the maximum value of the response can be obtained at the scale that best matches the size of the blood vessel to be detected. This maximum value can be regarded as the final result of the blood vessel shape detection at point X:
[0046]
[0047] Among them, s min and max The value of can be determined according to the scale range of the vascular structure to be detected. The value range is [0,1], where 0 represents non-vascular structure and 1 represents vascular structure.
[0048] After obtaining the vascular shape information, the present invention combines the shape information and the intensity information to design a 2D transfer function, encode the opacity, and improve the quality of vascular visualization. In Hessian-based shape coding rendering, the most common rendering scheme is to directly map the eigenvalues λ2 and λ3 to color attributes, for example:
[0049] I red ∝|λ2| ifλ3≤λ2<0(vesselness)
[0050] Iblue ∝|λ2| ifλ3≥λ2>0(airwayness)
[0051] I yellow ∝|λ3| ifλ3≤λ2≤λ1<0(blobness)
[0052] Among them, I red ,I blue and I yellow The RGB value represents the color attribute. However, this rendering scheme only uses two eigenvalues, and the visualization quality in areas such as vascular bifurcations and tumors is poor. In addition, in the 2D transfer function, the opacity of the vascular area also decays due to the gradual attenuation of the vascular response from the center to the edge of the vessel. Therefore, this transfer function is not conducive to visualizing curves and linear structures in angiography images. The 2D transfer function proposed in this paper is derived from the standard intensity transfer function and the transfer function based on the vessel shape information It consists of two parts, such as Figure 2 As shown. For any point X, the opacity transfer function is defined as:
[0053]
[0054] This paper combines the histogram design of vascular shape response distribution ( Figure 2(b)). If point X is in the complete suppression area, the opacity value is always zero. The partial suppression area in the middle suppresses structures with low response values by applying a smaller coefficient to the opacity. In the enhancement area on the far right, the vascular shape response value is very high, and a larger coefficient is applied to the opacity to highlight the vascular structure with high response value. The present invention achieves the effect of empirically adjusting the control points p1 and p2. Compared with directly selecting a cutoff threshold to divide the vascular area and the non-vascular area, the proposed The function has the characteristic of continuity at the boundaries of different tissue structures. In addition, in the color transfer function C DVR In one aspect, the present invention adopts a standard intensity transfer function instead of using eigenvalues or shape response values to encode colors, thereby avoiding potential interference factors introduced by color encoding in non-photorealistic rendering based on gradient contour rendering.
[0055] Preferably, in step (1), the blood vessel is directly volume rendered based on a GPU ray casting algorithm, and the ray casting algorithm is implemented in a fragment shader of the GPU;
[0056] Starting from the starting point of ray casting, interpolation calculation is first performed to obtain the scalar value corresponding to the current point, and these scalar values are mapped to the opacity optical property based on the shape-encoded transfer function; shading calculation is performed based on the Blinn-Phong illumination model to provide more directional information for the blood vessel surface; in the synthesis stage, all sampling points on the same ray are synthesized in the order from front to back or from back to front to generate corresponding pixel values; when the synthesis calculation is performed in the order from front to back, the final pixel value C pixel for:
[0057]
[0058] Among them, C i and α i are the i-th sampling point p on the ray i The color and opacity values of , expressed in recursive form:
[0059]
[0060] Among them, C′ i and α′ i Respectively represent the accumulated color and opacity values from 0 to i;
[0061] After the synthesis calculations on all rays are completed, the corresponding blood vessel direct volume rendering result image is presented in the display window.
[0062] Preferably, the step (1) implements direct blood vessel volume rendering to support 3D blood vessel visualization with interactive frame rates through graphics hardware acceleration.
[0063] Preferably, in step (2), the function f(X) represents the intensity distribution function of the 3D image, X = [x, y, z] T , the gradient vector is defined as:
[0064]
[0065] The gradient magnitude is defined as:
[0066]
[0067] After normalization, the gradient vector is defined as:
[0068]
[0069] Assuming that the origin of the local coordinate system is at the position of the current voxel point X, the intensity function f(X) in the local neighborhood is linearly approximated as:
[0070] f(X)≈Ax+By+Cz+D (8)
[0071] By assuming that f(X) is in the direction of the plane normal vector The linear approximation fits the 3D regression hyperplane to f(X). The D value determines the translation of this plane. The linear approximation is evaluated on the voxels in the local neighborhood, and the measurement error is calculated using the following mean square error:
[0072]
[0073] Among them, the coordinate x k ,y k and z k represents the position of the adjacent voxels in the local coordinate system; only the 26 neighborhoods of the current voxel point X are considered, then x k ,y k and z k The value of is ±1 or 0, the serial number k = 9(z+1)+3(y+1)+(x+1); the intensity value of the kth voxel is f k Indicates that the weight of the error contribution of the k-th voxel is w k :
[0074]
[0075] Among them, d k is the Euclidean distance from the kth voxel to the central voxel;
[0076] To minimize the 4D error function E(A,B,C,D), find the partial derivatives of the four unknown variables A, B, C, and D:
[0077]
[0078] When the error function takes its minimum value, these partial derivatives are all equal to zero; since w k , x k ,y k and z k Symmetric about the origin, so the solution to this linear equation system is:
[0079]
[0080] Finally, bring the above results into The gradient vector of the voxel point X in the 3D image is obtained, and the result is quickly obtained by calculating the first-order derivative filter.
[0081] Preferably, in step (2), the contour enhancement function is defined as:
[0082]
[0083] Among them, α X is the initial opacity value, parameter (scale control) controls the scaling of the overall opacity of the outline, parameters (contour thickness) controls the thickness of the contour, while the parameter (contour sharp) controls the sharpness of the contour, (gradient magnitude) is the gradient magnitude threshold used to control scene complexity.
[0084] Since the gradient direction The value range of the vector dot product result with the line of sight direction V is [0,1], so The value range of is also [0,1]; The closer it is to 0, the smaller the contour thickness; The closer it is to 1, the thicker the contour; The value range of is Usually set to a number greater than 1 to enlarge the interval The value within the range is reduced The value inside; The larger it is, the greater the overall opacity difference between the outlined and non-outlined areas, thus increasing the contrast; The smaller it is, the smaller the overall opacity difference between the contour area and the non-contour area is, and the contrast decreases; The setting depends on the initial opacity value α X , and make empirical adjustments based on the final display effect.
[0085] Preferably, in step (2), in order to reduce noise lines, when the condition When , the corresponding voxel point X is invisible; the color transfer function C of the contour NPR Set the outline to white.
[0086] Those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium. When the program is executed, it includes the steps of the above-mentioned embodiment method, and the storage medium can be: ROM / RAM, disk, CD, memory card, etc. Therefore, corresponding to the method of the present invention, the present invention also includes a 3D blood vessel visualization device based on shape coding hybrid rendering. The device includes:
[0087] A vascular direct volume rendering module, which is configured to encode opacity optical properties using a 2D feature space defined by vascular shape information and intensity information, construct a 2D transfer function based on vascular shape features and intensity features, and achieve effective distinction between vascular and non-vascular structures in vascular direct volume rendering based on a GPU ray casting algorithm, achieve multi-tissue structure classification, and emphasize vascular structures of interest in vascular direct volume rendering;
[0088] A blood vessel non-realistic rendering module is configured to express the contour information of tissues and organs around blood vessels in 3D angiography images in non-realistic rendering by analyzing the relationship between local gradient vectors and the angle of sight direction, thereby reducing unnecessary details in 3D angiography images and enhancing the contour features of tissues and organs around blood vessels;
[0089] A fusion module configured to fuse the rendering results of photorealistic rendering and direct volume rendering based on the vascular shape information, thereby highlighting the vascular structure and lesion information of interest in the hybrid rendering result and improving the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels;
[0090] In the fusion module, a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering:
[0091]
[0092] Where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values.
[0093] Preferably, in the blood vessel direct volume rendering module, for any point X, the 2D transfer function based on the blood vessel shape feature and intensity feature is:
[0094]
[0095] Among them, the standard intensity transfer function Transfer function based on blood vessel shape information
[0096] Preferably, in the blood vessel direct volume rendering module, the blood vessel direct volume rendering is performed based on a GPU ray casting algorithm, and the ray casting algorithm is implemented in a fragment shader of the GPU;
[0097] Starting from the starting point of ray casting, interpolation calculation is first performed to obtain the scalar value corresponding to the current point, and these scalar values are mapped to the opacity optical property based on the shape-encoded transfer function; shading calculation is performed based on the Blinn-Phong illumination model to provide more directional information for the blood vessel surface; in the synthesis stage, all sampling points on the same ray are synthesized in the order from front to back or from back to front to generate corresponding pixel values; when the synthesis calculation is performed in the order from front to back, the final pixel value C pixel for:
[0098]
[0099] Among them, C i and α i are the i-th sampling point p on the ray i The color and opacity values of , expressed in recursive form:
[0100]
[0101] Among them, C′ i and α′ iRespectively represent the accumulated color and opacity values from 0 to i;
[0102] After the synthesis calculations on all rays are completed, the corresponding blood vessel direct volume rendering result image is presented in the display window.
[0103] In order to solve the problems that different structures with similar intensity ranges are difficult to distinguish and how to balance the information of vascular structure and non-vascular structure, the present invention proposes a 3D vascular visualization method based on shape-coded hybrid rendering. First, the opacity optical properties are encoded in the 2D feature space defined by the vascular shape information and intensity information to achieve multi-tissue structure classification and emphasize the vascular structure of interest in the direct vascular volume rendering. Secondly, the shape information of the tissues and organs around the blood vessels is expressed through non-realistic rendering based on gradient contour drawing, and unnecessary detail information is removed. Finally, based on the vascular shape information, the rendering results of non-realistic rendering and direct volume rendering are fused in the fragment shader of the GPU, so as to highlight the vascular structure and lesion information of interest in the hybrid rendering result, and enhance the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels.
[0104] The method proposed in the present invention is verified and evaluated on vascular simulation data and multi-modal, multi-site clinical angiography images. The results of the vascular simulation data contour enhancement experiment show that the contour enhancement method proposed in the present invention effectively expresses contour information by controlling the thickness and sharpness of the contour, thereby improving the effect of non-realistic rendering. Experiments on clinical angiography images show that the shape coding-based hybrid rendering method proposed in the present invention effectively expresses the tissue and organ information around the blood vessels that does not interfere with the visualization of the blood vessels while highlighting the vascular structures of interest in the 3D images, and clearly conveys the complex spatial relationships in the 3D angiography images. In order to quantitatively evaluate the method proposed in the present invention, the present invention also designed a user survey experiment, and the results showed that the proposed shape coding-based hybrid rendering method was subjectively preferred by 100% of the participants, verifying the effectiveness of the proposed method. In addition, the average rendering time in multiple data scenarios was 110ms, indicating that the proposed method supports 3D vascular visualization with interactive frame rates.
[0105] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Any simple modification, equivalent changes and modifications made to the above embodiments based on the technical essence of the present invention are still within the protection scope of the technical solution of the present invention.
Claims
1. A 3D blood vessel visualization method based on shape coding hybrid rendering, characterized by: It includes the following steps: (1) The opacity optical properties are encoded in the 2D feature space defined by the vascular shape information and the intensity information, and a 2D transfer function based on the vascular shape features and the intensity features is constructed. The GPU ray casting algorithm is used to effectively distinguish the vascular and non-vascular structures in the vascular direct volume rendering, realize the classification of multiple tissue structures, and emphasize the vascular structures of interest in the vascular direct volume rendering. (2) By analyzing the relationship between the local gradient vector and the angle of the sight direction, the contour information of the tissues and organs around the blood vessels in the 3D angiography image is expressed in the non-photorealistic rendering, the unnecessary details in the 3D angiography image are reduced, and the contour features of the tissues and organs around the blood vessels are enhanced; (3) Based on the vascular shape information, the rendering results of realistic rendering and direct volume rendering are fused to highlight the vascular structure and lesion information of interest in the hybrid rendering results, and to improve the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels; In step (3), a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering: where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values.
2. The 3D blood vessel visualization method based on shape coding hybrid rendering according to claim 1, characterized in that: In step (1), for any point X, the 2D transfer function based on the blood vessel shape feature and intensity feature is: Among them, the standard intensity transfer function Transfer function based on blood vessel shape information 3. The 3D blood vessel visualization method based on shape coding hybrid rendering according to claim 2, characterized in that: In the step (1), the blood vessel is directly volume rendered based on the GPU ray casting algorithm, and the ray casting algorithm is implemented in the fragment shader of the GPU; Starting from the starting point of ray casting, interpolation calculation is first performed to obtain the corresponding scalar value of the current point, and these scalar values are mapped to the opacity optical property based on the shape-encoded transfer function; shading calculation is performed based on the Blinn-Phong illumination model to provide more directional information for the blood vessel surface; In the synthesis stage, all sampling points on the same ray are synthesized and calculated in order from front to back or from back to front to generate corresponding pixel values; when the synthesis calculation is performed in order from front to back, the final pixel value C pixel for: Among them, C i and α i are the i-th sampling point p on the ray i The color and opacity values of , expressed in recursive form: Among them, C′ i and α′ i Respectively represent the accumulated color and opacity values from 0 to i; After the synthesis calculations on all rays are completed, the corresponding blood vessel direct volume rendering result image is presented in the display window.
4. The 3D blood vessel visualization method based on shape coding hybrid rendering according to claim 3, characterized in that: The step (1) implements direct blood vessel volume rendering and supports 3D blood vessel visualization with interactive frame rates through graphics hardware acceleration.
5. The 3D blood vessel visualization method based on shape coding hybrid rendering according to any one of claims 1 to 4, characterized in that: In step (2), function f(X) represents the intensity distribution function of the 3D image, X = [x, y, z] T , the gradient vector is defined as: The gradient magnitude is defined as: After normalization, the gradient vector is defined as: Assuming that the origin of the local coordinate system is at the position of the current voxel point X, the intensity function f(X) in the local neighborhood is linearly approximated as: f(X)≈Ax+By+Cz+D (8) By assuming that f(X) is in the direction of the plane normal vector The linear approximation fits the 3D regression hyperplane to f(X). The D value determines the translation of this plane. The linear approximation is evaluated on the voxels in the local neighborhood, and the measurement error is calculated using the following mean square error: Among them, the coordinate x k ,y k and z k represents the position of the adjacent voxels in the local coordinate system; only the 26 neighborhoods of the current voxel point X are considered, then x k ,y k and z k The value of is ±1 or 0, the serial number k = 9(z+1)+3(y+1)+(x+1); the intensity value of the kth voxel is f k Indicates that the weight of the error contribution of the k-th voxel is w k : Among them, d k is the Euclidean distance from the kth voxel to the central voxel; Minimize the 4D error function E(A, B, C, D) and find the partial derivatives of the four unknown variables A, B, C, and D: When the error function takes its minimum value, these partial derivatives are all equal to zero; since w k , x k ,y k and z k Symmetric about the origin, so the solution to this linear equation system is: Finally, bring the above results into The gradient vector of the voxel point X in the 3D image is obtained, and the result is quickly obtained by calculating the first-order derivative filter.
6. The 3D blood vessel visualization method based on shape coding hybrid rendering according to claim 5, characterized in that: In step (2), the contour enhancement function is defined as: Among them, α X is the initial opacity value, parameter Controls the scaling of the overall opacity of the outline, parameters controls the thickness of the contour, while the parameter Controls the sharpness of the outline, is the gradient size threshold used to control the complexity of the scene; Since the gradient direction The value range of the vector dot product result with the line of sight direction V is [0, 1], so The value range of is also [0, 1]; The closer it is to 0, the smaller the contour thickness; The closer it is to 1, the thicker the contour; The value range of is Set to a number greater than 1 to enlarge the interval The value within the range is reduced The value inside; The larger it is, the greater the overall opacity difference between the outlined and non-outlined areas, thus increasing the contrast; The smaller it is, the smaller the overall opacity difference between the contour area and the non-contour area is, and the contrast decreases; The setting depends on the initial opacity value α X , and make empirical adjustments based on the final display effect.
7. The 3D blood vessel visualization method based on shape coding hybrid rendering according to claim 6, characterized in that: In step (2), in order to reduce noise lines, when the condition is not met When , the corresponding voxel point X is invisible; the color transfer function C of the contour NPR Set the outline to white.
8. A 3D blood vessel visualization device based on shape coding hybrid rendering, characterized in that: It includes: A vascular direct volume rendering module, which is configured to encode opacity optical properties using a 2D feature space defined by vascular shape information and intensity information, construct a 2D transfer function based on vascular shape features and intensity features, and achieve effective distinction between vascular and non-vascular structures in vascular direct volume rendering based on a GPU ray casting algorithm, achieve multi-tissue structure classification, and emphasize vascular structures of interest in vascular direct volume rendering; A blood vessel non-realistic rendering module is configured to express the contour information of tissues and organs around blood vessels in 3D angiography images in non-realistic rendering by analyzing the relationship between local gradient vectors and the angle of sight direction, thereby reducing unnecessary details in 3D angiography images and enhancing the contour features of tissues and organs around blood vessels; A fusion module configured to fuse the rendering results of photorealistic rendering and direct volume rendering based on the vascular shape information, thereby highlighting the vascular structure and lesion information of interest in the hybrid rendering result and improving the understanding and perception of the spatial relationship between the vascular structure and the tissues and organs around the blood vessels; In the fusion module, a rendering result fusion method based on vascular shape information is constructed to highlight the vascular structure of interest in the rendered image and integrate the tissue and organ information around the blood vessels into the rendering result. In the synthesis order from front to back, the vascular shape information is used to fuse the results of non-realistic rendering and direct volume rendering: where X = [x, y, z] T is a variable, is the similarity measure function, C DVR is the color transfer function, C NPR is the contour color transfer function, is the opacity transfer function, is the contour enhancement function, C hybird is the color value, α hybird Shape-encoded blending is achieved by tracing rays through the volume data in the GPU fragment shader for opacity values.
9. The 3D blood vessel visualization device based on shape coding hybrid rendering according to claim 8, characterized in that: In the vessel direct volume rendering module, for any point X, the 2D transfer function based on the vessel shape feature and intensity feature is: Among them, the standard intensity transfer function Transfer function based on blood vessel shape information 10. The 3D blood vessel visualization device based on shape coding hybrid rendering according to claim 9, characterized in that: In the blood vessel direct volume rendering module, the blood vessel direct volume rendering is performed based on the GPU ray casting algorithm, and the ray casting algorithm is implemented in the GPU fragment shader; starting from the starting point of the ray casting, an interpolation calculation is first performed to obtain the scalar value corresponding to the current point, and these scalar values are mapped to the opacity optical property based on the shape-coded transfer function; a shading calculation is performed based on the Blinn-Phong illumination model to provide more directional information for the blood vessel surface; In the synthesis stage, all sampling points on the same ray are synthesized in order from front to back or from back to front to generate corresponding pixel values; when the synthesis calculation is performed in order from front to back, the final pixel value C pixel for: Among them, C i and α i are the i-th sampling point p on the ray i The color and opacity values of , expressed in recursive form: Among them, C′ i and α′ i Respectively represent the accumulated color and opacity values from 0 to i; After the synthesis calculations on all rays are completed, the corresponding blood vessel direct volume rendering result image is presented in the display window.
