A quadrilateral mesh lightweight method, system, storage medium and device
By converting triangular meshes into initial quadrilateral meshes and combining local operation sets with tangent space smoothing, along with feature line preservation and adaptive density control, the structural sensitivity and feature preservation issues in the quadrilateral mesh simplification process of existing technologies are resolved, achieving efficient mesh lightweighting.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BELTECNO CORP
- Filing Date
- 2025-12-30
- Publication Date
- 2026-06-02
AI Technical Summary
In existing technologies, triangular mesh simplification algorithms suffer from insufficient simplification quality, processing efficiency, and model versatility in 3D design of process plants. Quadrilateral mesh simplification is susceptible to structural sensitivity and lacks effective feature preservation mechanisms and adaptive density adjustment capabilities, making it difficult to meet the lightweight requirements of complex plant models.
The triangular mesh is converted into an initial quadrilateral mesh. The optimization objective is to minimize the variance of the side length and diagonal length. By combining local operation sets and tangent space smoothing, the number of faces is gradually reduced while maintaining the geometric structure. The mesh density in different regions is adjusted by combining feature line preservation and adaptive density control.
It improves the structural regularity and geometric fidelity of the simplified mesh, effectively overcomes the mesh degradation problem caused by traditional global folding methods, and achieves efficient lightweight processing.
Smart Images

Figure CN121437810B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of graphics modeling technology, specifically to a method, system, storage medium, and device for lightweighting quadrilateral meshes. Background Technology
[0002] The 3D design integration of process plants involves collaboration among multiple disciplines, including equipment, piping, and instrumentation. The mechanical equipment models come from diverse sources and formats, often containing numerous detailed geometric features. These high-precision models face the challenge of excessive data volume in integration, construction, and operation and maintenance applications. Therefore, lightweighting the models is of significant engineering importance.
[0003] Currently, the industry commonly uses triangular meshes as a representation of 3D models and reduces the number of faces through mesh simplification techniques. Common simplification algorithms such as edge shrinking and vertex aggregation have significant limitations in terms of simplification quality, processing efficiency, and model versatility, making it difficult to meet the lightweight requirements of complex factory models.
[0004] While quadrilateral meshes offer advantages such as good structural regularity and ease of parameterization in fields like CAD modeling and finite element analysis, their simplification process is susceptible to structural sensitivity, and existing methods have significant drawbacks: global folding methods lead to abrupt resolution changes and coarse control granularity; vertex valence optimization methods struggle to preserve geometric features; and the lack of effective feature preservation mechanisms and adaptive density adjustment capabilities limits their application in practical engineering. Summary of the Invention
[0005] In view of the shortcomings of the prior art, the purpose of this invention is to provide a lightweight method, system, storage medium and device for quadrilateral grids, which aims to solve the above-mentioned problems described in the prior art.
[0006] A first aspect of the present invention is to provide a method for lightweighting quadrilateral meshes, the method comprising:
[0007] Receive an input mesh; if the input mesh is a triangular mesh, convert the triangular mesh into an initial quadrilateral mesh.
[0008] The initial quadrilateral mesh is iteratively optimized by minimizing the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective.
[0009] During the iterative optimization process, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining the geometry.
[0010] Combining feature line preservation with adaptive density control based on user-defined density functions to preserve geometric features and adjust mesh density in different regions;
[0011] During the iterative optimization process, when the preset termination condition is met, the lightweight target quadrilateral mesh is output.
[0012] The local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures.
[0013] The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations.
[0014] According to one aspect of the above technical solution, during the iterative optimization process, the step of collaboratively executing local operation sets and tangent space smoothing to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining the geometric structure includes:
[0015] Based on the current side length distribution of the initial quadrilateral mesh, select the shortest side or diagonal, and perform the corresponding side folding or diagonal folding operation to coarse it;
[0016] The system triggers local tangent space smoothing based on the spring-mass model, and optimizes the side length distribution of local regions in the initial quadrilateral mesh by dynamically adjusting vertex positions, thereby providing guidance for operation selection in the next iteration.
[0017] According to one aspect of the above technical solution, after performing the edge folding or diagonal folding operation and triggering local tangent space smoothing, it also includes...
[0018] Identify and remove vertices with a valence of 2 resulting from folding operations to eliminate beaded structures;
[0019] And identify and repair all non-quadrilateral degenerate patches caused by folding operations to eliminate monoliths.
[0020] According to one aspect of the above technical solution, the steps of combining feature line preservation with adaptive density control based on a user-defined density function to preserve geometric features and adjust the mesh density of different regions include:
[0021] During the iterative simplification process, the mesh vertices are snapped to the preset geometric feature lines so that the simplified mesh can retain the original sharp features and geometric contours.
[0022] The ideal local edge length is calculated based on the density function predefined by the user at the grid surface point, and the global density distribution is coordinated by normalization conditions. When the density function is less than the preset value, the local edge length is shortened to increase the patch density, and when the density function is greater than the preset value, the local edge length is lengthened to reduce the patch density.
[0023] According to one aspect of the above technical solution, the step of converting the triangular mesh into an initial quadrilateral mesh includes:
[0024] Traverse the triangular mesh and merge any two adjacent triangles in the mesh into quadrilateral patches;
[0025] For the remaining unpaired triangles after merging, a crawling pairing method is used to merge the unpaired triangles with the generated quadrilateral facets at the edges or combine them with other residual triangles until all triangle facets are processed to obtain the initial quadrilateral mesh.
[0026] According to one aspect of the above technical solution, the step of dynamically adjusting the vertex positions of the initial quadrilateral mesh based on the spring mass model for tangent space smoothing includes:
[0027] At the start of the iterative optimization process, global smoothing is applied to the entire initial quadrilateral mesh to minimize the overall side length variance and establish a uniform baseline structure.
[0028] After each local operation is performed, dynamic triggering is applied to local smoothing only for the area affected by the operation, by projecting vertices onto the tangent space of the original mesh surface to maintain geometric fidelity.
[0029] According to one aspect of the above technical solution, the step of determining whether the preset termination condition is met includes:
[0030] After each iteration, the current number of faces, the variance of side lengths, and the rate of change of the isometry objective function value of the initial quadrilateral mesh are calculated in real time.
[0031] When the number of patches drops below a preset threshold, or the variance of the side length converges to a stable range, or the rate of change of the objective function is lower than a set threshold, the preset termination condition is automatically determined to be met.
[0032] A second aspect of the present invention is to provide a lightweight quadrilateral grid system, applied to the method described in the above-mentioned technical solution, the system comprising:
[0033] The mesh conversion module is used to receive the input mesh, and if the input mesh is a triangular mesh, it converts the triangular mesh into an initial quadrilateral mesh.
[0034] The iterative optimization module is used to iteratively optimize the initial quadrilateral mesh by using the minimization of the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective.
[0035] The first processing module is used to collaboratively execute local operation sets and tangent space smoothing during the iterative optimization process, so as to gradually reduce the number of faces of the initial quadrilateral mesh and maintain the geometric structure.
[0036] The second processing module combines feature line preservation with adaptive density control based on a user-defined density function to preserve geometric features and adjust the mesh density in different regions.
[0037] The mesh output module is used to output a lightweight target quadrilateral mesh when a preset termination condition is met during the iterative optimization process.
[0038] The local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures.
[0039] The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations.
[0040] A third aspect of the present invention is to provide a readable storage medium having computer instructions stored thereon, which, when executed by a processor, implement the steps of the method described in the above-described technical solution.
[0041] A fourth aspect of the present invention is to provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the method described in the above technical solutions.
[0042] Compared with existing technologies, the advantages of using the quadrilateral grid lightweight method, system, storage medium, and device shown in this invention are as follows:
[0043] This invention receives an input mesh; if the input mesh is triangular, it converts it into an initial quadrilateral mesh. It then iteratively optimizes the initial quadrilateral mesh by minimizing the variance between the side lengths and diagonal lengths of the quadrilateral mesh as an isometry optimization objective. During this iterative optimization, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining its geometric structure. Feature line preservation and adaptive density control based on a user-defined density function are combined to preserve geometric features and adjust the mesh density in different regions. When a preset termination condition is met during the iterative optimization process, a lightweight target quadrilateral mesh is output. This invention, by introducing an isometry optimization objective centered on minimizing the variance between the side and diagonal lengths, fundamentally improves the structural regularity and geometric fidelity of the simplified mesh, effectively overcoming the mesh degradation problem caused by traditional global folding methods. Attached Figure Description
[0044] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:
[0045] Figure 1 A flowchart illustrating the quadrilateral mesh lightweighting method provided in an embodiment of the present invention;
[0046] Figure 2 This is a structural block diagram of a quadrilateral grid lightweight system provided in an embodiment of the present invention. Detailed Implementation
[0047] To make the objectives, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Several embodiments of the present invention are shown in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. Rather, these embodiments are provided so that the disclosure of the present invention will be more thorough and complete.
[0048] It should be noted that when a component is said to be "fixed to" another component, it can be directly on the other component or there may be an intervening component. When a component is said to be "connected to" another component, it can be directly connected to the other component or there may be an intervening component. The terms "vertical," "horizontal," "left," "right," and similar expressions used in this document are for illustrative purposes only.
[0049] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein in the description of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.
[0050] Example 1
[0051] Please see Figure 1 The first embodiment of the present invention provides a method for lightweighting quadrilateral meshes, which is particularly suitable for fields requiring high-quality mesh simplification, such as 3D design of process plants, digital twins, and computer animation. The method includes steps S10-S50:
[0052] Step S10: Receive the input mesh. If the input mesh is a triangular mesh, convert the triangular mesh into an initial quadrilateral mesh.
[0053] In this embodiment, the step of converting the triangular mesh into an initial quadrilateral mesh includes:
[0054] Traverse the triangular mesh and merge any two adjacent triangles in the mesh into quadrilateral patches;
[0055] For the remaining unpaired triangles after merging, a crawling pairing method is used to merge the unpaired triangles with the generated quadrilateral facets at the edges or combine them with other residual triangles until all triangle facets are processed to obtain the initial quadrilateral mesh.
[0056] Specifically, when the input model is a triangular mesh, a zero-complexity growth algorithm is used for conversion. First, the algorithm identifies and merges adjacent triangles to form a quadrilateral main frame. Then, the remaining triangles that cannot be paired are specially processed using a crawling pairing method to ensure that all triangular faces can be legally converted into quadrilateral faces.
[0057] The above conversion process not only reduces the number of patches to half or even less of the original number, but more importantly, it generates a well-structured initial quadrilateral mesh, providing an ideal topological basis for subsequent simplification operations.
[0058] Step S20: The initial quadrilateral mesh is iteratively optimized by minimizing the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective.
[0059] In this embodiment, the core of the isometry optimization objective lies in driving the mesh structure towards an ideal state through mathematical means. Its objective function consists of two key parts: the edge variance term and the diagonal variance term, mathematically expressed as:
[0060]
[0061] In the formula, e As an edge, d diagonal μ For the global average side length, through The calculation shows that |M| represents the number of faces of a given mesh surface M.
[0062] The above global average side length μ The function organically connects the geometric properties of the mesh with the optimization objective, and is based on the inherent geometric characteristics of a regular quadrilateral mesh, namely, all sides are of equal length and the diagonal length is maintained. The ideal state of the double side length relationship.
[0063] In the specific implementation process, the isometric optimization first performs global preprocessing on the initial quadrilateral mesh, specifically adopting a gradient descent-based numerical optimization method, and gradually converges the objective function value by iteratively adjusting the vertex positions.
[0064] Among them, efficient minimization of the edge variance term causes all edge lengths in the grid to tend towards the global average edge length. μ This effectively eliminates abnormally long or short sides, while optimization of the diagonal variance term ensures that the diagonal length and side length remain reasonable. The proportional relationship improved the overall quality of the mesh, laying a solid foundation for subsequent simplified operations.
[0065] The geometric principle of the above-mentioned isometry optimization can be intuitively demonstrated through an ideal mesh model. In a regular quadrilateral mesh, isometry is manifested in the uniformity of all side lengths and the proportional stability of the diagonal lengths. This characteristic provides a clear geometric objective for the optimization process.
[0066] It's important to note that, as a preprocessing step, isometric optimization and subsequent operations create a multi-layered synergistic effect. The resulting uniform edge length distribution provides an objective basis for determining the edge folding priority in local operations, while the regularized mesh structure significantly reduces the risk of topological degradation. More importantly, isometric optimization and tangent space smoothing form a good complementary relationship. The former focuses on the regularization of the macroscopic structure, while the latter focuses on maintaining the fidelity of local geometric features. Both work together to ensure mesh quality at different scales.
[0067] Step S30: During the iterative optimization process, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces of the initial quadrilateral mesh while maintaining the geometry.
[0068] In this embodiment, during the iterative optimization process, the steps of coordinating the execution of local operation sets and tangent space smoothing to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining the geometric structure include:
[0069] Based on the current side length distribution of the initial quadrilateral mesh, select the shortest side or diagonal, and perform the corresponding side folding or diagonal folding operation to coarse it;
[0070] The system triggers local tangent space smoothing based on the spring-mass model, and optimizes the side length distribution of local regions in the initial quadrilateral mesh by dynamically adjusting vertex positions, thereby providing guidance for operation selection in the next iteration.
[0071] In this embodiment, the local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures.
[0072] The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations.
[0073] The step of dynamically adjusting the vertex positions of the initial quadrilateral mesh based on the spring-mass model for tangent space smoothing includes:
[0074] At the start of the iterative optimization process, global smoothing is applied to the entire initial quadrilateral mesh to minimize the overall side length variance and establish a uniform baseline structure.
[0075] After each local operation is performed, dynamic triggering is applied to local smoothing only for the area affected by the operation, by projecting vertices onto the tangent space of the original mesh surface to maintain geometric fidelity.
[0076] In this embodiment, the number of mesh patches is gradually reduced while maintaining geometric quality through the alternating and coordinated operation of the local operation set and the tangent space smoothing mechanism. Specifically, the local operation set includes three types of operations with specific functions, which are dynamically selected and executed during the iteration process based on the current state of the mesh:
[0077] Firstly, the optimization operation mainly targets the fine-tuning of the mesh topology, including two specific forms: edge rotation and vertex rotation. The edge rotation operation shortens the excessively long diagonal by adjusting the position of the shared edge of two adjacent quadrilaterals, while the vertex rotation optimizes the distribution of vertex valence in the local area by changing the connection relationship of vertices. The aim is to improve the mesh quality without reducing the number of mesh patches, thus creating favorable conditions for subsequent coarsening operations.
[0078] Secondly, coarsening is a key step in achieving lightweighting. It reduces the number of faces by using two methods: edge folding and diagonal folding. Edge folding selects the shortest edge in the mesh for folding, merges adjacent vertices, and removes a quadrilateral face. Diagonal folding, on the other hand, operates on the diagonal of the quadrilateral face, directly removing a quadrilateral face. These operations are based on the edge length distribution information provided by the isometric optimization results, prioritizing the processing of the shortest edge or diagonal to minimize geometric distortion.
[0079] Third, the cleanup operation is responsible for maintaining the topological validity of the mesh. It is executed automatically after each coarsening operation and can remove vertices with a valence of 2 caused by the folding operation, eliminate double vertices, repair non-quadrilateral patches formed by degeneration, and eliminate single vertices, thereby ensuring that the mesh maintains a good topological structure throughout the simplification process.
[0080] In this embodiment, tangent space smoothing, as a key technology in conjunction with local operations, achieves dynamic optimization of vertex positions based on a spring-mass model. This mechanism operates in two modes:
[0081] The global smoothing mode is executed once at the beginning of the iteration process and applies to the entire mesh. Its goal is to establish a uniform initial structure distribution by adjusting the position of all vertices so that the edge and diagonal lengths are as close as possible to the ideal values defined in the equidistant optimization objective.
[0082] The local smoothing mode is triggered after each local operation. It optimizes vertex positions only for the local area affected by the operation. It preserves geometric features by projecting vertices into the tangent space of the original mesh surface. At the same time, it uses the physical simulation principle of the spring mass model to simulate the elastic adjustment process of the side length, so that the mesh quality of the local area is improved in real time.
[0083] It should be noted that the collaboration between local operations and tangent space smoothing involves first evaluating the current mesh state in each iteration cycle, selecting the most suitable local operation type based on the edge length distribution characteristics, and immediately triggering tangent space smoothing of the local region after executing the selected operation, thereby optimizing the local geometric features by dynamically adjusting the vertex positions.
[0084] Step S40 combines feature line preservation with adaptive density control based on a user-defined density function to preserve geometric features and adjust the mesh density in different regions.
[0085] In this embodiment, the steps of combining feature line preservation with adaptive density control based on a user-defined density function to preserve geometric features and adjust the mesh density of different regions include:
[0086] During the iterative simplification process, the mesh vertices are snapped to the preset geometric feature lines so that the simplified mesh can retain the original sharp features and geometric contours.
[0087] The ideal local edge length is calculated based on the density function predefined by the user at the grid surface point, and the global density distribution is coordinated by normalization conditions. When the density function is less than the preset value, the local edge length is shortened to increase the patch density, and when the density function is greater than the preset value, the local edge length is lengthened to reduce the patch density.
[0088] Specifically, in this embodiment, a dual mechanism is used to achieve precise preservation of geometric features and regional density adjustment. This step operates dynamically during the iterative simplification process, ensuring that important geometric features are not destroyed while allowing users to set different simplification intensities for different regions.
[0089] Feature preservation is achieved through a constraint-based vertex snapping algorithm. First, it identifies user-predefined geometric feature lines, such as sharp edges and curved boundaries in CAD models. Before each local operation, the spatial relationship between the operation area and the feature lines is detected. When a vertex enters the influence range of a feature line, a position constraint mechanism is automatically triggered. This process is implemented by defining a feature attraction function. This function dynamically adjusts the snapping strength based on the distance between the vertex and the feature line, ensuring that the mesh density near the feature lines is maintained during simplification. The feature preservation mechanism is closely related to local operations, and its implementation relies on precise control of the mesh topology. In practical applications, feature line preservation not only includes the maintenance of edge features but also extends to feature preservation in areas with significant curvature changes. By combining curvature analysis and feature line detection algorithms, high-feature regions in the geometric model can be automatically identified and protected, significantly reducing the workload of manual annotation.
[0090] Furthermore, the core of adaptive density control is an adjustment mechanism based on a user-defined density function λ(p). This function defines the ideal edge length ratio at any point p on the mesh surface, where λ(p) represents the ratio of the ideal edge length at that point to the global average edge length μ. The specific adjustment rules are as follows:
[0091] When λ(p) < 1, the actual side length of the region is shortened by adjusting the local operation to increase the patch density;
[0092] When λ(p) > 1, appropriately lengthen the local side length to reduce the number of facets;
[0093] When λ(p)=1, the standard density is maintained, following the global simplification strategy.
[0094] Furthermore, to ensure that the mesh after local density adjustment maintains global physical consistency, normalization constraints are also introduced:
[0095]
[0096] The above mathematical constraints coordinate the density differences in different regions, preventing mesh quality imbalance caused by excessive simplification or refinement in certain areas.
[0097] It should also be noted that feature preservation and density control work together through the following process:
[0098] First, an operation permission map is generated based on the feature line distribution and the density function λ(p) value, marking the types and intensities of simplification operations allowed in different regions. During iterative simplification, the selection of local operations considers not only geometric optimization factors but is also subject to the dual constraints of feature preservation priority and density requirements. Specifically, in high-feature regions (i.e., where λ(p) values are small), the frequency of coarsening operations is limited, and optimization operations are prioritized to improve mesh quality. In non-feature regions (i.e., where λ(p) values are large), more aggressive simplification strategies are allowed. This differentiated approach ensures a balance between feature preservation and simplification efficiency.
[0099] Step S50: When the preset termination condition is met during the iterative optimization process, output the lightweight target quadrilateral mesh.
[0100] In this embodiment, the step of determining whether the preset termination condition is met includes:
[0101] After each iteration, the current number of faces, the variance of side lengths, and the rate of change of the isometry objective function value of the initial quadrilateral mesh are calculated in real time.
[0102] When the number of patches drops below a preset threshold, or the variance of the side length converges to a stable range, or the rate of change of the objective function is lower than a set threshold, the preset termination condition is automatically determined to be met.
[0103] Specifically, among the preset termination conditions, the face number threshold criterion is the most basic. Users can preset the target face number or simplification ratio. When the current face number is detected to reach or fall below the set threshold, the termination procedure is automatically triggered. The geometric quality convergence criterion is based on the isometric optimization objective function. By monitoring the rate of change of the objective function value during adjacent iteration cycles, when the rate of change is lower than the preset tolerance, the mesh geometry is considered to have stabilized. The process stability criterion is achieved by analyzing the changes in the success rate of local operations. In consecutive iterations, when the number of executable legal operations decreases significantly or the operation effect tends to saturate, the simplification process is determined to have entered the diminishing returns stage, and termination is performed even if the face number threshold has not been reached.
[0104] This step, through intelligent termination judgment and strict quality control, ensures that while achieving the ideal simplification effect, the visual fidelity and structural integrity of the geometric model are maintained to the greatest extent.
[0105] Compared with existing technologies, the lightweight quadrilateral mesh method shown in this embodiment has the following advantages:
[0106] This embodiment receives an input mesh. If the input mesh is a triangular mesh, it is converted into an initial quadrilateral mesh. The initial quadrilateral mesh is iteratively optimized by minimizing the variance between the side lengths and diagonal lengths of the quadrilateral mesh as the isometry optimization objective. During the iterative optimization process, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining its geometric structure. Feature line preservation and adaptive density control based on a user-defined density function are combined to preserve geometric features and adjust the mesh density in different regions. When a preset termination condition is met during the iterative optimization process, a lightweight target quadrilateral mesh is output. This embodiment, by introducing an isometry optimization objective centered on minimizing the variance between the side and diagonal lengths, fundamentally improves the structural regularity and geometric fidelity of the simplified mesh, effectively overcoming the mesh degradation problem caused by traditional global folding methods.
[0107] Example 3
[0108] Please see Figure 2 A second embodiment of the present invention provides a lightweight quadrilateral mesh system applied to the method described in the above embodiments, the system comprising:
[0109] The mesh conversion module 10 is used to receive an input mesh, and if the input mesh is a triangular mesh, it converts the triangular mesh into an initial quadrilateral mesh.
[0110] The iterative optimization module 20 is used to iteratively optimize the initial quadrilateral mesh by using the minimization of the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective.
[0111] The first processing module 30 is used to collaboratively execute local operation sets and tangent space smoothing during the iterative optimization process, so as to gradually reduce the number of faces of the initial quadrilateral mesh and maintain the geometric structure.
[0112] The second processing module 40 is used to combine feature line preservation with adaptive density control based on a user-defined density function to preserve geometric features and adjust the mesh density of different regions.
[0113] Mesh output module 50 is used to output a lightweight target quadrilateral mesh when a preset termination condition is met during the iterative optimization process.
[0114] The local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures.
[0115] The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations.
[0116] Compared with existing technologies, the advantages of using the quadrilateral mesh lightweight system shown in this embodiment are as follows:
[0117] This embodiment receives an input mesh. If the input mesh is a triangular mesh, it is converted into an initial quadrilateral mesh. The initial quadrilateral mesh is iteratively optimized by minimizing the variance between the side lengths and diagonal lengths of the quadrilateral mesh as the isometry optimization objective. During the iterative optimization process, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining its geometric structure. Feature line preservation and adaptive density control based on a user-defined density function are combined to preserve geometric features and adjust the mesh density in different regions. When a preset termination condition is met during the iterative optimization process, a lightweight target quadrilateral mesh is output. This embodiment, by introducing an isometry optimization objective centered on minimizing the variance between the side and diagonal lengths, fundamentally improves the structural regularity and geometric fidelity of the simplified mesh, effectively overcoming the mesh degradation problem caused by traditional global folding methods.
[0118] Example 3
[0119] A third embodiment of the present invention provides a readable storage medium having computer instructions stored thereon, which, when executed by a processor, implement the steps of the methods described in the above embodiments.
[0120] Example 4
[0121] A fourth embodiment of the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the methods described in the above embodiments.
[0122] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0123] The embodiments described above are merely illustrative of several implementations of the present invention, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these modifications and improvements all fall within the scope of protection of the present invention. Therefore, the scope of protection of this patent should be determined by the appended claims.
Claims
1. A method for lightweighting quadrilateral meshes, characterized in that, The method includes: Receive an input mesh; if the input mesh is a triangular mesh, convert the triangular mesh into an initial quadrilateral mesh. The initial quadrilateral mesh is iteratively optimized by minimizing the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective. The objective function for isometry optimization is: ; In the formula, e As an edge, d diagonal μ For the global average side length, through The calculation shows that |M| represents the number of faces of a given mesh surface M; During the iterative optimization process, local operation sets and tangent space smoothing are performed collaboratively to gradually reduce the number of faces in the initial quadrilateral mesh while maintaining the geometry. The mesh vertices are snapped to the preset geometric feature lines so that the mesh can maintain its original sharp features and geometric contours. The local ideal edge length is calculated based on the density function predefined by the user at the grid surface point, and the global density distribution is coordinated by the normalization condition. When the density function is less than the preset value, the local edge length is shortened to increase the patch density, and when the density function is greater than the preset value, the local edge length is lengthened to reduce the patch density. After each iteration, the current number of faces, the variance of side lengths, and the rate of change of the isometry optimization objective function of the initial quadrilateral mesh are calculated in real time. When the number of faces drops below a preset threshold, or the variance of side lengths converges to a stable interval, or the rate of change of the objective function is lower than a set threshold, the preset termination condition is automatically met, and the lightweight target quadrilateral mesh is output. Specifically, the convergence of the variance of side lengths to a stable interval adopts a gradient descent-based numerical optimization method, which iteratively adjusts the vertex positions to gradually converge the objective function value, causing all side lengths in the mesh to tend towards the global average side length. μ This effectively eliminates abnormal edges that are too long or too short. The local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures. The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations, including: At the start of the iterative optimization process, global smoothing is applied to the entire initial quadrilateral mesh to minimize the overall side length variance and establish a uniform baseline structure. After each local operation is performed, dynamic triggering is applied to local smoothing only for the area affected by the operation, by projecting vertices onto the tangent space of the original mesh surface to maintain geometric fidelity.
2. The lightweight quadrilateral mesh method according to claim 1, characterized in that, During iterative optimization, the steps of coordinating the execution of local operation sets and tangent space smoothing to gradually reduce the number of faces in the initial quadrilateral mesh while preserving the geometry include: Based on the current side length distribution of the initial quadrilateral mesh, select the shortest side or diagonal, and perform the corresponding side folding or diagonal folding operation to coarse it; The system triggers local tangent space smoothing based on the spring-mass model, and optimizes the side length distribution of local regions in the initial quadrilateral mesh by dynamically adjusting vertex positions, thereby providing guidance for operation selection in the next iteration.
3. The quadrilateral mesh lightweighting method according to claim 2, characterized in that, After performing the edge folding or diagonal folding operation and triggering local tangent space smoothing based on the spring mass model, the method further includes: Identify and remove vertices with a valence of 2 resulting from folding operations to eliminate beaded structures; Identify and repair all non-quadrilateral degenerate patches caused by folding operations to eliminate singletons.
4. The lightweight quadrilateral mesh method according to claim 1, characterized in that, The step of converting the triangular mesh into an initial quadrilateral mesh includes: Traverse the triangular mesh and merge any two adjacent triangles in the mesh into quadrilateral patches; For the remaining unpaired triangles after merging, a crawling pairing method is used to merge the unpaired triangles with the generated quadrilateral facets at the edges or combine them with other residual triangles until all triangle facets are processed to obtain the initial quadrilateral mesh.
5. A lightweight quadrilateral grid system, characterized in that, The system, applicable to the method of any one of claims 1-4, comprises: A mesh conversion module is used to receive an input mesh, and if the input mesh is a triangular mesh, convert the triangular mesh into an initial quadrilateral mesh. The iterative optimization module is used to iteratively optimize the initial quadrilateral mesh by using the minimization of the variance between the side length and the diagonal length of the quadrilateral mesh as the isometry optimization objective. The first processing module is used to collaboratively execute local operation sets and tangent space smoothing during iterative optimization to gradually reduce the number of faces of the initial quadrilateral mesh while maintaining the geometric structure. The second processing module is used to perform feature line preservation and implement adaptive density control based on user-defined density functions to preserve geometric features and adjust the mesh density in different regions. The mesh output module is used to output a lightweight target quadrilateral mesh when a preset termination condition is met during the iterative optimization process. The local operation set includes optimization operations for adjusting the mesh topology, coarsening operations for reducing the number of patches, and cleaning operations for cleaning up degenerate structures. The tangent space smoothing dynamically adjusts the vertex positions of the initial quadrilateral mesh based on a spring-mass model to maintain geometric fidelity and guide the selection of subsequent local operations.
6. A readable storage medium having computer instructions stored thereon, characterized in that, When executed by the processor, this instruction implements the steps of the method as described in any one of claims 1-4.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method as described in any one of claims 1-4.
Citation Information
Patent Citations
Direction field-based quadrilateral grid generation method
CN117745972A
Singularity reduction in quadrilateral meshes
US20180101983A1