Orthopedic surgery preoperative planning method based on UE5
Through the transformation of the UE5 platform, high precision and high flexibility of plastic surgery preoperative planning have been achieved, the problem of insufficient simulation of surgical details in existing technologies has been solved, visual surgical design tools have been provided, and the rationality and accuracy of surgical plans have been improved.
Patent Information
- Application Number
- CN202511156653.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-19
- Publication Date
- 2025-09-16
- Estimated Expiration
- 2045-08-19
AI Technical Summary
Existing 3D visualization and simulation technologies cannot meet the requirements of high precision and high flexibility in preoperative planning of plastic surgery, especially in details such as triangular surface processing between two points, closed area search, incision vertex separation and tension calculation.
Through in-depth transformation of the UE5 platform, a dynamic triangle splitting algorithm was developed to achieve surgical cutting and incision separation. Combined with soft body simulation and graphics rendering functions, it simulates surgical resection, transplant design and suturing processes, calculates pulling or tension, and optimizes model structure.
It provides visual and adjustable preoperative planning tools, improves the accuracy and realism of simulation, helps doctors make more accurate surgical designs and effect evaluations, and reduces surgical risks.
Smart Images

Figure CN120656739A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of graphics processing technology, and in particular to a plastic surgery preoperative planning method based on UE5. Background Art
[0002] In plastic surgery, preoperative planning is crucial for the success of the operation. Traditional preoperative planning often relies on the doctor's experience and two-dimensional images, making it difficult to intuitively demonstrate the surgical results and assess surgical risks. With the development of computer graphics technology, the application of three-dimensional visualization and simulation technology in the medical field has gradually increased. However, existing related technologies still have shortcomings in dynamic editing, biomechanical simulation, interactive operation, etc., and cannot meet the high-precision and high-flexibility requirements of plastic surgery preoperative design. In particular, there are deficiencies in details such as triangulation between two points, closed area search, incision vertex separation, and tension calculation. Summary of the Invention
[0003] The present invention aims to overcome the problems existing in the prior art and provides a method for plastic surgery preoperative planning based on UE5. It should be clarified that UE5 is a well-known existing technology platform, and its basic functions (such as graphics rendering, physical simulation, and general interaction) are common knowledge in the field. The innovation of the present invention lies in its customized transformation for medical scenarios.
[0004] UE5 is a well-known real-time 3D development platform in the field, which includes the following features: Graphics rendering: Relying on Nantie, Lumen and other technologies, it realizes real-time light and shadow rendering and material display of 3D models; Physics simulation: Through the Chaos physics system, it provides rigid body collision and basic soft body deformation simulation capabilities; Interactive function: Supports input from peripherals such as mouse and handles, and implements common interactive responses such as clicking and dragging virtual objects.
[0005] The above functions are existing technologies that can be directly obtained by those skilled in the art. However, they are not adapted to the medical characteristics of plastic surgery preoperative planning (such as surgical incision and flap simulation) and cannot meet the needs of surgical planning. This invention does not reuse the existing functions of UE5, but makes in-depth innovations based on them. The specific differences are as follows: 1. Improvement of physical simulation functions: Develop a dynamic triangle splitting algorithm to adapt to surgical cutting and incision separation requirements; 2. Improvements to soft body simulation: Through dynamic mesh models, vertices can be added and deleted in real time, triangles can be reorganized, and constraints can be added to simulated vertices to enable drag-and-sew functions. 3. Extension of graphics rendering capabilities: Implement medical tissue simulation and map mechanical calculation results into visual effects; The object of the present invention is achieved through the following technical solutions: A method for preoperative planning of plastic surgery based on UE5 is provided, comprising the following steps: S1. Convert the static three-dimensional mesh model of the patient's affected area into a dynamic mesh model, allowing the mesh model data to be dynamically edited during runtime. This step lays the foundation for subsequent interactive operations and simulations. Through the characteristics of the dynamic mesh, it can respond to various editing operations in real time. S2. Based on the dynamic mesh model, the wound area to be repaired is delineated on the model surface through interactive operations, and the morphological characteristics of the wound are simulated. The doctor can determine the area that needs to be repaired based on the patient's actual situation and understand the basic morphology of the wound through simulation. S3. Perform a virtual excision operation on the delineated wound area to generate a wound defect model. This operation can simulate the excision process during surgery and provide an accurate defect morphology reference for subsequent transplant design. S4. Delineate the transplanted skin area from the preset donor area dynamic mesh, and simulate the morphology, tension distribution and matching degree of the transplanted skin with the wound through biomechanical simulation. Through biomechanical simulation, the state of the transplanted skin in the body can be more realistically simulated, helping doctors evaluate the transplant effect. S5. In the simulation area, the transplanted skin model and surrounding tissues are virtually cut, and drag-and-drop operations are supported to achieve secondary incision design, with flexible adjustment of the incision position, angle, and range; the system updates the dynamic mesh model in real time to reflect the effects of cutting and adjustment. S6. The suturing process of the transplanted skin and the wound surface is simulated, and the tissue morphology after suturing is simulated through the deformation calculation of the dynamic mesh; through this simulation, the doctor can understand the effect after suturing in advance and further evaluate the rationality of the surgical plan. S7. Based on the tissue morphology after simulation suturing, the triangle surface between two points is solved and reconstructed, and the vertices and triangle surfaces in the closed area are recursively searched to achieve incision vertex separation, and the tension or tension is calculated based on the relationship between the vertices and the triangle surfaces. The solution and reconstruction of the triangle surface between two points can optimize the model structure, the recursive search helps to accurately locate the area, the separation of the incision vertices can improve the cutting accuracy, and the calculation of tension or tension can more realistically simulate the stress state of the skin.
[0006] In some embodiments, converting the static three-dimensional mesh model of the patient's affected area into a dynamic mesh model includes: Remove duplicate vertices to optimize the mesh structure. The calculation formula is: and , if the absolute value of the position difference between the two vertices is less than the set threshold ,Right now , then it is determined to be a duplicate vertex and merged. Represents a vertex location, Represents a vertex location; Correct the mesh vertex normals. The correction formula is: ,in is the corrected normal, The normals of adjacent triangles are used to improve the model surface lighting rendering accuracy, making the model more realistic visually.
[0007] In some embodiments, determining that the vertices are duplicates and performing a merge process includes: Vertex list deduplication: In the vertex array of the mesh, find the data of vertices i and j, which includes the position information, normal information and all triangle information associated with the vertex and the vertex information contained in these triangles; delete or Vertices with less information about the middle triangle; Triangle association update: Each triangle data contains three vertex indices, and the vertices will be deleted or The corresponding deleted vertices in the vertex information of the associated triangle are replaced with the retained vertex index, such as the triangle The original vertex index is ,in is the index of the deleted vertex, then Vertex information Replace with , the updated result is . It should be noted that if the vertex is deleted The vertex index of the associated triangle contains duplicate vertices , then directly delete the triangle information without replacing it; It should be made clear that the deduplication of vertex lists and the update of triangle associations in the present invention are not simply processing of UE5 model data, but a deep integration of the particle information of flap simulation, early adaptation of tissue mechanics solution constraints, and transformation of conventional mesh optimization into a process serving plastic surgery simulation, which is different from the existing technology.
[0008] In some embodiments, in the biomechanical simulation, the skin properties are simulated by creating particle mass and spring constraints, wherein the particle mass is calculated as follows: ,in is the particle mass, is the total mass, is the number of particles; the stiffness of the spring constraint is set by the tensile stiffness and bending stiffness parameters to simulate the stretching and bending characteristics of the skin, and the damping coefficient is introduced To simulate skin motion attenuation, the particle velocity update formula is: ,in is the velocity value of the current frame, is the speed value of the previous frame, is the motion attenuation value, is the interval between the current frame and the previous frame, represents acceleration; the skin tension distribution is calculated using the extended formula of Hooke's law: ,in For tension, is the current length, is the original length, Represents the tensile stiffness.
[0009] In some embodiments, during the virtual resection operation, whether a point is on the triangle plane is determined by calculating the distance from the point to the triangle plane, using the formula: ,in is a point on the plane, is the plane normal vector, is the value of the plane equation; then a point outside the plane The distance to the plane is ,when When it is less than the set threshold, the point is determined to be on the plane; the smoothness of the cutting edge is calculated using the weighted average formula: the new position of the edge vertex ,in is the new position after smoothing, is the current edge point, is the weight of adjacent vertices, which is distributed in inverse proportion to the distance. In some embodiments, during the virtual cutting operation, two cutting points are calculated. Connection and Normal vector of the triangle The formed plane with dot The endpoints of the triangle edges contained in the associated triangle face The intersection of , the formula is: , , , , , ,in Indicates the cutting point The vector formed, Represents the endpoints of a triangle edge The vector formed, is the triangle edge vector and The dot product of the cutting plane, is the ray parameter, indicating the Departure delay The step ratio of the direction, when and When the intersection point is on the triangle edge; through the intersection point Create New Vertex ,pass and Reorganize the new triangle surface and add it to the plane according to the relationship between the triangle edges Move to both sides and then As a new Solve recursively until the required triangle contains the vertex , adding the resulting intersection point to the set of cut vertices.
[0010] In some embodiments, the simulated suturing process of the transplanted skin and the wound surface includes: During the stitching simulation, multi-level constraints are applied to vertices to achieve stitching simulation: Rigid constraint: impose position constraints on the stitching point pair, assuming that the stitching point pair is , the constraint equation is ,in for At the position corresponding to each frame, For each frame The corresponding position, The stitching accuracy threshold is set and the constraint satisfaction is ensured by the position correction algorithm; Elastic constraint: Apply spring constraints to the vertices around the stitching point. The constraint strength decays with distance. The elastic force is ,in is the elastic coefficient, is the current distance, is the initial distance, is the unit direction vector; Area constraint: Set the maximum displacement threshold for the vertices within the stitching area, and the constraint formula ,in is the current position of the vertex, is the initial position, is the maximum allowable displacement; Moving distance calculation: , , ,in and For the two points that need to be sutured, To obtain and The distance between points, is the moving speed, for point The distance to move, for point The distance to be moved, Method The value will not be less than 0 and not greater than , is the frame interval duration, for The moving weight, for and The current distance between the two points is gradually adjusted by this moving distance to simulate the stitching effect.
[0011] In some embodiments, the solving and reconstruction of the triangular surface between two points includes: First determine the shortest path between two points. The triangle set on the path is the solution target. Let the two points be 、 , triangular face The three vertices of 、 、 ,like and On the triangle surface On both sides of the line segment With triangles If they intersect, the triangle is one of the triangles on the path. In this way, a triangle sequence between two points is constructed. When reconstructing, the coordinates of the new triangle vertex are calculated as the new vertex. ,in , 、 、 is the weight coefficient, which is assigned according to the position of the triangle in the path. In some embodiments, the recursive search for vertices and triangular faces within a closed region includes: Initial vertex As the starting point, recursively traverse the vertices adjacent to the current vertex ,like If the closed region boundary condition is met, it will be added to the region vertex set, and the Add the triangles with vertices already in the set to the regional triangle set.
[0012] In some embodiments, the incision apex separation comprises: Calculate the distance ratio from the vertex on the incision line to the two end points of the incision. Let the two end points of the incision be 、 ,vertex arrive The distance is ,arrive The distance is , distance ratio ,when exist When the vertex is within the range Mark the vertices separated by the cut and The values are assigned to different vertex subsets; the vertices on both sides of the cutting plane are classified, and the vertices The distance to the cutting plane is ,when When is the vertex on the positive side of the plane, When is the vertex on the negative side of the plane, is the distance threshold; the triangles that cross the cutting plane are split to generate a new set of triangles. The new vertex offset after splitting is calculated as ,in is the cutting plane normal vector, is the separation distance parameter; a bidirectional mapping relationship between the cutting edge vertices is established, and the mapping intensity coefficient is ,in 、 is the distance from the corresponding vertex to the cutting starting point, is the attenuation coefficient; The calculation of the pulling force or tension according to the relationship between the vertex and the triangle surface includes: For vertices and contains The formula for calculating the tension on the triangular surface is ,in is the deformation variable of the triangle surface, is the initial area of the triangle, is the tensile coefficient; tension The calculation of the distance between the vertex and each side of the triangle is based on the tension. The formula is ,in It is the ratio of the distance from the vertex to each edge of the triangle to the length of the triangle edge.
[0013] It should be further explained that the technical features corresponding to the above embodiments can be combined or replaced with each other to form a new technical solution if there is no conflict.
[0014] Compared with the prior art, the present invention has the following beneficial effects: The present invention achieves simulation of tissue physical properties by converting static meshes to dynamic meshes, and combines wound treatment, transplant design, and interactive cutting and suturing simulation to provide a visual and adjustable preoperative planning tool for plastic surgery. Newly added content such as solving and reconstructing triangles between two points, recursive searching for vertices and triangles within a closed area, separation of incision vertices, and calculation of pulling force or tension based on the relationship between vertices and triangles, as well as related formulas, further enhances the accuracy and authenticity of the simulation, and can more comprehensively simulate various situations during surgery. Doctors can perform more accurate surgical design and effect evaluation before surgery, which helps to improve the rationality and accuracy of surgical plans and reduce surgical risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 This is a flow chart of a plastic surgery preoperative planning method based on UE5 according to an embodiment of the present invention; Figure 2 A schematic diagram of optimizing duplicate vertices when converting a static mesh to a dynamic mesh according to an embodiment of the present invention; Figure 3 This is a schematic diagram of forming a cutting path point set according to an embodiment of the present invention; Figure 4 A schematic diagram of reconstructing a triangular surface according to an embodiment of the present invention; Figure 5 A schematic diagram of solving the intersection of a cutting path and a triangle edge according to an embodiment of the present invention; Figure 6 This is a schematic diagram of cutting vertex separation according to an embodiment of the present invention. DETAILED DESCRIPTION
[0016] The technical solutions of the present invention are described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. The components of the embodiments of the present application generally described and shown in the drawings herein can be arranged and designed in various different configurations. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0017] It should be noted that the defects existing in the solutions in the above-mentioned prior art are the results obtained by the inventor after practice and careful research. Therefore, the discovery process of the above-mentioned problems and the solutions proposed in the embodiments of this application below for the above-mentioned problems should be the contributions made by the inventor to this application in the process of invention and creation, and should not be understood as technical contents known to technical personnel in this field.
[0018] In an exemplary embodiment, referring to FIG. 1 , a UE5-based plastic surgery preoperative planning method includes the following steps.
[0019] S1. Converting Static Mesh to Dynamic Mesh: In UE5, convert a static 3D mesh model to a dynamic mesh model using relevant components and functions. As shown in Figure 2, during the conversion process, duplicate vertices need to be removed to optimize the mesh structure. Converting a static 3D mesh model of the patient's affected area to a dynamic mesh model includes: Remove duplicate vertices to optimize the mesh structure. The calculation formula is: and , if the absolute value of the position difference between the two vertices is less than the set threshold ,Right now , then it is determined to be a duplicate vertex and merged. Represents a vertex location, Represents a vertex location; Correct the mesh vertex normals. The correction formula is: ,in is the corrected normal, is the normal of the adjacent triangle. It is a minimum threshold constant, usually 0.0001 units. The unit depends on the scale of the modeling, such as 0.0001mm in a millimeter-scale scene. Vertex list deduplication: In the vertex array of the mesh, find the data of vertices i and j, which includes the position information, normal information and all triangle information associated with the vertex and the vertex information contained in these triangles; delete or Vertices with less information about the middle triangle; Triangle association update: Each triangle data contains three vertex indices, and the vertices will be deleted or The corresponding deleted vertices in the vertex information of the associated triangle are replaced with the retained vertex index, such as the triangle The original vertex index is ,in is the index of the deleted vertex, then Vertex information Replace with , the updated result is . It should be noted that if the vertex is deleted The vertex index of the associated triangle contains duplicate vertices , then directly delete the triangle information without replacing it;
[0020] S2. Delineation of wound area and simulation: As shown in Figures 3 and 4, the doctor operates on the dynamic grid model through the interactive device to form a set of path points , create new model vertices at the path points, and reconstruct the triangles based on the adjacent vertices. If the adjacent vertices are not in the same triangle, the intersection needs to be calculated by the triangle intersection solving algorithm and added to the set Based on the characteristics of the dynamic mesh model, it responds to operations in real time and displays the demarcated area. S3. Virtual excision to generate defect model: Perform virtual excision according to the defined wound area. In the virtual excision operation, the distance from the point to the triangle plane is calculated to determine whether the point is on the triangle plane, and then determine the range of excision. The formula is: ,in is a point on the plane, is the plane normal vector, is the value of the plane equation; then a point outside the plane The distance to the plane is ,when When it is less than the set threshold, the point is determined to be on the plane; the smoothness of the cutting edge is calculated using the weighted average formula: the new position of the edge vertex ,in is the new position after smoothing, is the current edge point, is the weight of adjacent vertices, which is distributed in inverse proportion to the distance.
[0021] As shown in Figure 5 and Figure 6, in the virtual cutting operation, by calculating two cutting points Connection and Normal vector of the triangle The formed plane with dot The endpoints of the triangle edges contained in the associated triangle face The intersection of , the formula is: , , , , , ,in Indicates the cutting point The vector formed, Represents the endpoints of a triangle edge The vector formed, is the triangle edge vector and The dot product of the cutting plane, is the ray parameter, indicating the Departure delay The step ratio of the direction, when and When the intersection point is on the triangle edge; through the intersection point Create New Vertex ,pass and Reorganize the new triangle surface and add it to the plane according to the relationship between the triangle edges Move to both sides and then As a new Solve recursively until the required triangle contains the vertex , add the resulting intersection point to the set of cut vertices, making the cut vertices and faces continuous.
[0022] S4. Delineation and simulation of transplanted skin area: After delineating the transplanted skin area from the preset donor area dynamic grid, biomechanical simulation is performed. In the simulation, the transplanted skin area is divided into multiple particles, where the particle mass is calculated as follows: ,in is the particle mass, is the total mass, is the number of particles; the stiffness of the spring constraint is set by the tensile stiffness and bending stiffness parameters to simulate the stretching and bending characteristics of the skin, and the damping coefficient is introduced To simulate skin motion attenuation, the particle velocity update formula is: ,in is the velocity value of the current frame, is the speed value of the previous frame, is the motion attenuation value, is the interval between the current frame and the previous frame, represents acceleration; the skin tension distribution is calculated using the extended formula of Hooke's law: ,in For tension, is the current length, is the original length, Indicates tensile stiffness, thereby achieving simulation of the matching degree between the morphology of the transplanted skin and the wound surface.
[0023] S5. Virtual Incision and Secondary Incision Design: The doctor virtually incises the transplanted skin model and surrounding tissue. By dragging with a mouse or other interactive device, secondary incision design is implemented, allowing for flexible adjustment of the incision's position, angle, and range. The system updates the dynamic mesh model in real time to reflect the results of the incision and adjustments. The process of suturing the simulated transplanted skin and the wound surface includes: During the stitching simulation, multi-level constraints are applied to vertices to achieve stitching simulation: Rigid constraint: impose position constraints on the stitching point pair, assuming that the stitching point pair is , the constraint equation is ,in for At the position corresponding to each frame, For each frame The corresponding position, The stitching accuracy threshold is set and the constraint satisfaction is ensured by the position correction algorithm; Elastic constraint: Apply spring constraints to the vertices around the stitching point. The constraint strength decays with distance. The elastic force is ,in is the elastic coefficient, is the current distance, is the initial distance, is the unit direction vector; Area constraint: Set the maximum displacement threshold for the vertices within the stitching area, and the constraint formula ,in is the current position of the vertex, is the initial position, is the maximum allowable displacement; Moving distance calculation: , , ,in and For the two points that need to be sutured, To obtain and The distance between points, is the moving speed, for point The distance to move, for point The distance to be moved, Method The value will not be less than 0 and not greater than , is the frame interval duration, for The moving weight, for and The current distance between the two points is gradually adjusted by this moving distance to simulate the stitching effect.
[0024] S6. Solving and reconstructing triangular faces between two points: First determine the shortest path between the two points. The triangular faces on the path are the solution target. Suppose the two points are 、 , triangular face The three vertices of 、 、 ,like and On the triangle surface On both sides of the line segment With triangles If they intersect, the triangle is one of the triangles on the path. In this way, a triangle sequence between two points is constructed. When reconstructing, the coordinates of the new triangle vertex are calculated as the new vertex. ,in , 、 、 is the weight coefficient, which is assigned according to the position of the triangle in the path.
[0025] S7. Recursively search for vertices and triangles in the closed area: starting with the initial vertex As the starting point, recursively traverse the vertices adjacent to the current vertex ,like If the closed region boundary condition is met, it will be added to the region vertex set, and the Add the triangles with vertices already in the set to the regional triangle set.
[0026] S8. Cut vertex separation: Calculate the distance ratio between the vertex on the cut line and the two end points of the cut. Let the two end points of the cut be 、 ,vertex arrive The distance is ,arrive The distance is , distance ratio ,when exist When the vertex is within the range Mark the vertices separated by the cut and The values are assigned to different vertex subsets; the vertices on both sides of the cutting plane are classified, and the vertices The distance to the cutting plane is ,when When is the vertex on the positive side of the plane, When is the vertex on the negative side of the plane, is the distance threshold; the triangles that cross the cutting plane are split to generate a new set of triangles. The new vertex offset after splitting is calculated as ,in is the cutting plane normal vector, is the separation distance parameter; a bidirectional mapping relationship between the cutting edge vertices is established, and the mapping intensity coefficient is ,in 、 is the distance from the corresponding vertex to the cutting starting point, is the attenuation coefficient; The calculation of the pulling force or tension according to the relationship between the vertex and the triangle surface includes: For vertices and contains The formula for calculating the tension on the triangular surface is ,in is the deformation variable of the triangle surface, is the initial area of the triangle, is the tensile coefficient; tension The calculation of the distance between the vertex and each side of the triangle is based on the tension. The formula is ,in It is the ratio of the distance from the vertex to each edge of the triangle to the length of the triangle edge.
[0027] The above specific implementation methods are detailed descriptions of the present invention. It cannot be considered that the specific implementation methods of the present invention are limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, they can make several simple deductions and substitutions without departing from the concept of the present invention, which should be regarded as falling within the scope of protection of the present invention.
Claims
1. A plastic surgery preoperative planning method based on UE5, characterized in that: The following steps are involved: S1. Converting a static three-dimensional mesh model of the patient's affected area into a dynamic mesh model; S2. Based on the dynamic mesh model, the wound area to be repaired is delineated on the model surface through interactive operations, and the morphological characteristics of the wound surface are simulated; S3. Perform a virtual excision operation on the defined wound area to generate a wound defect model; S4. Delineate the transplanted skin area from the preset donor area dynamic grid and simulate the morphology, tension distribution, and matching degree of the transplanted skin with the wound surface through biomechanical simulation; S5. Virtually cut the transplanted skin model and surrounding tissue within the simulation area, supporting drag-and-drop operations to achieve secondary incision design and flexibly adjust the incision position, angle, and range. S6. Simulate the suturing process of the transplanted skin and the wound surface, and simulate the post-suturing tissue morphology through dynamic mesh deformation calculation. S7. Based on the simulated tissue morphology after suture, solve and reconstruct the triangular face between two points, recursively search for vertices and triangular faces within the closed area, separate the incision vertices, and calculate the pulling force or tension based on the relationship between the vertices and triangular faces.
2. A plastic surgery preoperative planning method based on UE5 according to claim 1, characterized in that: The converting of the static three-dimensional mesh model of the patient's affected area into a dynamic mesh model comprises: Remove duplicate vertices to optimize the mesh structure. The calculation formula is: and , if the absolute value of the position difference between the two vertices is less than the set threshold ,Right now , then it is determined to be a duplicate vertex and merged. Represents a vertex location, Represents a vertex location; Correct the mesh vertex normals. The correction formula is: ,in is the corrected normal, is the normal of the adjacent triangle.
3. A plastic surgery preoperative planning method based on UE5 according to claim 2, characterized in that: The process of determining duplicate vertices and merging them includes: Vertex list deduplication: Find the vertex in the vertex array of the mesh. and The data includes the position information corresponding to the vertex, normal information and all triangle information associated with the vertex and the vertex information contained in these triangles; delete the vertex or Vertices with less information about the middle triangle; Triangle face association update: Each triangle face data contains three vertex indices, and the corresponding deleted vertices in the vertex information of the triangle face associated with the deleted vertex i or j are replaced with the retained vertex indices.
4. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: In the biomechanical simulation, the skin properties are simulated by creating particle mass and spring constraints, where the particle mass is calculated as ,in is the particle mass, is the total mass, is the number of particles; the stiffness of the spring constraint is set by the tensile stiffness and bending stiffness parameters to simulate the stretching and bending characteristics of the skin, and the damping coefficient is introduced To simulate skin motion attenuation, the particle velocity update formula is: ,in is the velocity value of the current frame, is the speed value of the previous frame, is the motion attenuation value, is the interval between the current frame and the previous frame, represents acceleration; Skin tension distribution is calculated using the extended formula of Hooke's law: ,in For tension, is the current length, is the original length, Represents the tensile stiffness.
5. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: In the virtual resection operation, the distance from the point to the triangle plane is calculated to determine whether the point is on the triangle plane. The formula is: ,in is a point on the plane, is the plane normal vector, is the value of the plane equation; then a point outside the plane The distance to the plane is ,when When it is less than the set threshold, the point is determined to be on the plane; The smoothness of the cutting edge is calculated using the weighted average formula: the new position of the edge vertex ,in is the new position after smoothing, is the current edge point, is the weight of adjacent vertices, which is distributed in inverse proportion to the distance.
6. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: In the virtual cutting operation, two cutting points are calculated Connection and Normal vector of the triangle The formed plane with dot The endpoints of the triangle edges contained in the associated triangle face The intersection of , the formula is: , , , , , ,in Indicates the cutting point The vector formed, Represents the endpoints of a triangle edge The vector formed, is the triangle edge vector and The dot product of the cutting plane, is the ray parameter, indicating the Departure delay The step ratio of the direction, when and When the intersection point is on the triangle edge; through the intersection point Create New Vertex ,pass and Reorganize the new triangle surface and add it to the plane according to the relationship between the triangle edges Move to both sides and then As a new Solve recursively until the required triangle contains the vertex , adding the resulting intersection point to the set of cut vertices.
7. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: The process of suturing the simulated transplanted skin and the wound surface includes: During the stitching simulation, multi-level constraints are applied to vertices to achieve stitching simulation: Rigid constraint: impose position constraints on the stitching point pair, assuming that the stitching point pair is , the constraint equation is ,in for At the position corresponding to each frame, For each frame The corresponding position, The stitching accuracy threshold is set and the constraint satisfaction is ensured by the position correction algorithm; Elastic constraint: Apply spring constraints to the vertices around the stitching point. The constraint strength decays with distance. The elastic force is ,in is the elastic coefficient, is the current distance, is the initial distance, is the unit direction vector; Area constraint: Set the maximum displacement threshold for the vertices within the stitching area, and the constraint formula ,in is the current position of the vertex, is the initial position, is the maximum allowable displacement; Moving distance calculation: , , ,in and For the two points that need to be sutured, To obtain and The distance between points, is the moving speed, for point The distance to move, for point The distance to be moved, Method The value will not be less than 0 and not greater than , is the frame interval duration, for The moving weight, for and The current distance between the two points is gradually adjusted by this moving distance to simulate the stitching effect.
8. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: The solution and reconstruction of the triangular surface between two points includes: First determine the shortest path between two points. The triangle set on the path is the solution target. Let the two points be 、 , triangular face The three vertices of 、 、 ,like and On the triangle surface On both sides of the line segment With triangles If they intersect, the triangle is one of the triangles on the path. In this way, a triangle sequence between two points is constructed. When reconstructing, the coordinates of the new triangle vertex are calculated as the new vertex. ,in , 、 、 is the weight coefficient, which is assigned according to the position of the triangle in the path.
9. The method for preoperative planning of plastic surgery based on UE5 according to claim 1, characterized in that: The recursive search for vertices and triangles within the closed area includes: Initial vertex As the starting point, recursively traverse the vertices adjacent to the current vertex ,like If the closed region boundary condition is met, it will be added to the region vertex set, and the Add the triangles with vertices already in the set to the regional triangle set.
10. The method for preoperative planning of plastic surgery based on UE5 according to claim 7, characterized in that: The incision vertex separation comprises: Calculate the distance ratio from the vertex on the incision line to the two end points of the incision. Let the two end points of the incision be 、 ,vertex arrive The distance is ,arrive The distance is , distance ratio ,when exist When the vertex is within the range Mark the vertices separated by the cut and The values are assigned to different vertex subsets; the vertices on both sides of the cutting plane are classified, and the vertices The distance to the cutting plane is ,when When is the vertex on the positive side of the plane, When is the vertex on the negative side of the plane, is the distance threshold; the triangles that cross the cutting plane are split to generate a new set of triangles. The new vertex offset after splitting is calculated as ,in is the cutting plane normal vector, is the separation distance parameter; a bidirectional mapping relationship between the cutting edge vertices is established, and the mapping intensity coefficient is ,in 、 is the distance from the corresponding vertex to the cutting starting point, is the attenuation coefficient; The calculation of the pulling force or tension according to the relationship between the vertex and the triangle surface includes: For vertices and contains The formula for calculating the tension on the triangular surface is ,in is the deformation variable of the triangle surface, is the initial area of the triangle, is the tensile coefficient; tension The calculation of the distance between the vertex and each side of the triangle is based on the tension. The formula is ,in It is the ratio of the distance from the vertex to each edge of the triangle to the length of the triangle edge.
Citation Information
Patent Citations
Method and system for surgical planning based on three-dimensional model
CN103345568A
Automatic edge cutting generation method based on normal direction of placeholder triangular patch
CN110706350A
Soft tissue deformation and cutting simulation method based on extension position dynamics
CN114724722A
Head and neck tumor operation simulation training system based on UE5 engine
CN119091708A
Virtual operation simulation method based on grid adaptive cutting and subdivision
CN119418942A