A heterogeneous multi-material continuous scaling mapping method based on STL model synchronous slicing and constraint CDT
Patent Information
- Application Number
- CN202610951520.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-29
- Publication Date
- 2026-09-25
AI Technical Summary
[0005]针对现有技术的不足,本发明的目的在于提供一种基于STL模型同步切片与约束CDT的异质多材料比例连续映射方法,解决现有技术中STL模型无法承载材料属性、多模型切片易错位、材料边界表达精度低、材料界面缺乏连续过渡能力的技术问题,在兼容标准STL格式的基础上,实现材料区域、材料界面与材料比例在切片层内的统一、精准、连续映射
1.本发明采用统一切片高度序列对主体模型与所有材料分区模型执行同步切片,从根源上避免了切片高度差异导致的材料区域与主体几何的层间错位问题;配合二维布尔求交运算自动裁剪超出主体范围的材料区域,并自动划分默认材料区域,保证了零件实体内部材料分区的完整性与准确性。
Smart Images

Figure CN122818638A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of additive manufacturing and multi-material digital modeling technology, specifically to a slicing mapping method for heterogeneous multi-material distribution, and more particularly to a method for continuous proportional mapping of heterogeneous multi-materials based on synchronous slicing of STL model and constrained CDT. Background Technology
[0002] STL (StereoLithography) models are discretized geometric models that describe the outer surface of a 3D solid using a set of triangular facets. Due to their simple data structure, unified format, and strong compatibility, they have become a common input format in the fields of additive manufacturing and rapid prototyping. With the rapid development of heterogeneous multi-material additive manufacturing technology, the demand for manufacturing functionally graded materials and multi-component composite parts is increasing, and the accurate representation of material distribution has become a core prerequisite for multi-material manufacturing.
[0003] However, standard STL models only record the geometric boundary information of entities and do not contain attribute information such as material type, material distribution, and material proportion. Therefore, they cannot directly support multi-material design results and require an additional mapping process to combine material information with the geometric model. Currently, mainstream multi-material modeling and mapping methods mainly suffer from the following drawbacks: Firstly, although material representation methods based on voxels or implicit functions can achieve continuous material representation, they have high computational and storage overhead, are incompatible with standard STL geometry formats, and cannot be directly integrated with existing slicing and manufacturing systems. Secondly, the partitioning method based on the superposition of multiple STL models describes different material regions through independent models. This is prone to problems such as spatial misalignment and boundary mismatch due to inconsistent coordinate systems and slice heights, making it difficult to guarantee the fitting accuracy between the material region and the main geometry. Third, the post-processing method of assigning values after slicing only divides the cross-sectional region into discrete material labels, lacks geometric constraints on the material interface, has a rough boundary expression, and the material properties are in an abrupt state at the interface, making it impossible to achieve a continuous transition and difficult to meet the fine modeling requirements of graded functional materials.
[0004] Furthermore, existing two-dimensional discretization methods within slice layers often employ regular grid structures. When dealing with complex material partitions and part structures containing holes, these methods suffer from low boundary fitting accuracy and poor topological stability, failing to simultaneously ensure geometric accuracy and material property representation. Therefore, there is an urgent need to develop a multi-material slice mapping method that is compatible with standard STL format, has high spatial matching accuracy, preserves boundary features completely, and enables continuous transitions in material proportions. Summary of the Invention
[0005] To address the shortcomings of existing technologies, the present invention aims to provide a method for continuous mapping of heterogeneous multi-material proportions based on synchronous slicing of STL models and constrained CDT, thereby solving the technical problems in existing technologies such as the inability of STL models to bear material properties, easy misalignment of multi-model slices, low accuracy of material boundary representation, and lack of continuous transition capability of material interfaces. While being compatible with the standard STL format, the invention achieves unified, accurate, and continuous mapping of material regions, material interfaces, and material proportions within the slice layer.
[0006] To achieve the above-mentioned objectives, this invention provides a method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT, comprising the following steps: S1: Input the main STL model and at least one material partition STL model; S2: Preprocess all input STL models; S3: Establish a unified slice height sequence; S4: Based on the unified slice height sequence, slice the main body STL model and each material partition STL model at the same slice height to obtain the main body cross-sectional area and each material partition cross-sectional area. S5: Perform a two-dimensional Boolean intersection operation between each material partition section region and the main section region to obtain the effective material region corresponding to each material, and determine the default material region within the main section region; S6: Extract the main cross-sectional boundary of the current slice layer and the boundaries of each effective material region to form a set of constraint edges; use the set of constraint edges as a forced constraint condition to construct a constrained Delaunay triangulation mesh inside the main cross-sectional region; S7: Determine the material region attribution for the vertices or sampling points inside the constrained Delaunay triangulation mesh; S8: Calculate the signed distance from each vertex or sampling point to the boundary of the corresponding material region, and calculate the continuous material ratio at each vertex or sampling point based on the signed distance; S9: Normalize the proportions of all materials at each vertex or sampling point; S10: After traversing all slice heights and completing the corresponding processing, output the complete heterogeneous multi-material slice layer dataset.
[0007] Preferably, the main body STL model is used to represent the overall geometric region of the part, and the material partition STL model is used to represent the distribution region of the corresponding material in three-dimensional space.
[0008] Preferably, the preprocessing in step S2 includes geometric repair processing and spatial consistency verification; the geometric repair processing includes removing duplicate faces, removing degenerate faces, cleaning up unreferenced vertices, repairing face normals, and checking model closure; the spatial consistency verification is used to confirm that all models are in the same coordinate system, the same unit scale, and have the correct relative positional relationship.
[0009] Preferably, in step S3, the unified slice height sequence is established based on the height direction distribution range of the main STL model and the preset slice layer thickness, and all STL models use this unified slice height sequence to perform slicing operations.
[0010] Preferably, in step S5, the effective material region is the intersection of the material partition section region and the main section region; the default material region is the complement of all effective material regions within the main section region.
[0011] Preferably, in step S6, the set of constraint edges further includes the hole boundaries of the main cross section; after the material region boundary is embedded as a constraint edge in the meshing process, the generated triangular mesh can accurately preserve the geometric features of the material interface and avoid the boundary from shifting during the discretization process.
[0012] Preferably, the attribution determination rule for step S7 is as follows: if a vertex or sampling point is located within a certain effective material region, it is assigned to the corresponding material region; if a vertex or sampling point does not belong to any effective material region, it is assigned to the default material region.
[0013] Preferably, in step S8, the calculation rule for the signed distance is as follows: when the point is located inside the material region, the signed distance is taken as the positive value of the Euclidean distance from the point to the boundary of the material region; when the point is located outside the material region, the signed distance is taken as the negative value of the Euclidean distance from the point to the boundary of the material region.
[0014] Preferably, in step S8, a normalized parameter is calculated by combining the preset material transition zone width and the signed distance, and then the continuously changing material ratio is calculated by a smoothing function, so that the material ratio can achieve a smooth transition within the interface transition zone.
[0015] Preferably, the multi-material slice layer data of a single slice layer includes slice height, main cross-sectional area, effective material area, default material area, constrained Delaunay triangulation mesh, material interface, signed distance calculation results, material scale value and normalization results.
[0016] The present invention has the following beneficial effects: 1. This invention employs a unified slice height sequence to perform synchronous slicing on the main model and all material partition models, fundamentally avoiding the problem of interlayer misalignment between material regions and the main geometry caused by differences in slice height; combined with two-dimensional Boolean intersection operation to automatically trim material regions exceeding the main body range and automatically divide default material regions, ensuring the integrity and accuracy of material partitioning within the part entity.
[0017] 2. This invention uses the main cross-sectional boundary, the hole boundary, and the material region boundary as forced constraint edges to construct a CDT mesh, so that the generated triangular mesh strictly fits various boundary features, effectively avoiding the material boundary from shifting, becoming blurred, or being lost during the mesh discretization process. It can still guarantee the geometric accuracy and topological stability of the material interface under complex shapes and structures containing holes.
[0018] 3. This invention calculates the signed distance from the point to the material interface and combines the transition zone width with a smooth function mapping to obtain the continuous material ratio. This allows the material ratio to change continuously and smoothly within the interface transition region, eliminating the abrupt change in material properties caused by traditional discrete partitioning methods. It significantly improves the continuous expressive ability of heterogeneous multi-material models and can adapt to the refined modeling needs of graded functional materials.
[0019] 4. This invention directly uses the general standard STL model as input, without modifying the data structure and format of the existing 3D model. It can seamlessly connect with mainstream 3D modeling software, slicing systems and additive manufacturing equipment, and has low difficulty in engineering implementation and system integration.
[0020] 5. This invention outputs full data, including geometric regions, constraint meshes, material interfaces, and continuous scale fields, on a slice-by-slice basis. It can provide complete data support for scanning path planning, nozzle flow control, and process parameter matching in heterogeneous multi-material additive manufacturing, and has strong engineering application value. Attached Figure Description
[0021] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0022] Figure 1 This is a schematic diagram of the overall process of the method described in this invention.
[0023] Figure 2 This is a detailed algorithm flowchart of the method described in this invention.
[0024] Figure 3 This is a schematic diagram of the cross-sectional material ratio distribution according to an embodiment of the present invention. Detailed Implementation
[0025] The technical solutions of the present invention will be clearly and completely described below with reference to the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.
[0026] Example 1: See Figure 1 This invention provides a method for continuous scaling of heterogeneous multi-materials based on simultaneous slicing of STL models and constrained CDT, comprising the following steps: S1: Input the main STL model and the material partition STL model; S2: Preprocessing the main model and material partitioning model; S3: Establish a unified slice height sequence Z 1, Z 2, ..., Z n ; S4: At the same slice height Z i Down-synchronous slicing; S5: Perform a two-dimensional Boolean intersection of the main cross section and the material cross section to determine the default material region; S6: Extract the main body boundary, hole boundary, and material region boundary, and construct a constrained CDT mesh within the slice layer; S7: Determine the material region for CDT vertices or sampling points; S8: Calculate the signed distance from the point to the material interface, and calculate the material proportion based on the signed distance and the transition zone width; S9: Normalize the material ratio; S10: Output multi-material slice layer data.
[0027] Example 2: See Figure 2 This embodiment takes dual-material gradient functional parts as a typical application scenario, and elaborates on the complete execution process of this method in detail. It also covers the general calculation rules for multiple materials and includes all the operation steps of this method.
[0028] 1. Model Input The method of this invention inputs a main body STL model and at least one material partition STL model. The main body STL model is used to represent the overall geometric region of the part, denoted as... Material partitioning STL models are used to represent the distribution region of a specified material in three-dimensional space, denoted as . ,in , This indicates the number of material partitioning models. In the case of two materials, a single material partitioning STL model can be input. This represents material region A; the portion of the main model not covered by this material partition is used as the default material region B.
[0029] This embodiment specifically uses one main body STL model and one material partition STL model: Main STL model Define the overall geometric boundaries of the part for a cuboid model with dimensions of 10mm×10mm×20mm; Material partitioning STL model The model is a cylinder with a diameter of 6mm and a height of 20mm, corresponding to the spatial distribution area of the first functional material (material A), and the number of material partitions. The area not covered by the main body is the default material B area.
[0030] 2. Model Preprocessing Geometric preprocessing is performed on the main STL model and the material partition STL model, mainly including: removing duplicate faces, removing degenerate faces, cleaning up unreferenced vertices, repairing face normals, checking model closure, and checking the model bounding box. Simultaneously, spatial consistency checks are performed on the main STL model and the material partition STL model to ensure they are in the same coordinate system, the same unit scale, and have the correct relative positional relationship. If the material partition model does not overlap spatially with the main model, the material partition will not participate in subsequent material mapping; if they overlap spatially, the synchronous slicing step is initiated.
[0031] In this embodiment, the two STL models are sequentially subjected to deduplication of faces, elimination of degenerate faces with side lengths less than 0.001 mm, cleanup of redundant vertices, unification of normals outward, closure verification and bounding box calculation. After spatial consistency verification, both models are in the world coordinate system, with units in millimeters, and the cylinder is coaxially nested inside the cuboid. The spatial overlap area is complete and meets the conditions for subsequent calculations.
[0032] 3. Establish a unified slice height sequence Based on the height range of the main STL model and the preset layer thickness, a unified slice height sequence is established: ; The main STL model and all material partition STL models use the same slice height sequence. This ensures that the main body section and the material section are treated at the same height, avoiding interlayer misalignment between the material area and the main body geometric area.
[0033] In this embodiment, the preset slice layer thickness is 0.1mm, and the height range of the main STL model is 0mm~20mm. The total number of layers is calculated. , No. Layer slice height ( ).
[0034] 4. Synchronous slicing For any slice height Horizontal slices were then applied to both the main STL model and the material partitioning STL model. The main STL model was sliced in the [number missing]th [section missing]. i The cross-sectional region of the layer is: ; No. k The material partitioning STL model in the first... i The cross-sectional region of the layer is: ; in, Indicates the first The main cross-sectional area of the layer, Indicates the first The first in the layer Each material partition section area. Through synchronous slicing, the main geometric area and the material partition area can be processed uniformly within the same slice layer.
[0035] In this embodiment, the main cross-section The material is divided into sections for a rectangular area of 10mm × 10mm. It is a circular region with a diameter of 6mm, and the two are located in the same two-dimensional plane.
[0036] 5. Two-dimensional Boolean intersection and determination of default material region Main cross-sectional area Material partition cross-sectional area Perform a two-dimensional Boolean intersection to obtain the effective material region: ; in, Indicates the first The first layer The effective area of the material.
[0037] The portion of the main cross-section not covered by any material partition is defined as the default material region. : ; This step automatically trims the portion of the material area that extends beyond the main body, while the portion of the main body without a specified material is automatically assigned to the default material area.
[0038] In this embodiment, the circular material partition is entirely located inside the rectangular main body, therefore the effective material area... Consistent with the cross-section of the raw material partition; the area outside the circle within the rectangular area is the default material area. .
[0039] 6. Construct constrained CDT mesh In the current slice layer, the following boundary information is extracted: the outer boundary of the main cross-section, the hole boundary of the main cross-section, and the boundary of the effective material region. These boundaries are collectively used as a set of constraint edges, denoted as... .
[0040] ; Subsequently, a constrained Delaunay triangulation mesh, i.e., a constrained CDT mesh, is constructed within the main cross-sectional region: ; in, Indicates the first The CDT mesh of the layer can be represented as: ; in Represents the CDT vertex set. This represents the CDT triangular unit set.
[0041] By including the material region boundary as a constraint edge in the CDT mesh construction, the generated intralayer mesh can simultaneously represent the main geometric boundary and the material region boundary, avoiding the material boundary from shifting or being lost during the mesh discretization process.
[0042] In this embodiment, the part has no internal holes, so the set of constraint edges includes the rectangular outer boundary and the circular material region boundary; based on the CDT mesh generated by the above constraint edges, all triangular elements do not cross the circular material boundary, and the geometric features of the material interface are completely preserved.
[0043] 7. Determination of Material Region Attribution For any vertex or sampling point in the constrained CDT mesh Determine its relationship with each effective material region. The positional relationship. If Then point Belongs to the A material area. If point If it does not belong to any valid material area, then point Belongs to the default material area .
[0044] In the case of two materials, it can be understood as: point When located within region A, material A dominates; point When located outside of material A region, material B is predominant by default; point When located near the material interface, continuous scaling calculations are required.
[0045] In this embodiment, the grid vertices located inside the circular area belong to material A area, while the vertices located outside the circular area and inside the rectangle belong to the default material B area. The vertices around the interface are included in the subsequent continuous ratio calculation.
[0046] 8. Material ratio calculation based on signed distance For CDT vertices or sampling points Calculate the signed distance from it to the boundary of the material region. The boundaries of each material region are: ; point To the The signed distance of each material interface is: ; in, Point The shortest Euclidean distance to the boundary of the material region.
[0047] Let the width of the material transition zone be... Then, the normalization parameters are constructed based on the signed distance: ; In a preferred embodiment, a smoothing function is used to calculate the material ratio: ; in, Point First The formula determines the proportion of materials. This formula ensures that the material proportion is close to 1 inside the material region, close to 0 outside the material region, and changes continuously and smoothly near the material interface.
[0048] This embodiment pre-determines the total width of the material transition zone. The transition zone extends 0.25 mm outwards and inwards from the circular material boundary. After calculation using the above formula, the proportion of material A approaches 1 in the inner part of the circle far from the boundary, continuously decreases from 1 to 0 in the transition zone, and remains 0 in the outer part of the circle far from the boundary, without any abrupt steps.
[0049] 9. Material proportion normalization treatment For multi-material situations, point The material proportion at a given location can be represented as a material proportion vector: ; in, This indicates the default material ratio. Indicates the first The proportion of various materials.
[0050] The material proportions are normalized so that the sum of all material proportions is 1: ; This embodiment is a dual-material scenario, and the default proportion of material B meets the following conditions. It automatically satisfies the normalization conditions; for complex scenarios with multiple overlapping materials, this normalization operation can ensure the physical rationality of the material ratio.
[0051] 10. Multi-material slice layer data output After calculating the material ratio of the current slice layer, output the multi-material slice layer data for that layer. Each slice layer of data can be represented as : ; These include: slice height, main cross-sectional area, effective material area, default material area, constrained CDT mesh, material interface, signed distance, material scale, and normalized results.
[0052] Repeat all slicing to output steps for all slice heights to obtain a complete set of heterogeneous multi-material slice layer data: ; This embodiment ultimately outputs 200 layers of multi-material slice data. Each layer contains a complete geometric mesh and a continuous material scale field, which can be directly used for path planning and material control in subsequent heterogeneous multi-material additive manufacturing.
[0053] Example 3: Reference Figure 3 The feasibility of the heterogeneous multi-material continuous scaling method based on simultaneous slicing of an STL model and constrained CDT provided by this invention has been verified. In this experiment, the main body model was a cuboid, and the material partitioning model was a cylinder. After simultaneous slicing, a constrained CDT mesh was constructed within the rectangular main body cross-section region, and a circular region was used as the target distribution area for material A. The colors in the figure represent the proportion of material A at each mesh vertex or sampling point, with blue corresponding to a material A proportion close to 1, red corresponding to a material A proportion close to 0, and intermediate colors such as green and yellow corresponding to material A proportions between 0 and 1.
[0054] Depend on Figure 3It is evident that the proportion of material A remains relatively high inside the circular region, while the proportion of material A gradually decreases to 0 outside the circular region. A ring-shaped transition region of a certain width is formed near the material interface, where the material proportion changes continuously and smoothly from 1 to 0 without any significant abrupt change. Furthermore, the material proportion distribution is adaptable to the irregular triangular mesh.
[0055] The experimental results show that the present invention can achieve accurate representation of material regions and continuous proportional mapping near material interfaces on constrained CDT meshes, thereby verifying the feasibility of the signed distance calculation and material proportional mapping method.
[0056] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for continuous scaling of heterogeneous multi-materials based on simultaneous slicing of STL models and constrained CDT, characterized in that, Includes the following steps: S1: Input the main STL model and at least one material partition STL model; S2: Preprocess all input STL models; S3: Establish a unified slice height sequence; S4: Based on a unified slice height sequence, slice the main STL model and the STL models of each material partition at the same slice height to obtain the main cross-sectional area and the cross-sectional area of each material partition. S5: Perform a two-dimensional Boolean intersection operation between each material partition section and the main section section to obtain the effective material region corresponding to each material, and determine the default material region within the main section section; S6: Extract the main cross-sectional boundary of the current slice layer and the boundaries of each effective material region to form a set of constraint edges; use the set of constraint edges as a forced constraint condition to construct a constrained CDT mesh inside the main cross-sectional region; S7: Determine the material region attribution for vertices or sampling points within the constrained CDT mesh; S8: Calculate the signed distance from each vertex or sampling point to the boundary of the corresponding material region, and calculate the continuous material ratio at each vertex or sampling point based on the signed distance; S9: Normalize the proportions of all materials at each vertex or sampling point; S10: After traversing all slice heights and completing the corresponding processing, output the complete heterogeneous multi-material slice layer dataset.
2. The method for continuous scaling of heterogeneous multi-materials based on synchronous slicing of STL model and constrained CDT according to claim 1, characterized in that, The main body STL model is used to represent the overall geometric region of the part, and the material partition STL model is used to represent the distribution region of the corresponding material in three-dimensional space.
3. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, The preprocessing in step S2 includes geometric repair and spatial consistency verification. The geometric repair includes removing duplicate faces, removing degenerate faces, cleaning up unreferenced vertices, repairing face normals, and checking model closure. The spatial consistency verification is used to confirm that all models are in the same coordinate system, the same unit scale, and have the correct relative positional relationship.
4. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, In step S3, a unified slice height sequence is established based on the height direction distribution range of the main STL model and the preset slice layer thickness. All STL models use this unified slice height sequence to perform slicing operations.
5. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, In step S5, the effective material region is the intersection of the material partition section region and the main section region; the default material region is the complement of all effective material regions within the main section region.
6. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, In step S6, the set of constraint edges also includes the hole boundaries of the main cross section; after the material region boundary is embedded as a constraint edge in the meshing process, the generated triangular mesh can accurately preserve the geometric features of the material interface and avoid the boundary from shifting during the discretization process.
7. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, The assignment rule for step S7 is as follows: if a vertex or sampling point is located inside a certain effective material region, it is assigned to the corresponding material region; if a vertex or sampling point does not belong to any effective material region, it is assigned to the default material region.
8. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, In step S8, the calculation rule for the signed distance is as follows: when the point is located inside the material region, the signed distance is taken as the positive value of the Euclidean distance from the point to the boundary of the material region; when the point is located outside the material region, the signed distance is taken as the negative value of the Euclidean distance from the point to the boundary of the material region.
9. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, In step S8, a normalized parameter is calculated by combining the preset material transition zone width and the signed distance, and then the continuously changing material ratio is calculated by the smoothing function, so that the material ratio can achieve a smooth transition within the interface transition zone.
10. The method for heterogeneous multi-material proportional continuous mapping based on STL model synchronous slicing and constrained CDT according to claim 1, characterized in that, The multi-material slice data of a single slice layer includes slice height, main cross-sectional area, effective material area, default material area, constrained CDT mesh, material interface, signed distance calculation results, material scale value and normalization results.