A method and system for generating stereolithography data for a part with scanned features

By generating tangential contour point data and printing speed data of scanned feature parts, the problem of feature loss and offset of complex parts in existing 3D printing technology is solved, and unsupported adaptive spatial slicing is realized, which improves printing accuracy and quality.

CN116330662BActive Publication Date: 2026-07-21HEFEI UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HEFEI UNIV OF TECH
Filing Date
2023-03-02
Publication Date
2026-07-21

Smart Images

  • Figure CN116330662B_ABST
    Figure CN116330662B_ABST
Patent Text Reader

Abstract

The application provides a kind of generation method and system for the stereoscopic printing data of scanning feature parts, the method comprises: obtaining a plurality of scanning track points of a part to be printed;Obtain a plurality of cross-sectional profile points of the part to be printed at each scanning track point, and record as cross-sectional profile point data;Coordinate conversion is carried out on the cross-sectional profile point data to generate tangent plane profile point data;According to the distance between the tangent planes corresponding to adjacent scanning track points, generate tangent plane distance data;According to the tangent plane profile point data, generate printing trajectory data;According to the tangent plane distance data and the preset line width data, generate printing speed data;And according to the printing trajectory data and the printing speed data, generate the stereoscopic printing data of the part to be printed.The application can realize support-free adaptive spatial slicing, save support materials, and improve printing accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of 3D printing technology, and in particular to a method and system for generating 3D printing data for scanned feature parts. Background Technology

[0002] The core step in 3D (3-dimensional) printing technology is slicing. By cutting a 3D model according to a specific direction, 3D processing is transformed into layer-by-layer processing within a 2D plane, simplifying the manufacturing process. Existing slicing methods are mainly designed for three-degree-of-freedom printing equipment, which can handle simple parts with no overhangs and small curvature relatively well. However, when processing complex parts with overhangs, large curvature, and spatial variations, such as bent pipes, slicing according to a specific direction not only requires supporting material to prevent the overhangs from collapsing but also introduces significant step errors and can even cause feature loss, severely impacting the quality and accuracy of 3D printing. Therefore, there are areas for improvement. Summary of the Invention

[0003] In view of the shortcomings of the prior art described above, the purpose of this invention is to provide a method and system for generating 3D printing data for scanned feature parts, so as to solve the problems of feature loss and feature offset that exist in the printing of mold parts in the prior art.

[0004] To achieve the above and other related objectives, the present invention provides a method for generating stereoscopic printing data for scanned feature parts, comprising: Obtain multiple scan trajectory points of the part to be printed; Obtain multiple cross-sectional contour points of the part to be printed at each of the scanning trajectory points, and record them as cross-sectional contour point data; The cross-sectional profile point data is subjected to coordinate transformation to generate tangent plane profile point data; Based on the distance between the tangent planes corresponding to adjacent scan trajectory points, generate tangent plane distance data; Based on the tangent plane contour point data, print trajectory data is generated; Based on the cutting plane distance data and the preset line width data, print speed data is generated; and Based on the printing trajectory data and the printing speed data, 3D printing data for the part to be printed is generated.

[0005] In one embodiment of the present invention, the step of performing coordinate transformation on the cross-sectional contour point data to generate tangent plane contour point data includes: Acquire scan trajectory point data of multiple scan trajectory points; Based on the scan trajectory point data and the section profile point data, a rotation transformation matrix is ​​generated, wherein the rotation transformation matrix represents the transformation matrix of the coordinates of the section profile points from the section corresponding to the scan trajectory points to the tangent plane; and The section profile point data is transformed according to the rotation transformation matrix and translation vector to generate the tangent plane profile point data.

[0006] In one embodiment of the present invention, the rotation transformation matrix satisfies the following formula:

[0007] in, Let be the rotation transformation matrix. , , , This represents the first, second, third, and fourth columns of data in a quaternion.

[0008] In one embodiment of the present invention, the step of generating tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points includes: Based on the contour point data of the cutting plane, determine whether adjacent cutting planes intersect; When adjacent tangent planes do not intersect, the tangent plane distance data is generated based on the distance between the tangent planes corresponding to adjacent scan trajectory points; and When adjacent tangent planes intersect, the adjacent scanning trajectory points are adjusted, and the adjusted tangent plane distance data is generated.

[0009] In one embodiment of the present invention, the step of generating tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points includes: Based on the contour point data of the cutting plane, determine whether adjacent cutting planes intersect; When adjacent tangent planes do not intersect, the tangent plane distance data is generated based on the distance between the tangent planes corresponding to adjacent scan trajectory points; and When adjacent tangent planes intersect, delete the tangent plane contour point data of the intersecting portion of the adjacent tangent planes, and generate the tangent plane distance data of the non-intersecting portion.

[0010] In one embodiment of the present invention, the step of generating printing trajectory data based on the tangent plane contour point data further includes: Obtain the line height range data of the 3D printer; Based on the cutting plane distance data and the line height range data, generate slice layer data for the part to be printed; and The printing trajectory data is generated based on the cutting plane contour point data and the slice layer data.

[0011] In one embodiment of the present invention, the step of generating slice layer data of the part to be printed based on the cutting plane distance data and the line height range data includes: Based on the cutting plane distance data and the line height range data, determine whether the distance between adjacent cutting planes is within the line height range of the printer; When the distance between adjacent cutting planes is within the printer's line height range, the part to be printed is sliced ​​based on the scan trajectory point data and the cutting plane contour point data, generating the slice layer data; and When the distance between adjacent cutting planes is not within the line height range of the printer, the scanning trajectory line is re-discretized to generate the slice layer data.

[0012] In one embodiment of the present invention, the step of generating the printing trajectory data based on the cutting plane contour point data and the slice layer data includes: Based on the tangent plane contour point data, the tangent plane contour points are connected sequentially to generate single-layer trajectory planning data; and Based on the slice layer data and the single-layer trajectory planning data, the termination contour point of the cutting plane is connected to the contour point on the next cutting plane that is closest to the starting contour point of the cutting plane, thereby generating the printing trajectory data.

[0013] In one embodiment of the present invention, the distance and relative speed between the nozzle and the printing platform of the 3D printer are changed to print lines with the same line width but different line heights, and the line height range data is calculated based on the printing state of the lines.

[0014] The present invention also provides a system for generating stereoscopic printing data for scanned feature parts, comprising: The scanning trajectory processing module is used to acquire multiple scanning trajectory points of the part to be printed; The cross-sectional contour processing module is used to acquire multiple cross-sectional contour points of the part to be printed at each of the scanning trajectory points, and record them as cross-sectional contour point data; The coordinate transformation processing module is used to perform coordinate transformation on the cross-sectional contour point data to generate tangent plane contour point data. The tangent plane distance calculation module is used to generate tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points; The printing trajectory planning module is used to generate printing trajectory data based on the cutting plane contour point data; A printing speed planning module is used to generate printing speed data based on the cutting plane distance data and preset line width data; and The printing code generation module is used to generate 3D printing data for the part to be printed based on the printing trajectory data and the printing speed data.

[0015] As described above, the method and system for generating stereoscopic printing data for parts with scanning features according to the present invention have the following beneficial effects: the present invention can perform unsupported adaptive spatial slicing for parts with scanning features, thereby saving support materials and improving printing accuracy. Attached Figure Description

[0016] Figure 1 The diagram shown is a flowchart illustrating a method for generating 3D printing data for scanned feature parts provided by the present invention.

[0017] Figure 2 The diagram shows a simple discretization process of the scan trajectory line.

[0018] Figure 3 The diagram shows a discretization process for a complex scan trajectory.

[0019] Figure 4 The diagram shows a schematic of the discretization process for multi-scan trajectory lines.

[0020] Figure 5 The diagram shows a discretization process of a constant cross-sectional profile.

[0021] Figure 6 The diagram shows a discretized representation of the profile of the variable cross-section.

[0022] Figure 7 The diagram shows a discretization process of the multi-section profile.

[0023] Figure 8 This is a schematic diagram illustrating the process of transforming the coordinates of the profile points.

[0024] Figure 9 The diagram shows a specific implementation of step S30.

[0025] Figure 10 The diagram shows a specific implementation of step S40.

[0026] Figure 11 This is a schematic diagram showing the distance between any point on the tangent plane profile and adjacent points on the tangent plane profile.

[0027] Figure 12 This is a schematic diagram showing the shortest distance between any point on the tangent plane profile and the points on adjacent tangent plane profiles.

[0028] Figure 13 This is a schematic diagram showing the shortest distance between adjacent tangent plane contour points.

[0029] Figure 14 This diagram shows the maximum and minimum distances between adjacent tangent planes.

[0030] Figure 15 This is a schematic diagram showing the intersection of adjacent tangent planes.

[0031] Figure 16 This is a schematic diagram showing the trajectory processing of the intersection of adjacent tangent planes.

[0032] Figure 17 The diagram shown is a flowchart illustrating a specific implementation of step S50.

[0033] Figure 18 The diagram shown is a flowchart illustrating a specific implementation of step S52.

[0034] Figure 19 The diagram shown is a flowchart of a specific implementation of step S53.

[0035] Figure 20 This is a schematic diagram showing the slice result of a part with a constant cross-section and a simple scan trajectory.

[0036] Figure 21 The image shows a schematic diagram of the sliced ​​part with a complex scanning trajectory and variable cross-section.

[0037] Figure 22 This is a schematic diagram showing the slice results of a blade-type part.

[0038] Figure 23 The diagram shown is a structural block diagram illustrating a system for generating stereoscopic printing data for scanned feature parts, as an exemplary embodiment of the present invention. Detailed Implementation

[0039] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that, unless otherwise specified, the following embodiments and features can be combined with each other. It should also be understood that the terminology used in the embodiments of the present invention is for describing specific implementation schemes and not for limiting the scope of protection of the present invention. Test methods in the following embodiments that do not specify specific conditions are generally performed under conventional conditions or according to the conditions recommended by the respective manufacturers.

[0040] It should be understood that the structures, proportions, sizes, etc., illustrated in the accompanying drawings of this specification are merely for illustrative purposes to aid those skilled in the art and are not intended to limit the scope of the invention. Therefore, they have no substantial technical significance. Any modifications to the structure, changes in proportions, or adjustments to size, without affecting the effectiveness and purpose of the invention, should still fall within the scope of the technical content disclosed in this invention. Furthermore, the terms such as "upper," "lower," "left," "right," "middle," and "one" used in this specification are merely for clarity and are not intended to limit the scope of the invention. Changes or adjustments to their relative relationships, without substantially altering the technical content, should also be considered within the scope of the invention.

[0041] Please see Figures 1 to 23 This invention provides a method and system for generating 3D printing data for scanned feature parts, applicable to the field of 3D printing technology. For example, it allows for spatial slicing of parts to generate G-code (i.e., 3D printing data, which can be read by a 3D printer). This invention enables unsupported adaptive spatial slicing of parts with scanned features, addressing the problems of supported printing and large step errors caused by slicing complex parts with spatial variations in a specific direction in existing STL (stereolithography)-based 3D printing technology. This saves support material and improves printing accuracy.

[0042] Please see Figure 1 As shown, in one embodiment of the present invention, Figure 1 The diagram shown is a flowchart illustrating a method for generating 3D printing data for scanned feature parts provided by the present invention, which may include the following steps: Step S10: Obtain multiple scan trajectory points of the part to be printed; Step S20: Obtain multiple section profile points of the part to be printed at each scanning trajectory point and record them as section profile point data; Step S30: Perform coordinate transformation on the cross-sectional profile point data to generate tangent plane profile point data; Step S40: Generate tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points; Step S50: Generate printing trajectory data based on the cutting plane contour point data; Step S60: Generate printing speed data based on the cutting plane distance data and preset line width data; and Step S70: Generate 3D printing data of the part to be printed based on the printing trajectory data and printing speed data.

[0043] Please see Figures 2-4 As shown, in one embodiment of the present invention, Figure 2 The diagram shows a simple discretization process of the scan trajectory line. Figure 3 The diagram shows a discretization process for a complex scan trajectory line. Figure 4 The diagram illustrates the discretization process of multiple scan trajectory lines. When step S10 is executed, multiple scan trajectory points of the part to be printed are obtained. Specifically, firstly, the part to be printed is a part with scanning features, and its scan trajectory lines are obtained; then, the scan trajectory lines are discretized to obtain multiple scan trajectory points. The number of scan trajectory points can be denoted as... Furthermore, the coordinates of the scan trajectory points can be recorded as scan trajectory point data. In this embodiment, the coordinates of the scan trajectory points can be expressed as follows: , ..., , ..., , ... ,in, .

[0044] Please see Figures 5-7 As shown, in one embodiment of the present invention, Figure 5 The diagram shows the discretization process of the constant cross-sectional profile. Figure 6 The diagram shows a discretized processing of the variable section profile. Figure 7 This is a schematic diagram of the discretization process for multiple cross-sectional contour lines. When step S20 is executed, multiple cross-sectional contour points of the part to be printed at each scanning trajectory point are acquired and recorded as cross-sectional contour point data. Specifically, firstly, all cross-sectional contour lines are acquired, with one cross-sectional contour line corresponding to one scanning trajectory point. Obviously, the cross-sections enclosed by the cross-sectional contour lines are perpendicular to the vertical coordinate axis (z-axis) of the part to be printed; that is, the shape of the cross-sectional contour lines is expressed in the xoy plane of the three-dimensional coordinate axis of the part to be printed. Then, the cross-sectional contour lines are discretized to obtain multiple cross-sectional contour points; finally, the coordinates of the cross-sectional contour points are recorded as cross-sectional contour point data. In this embodiment, the x-axis direction of the part to be printed is set as the starting direction, and the cross-sectional contour points are sorted by counterclockwise rotation. The coordinates of the cross-sectional contour points corresponding to each cross-section can be expressed as: , ..., , ..., , ..., ,in, , n, ..., p, r, ..., l represent the number of profile points of each section.

[0045] Please see Figure 8 As shown, in one embodiment of the present invention, Figure 8 The diagram illustrates the process of coordinate transformation of the section profile points. When step S30 is executed, the section profile point data is transformed to generate tangent plane profile point data. Specifically, the coordinate transformation of the section profile point data can be performed through rotation and translation transformations, converting the coordinates of each section profile point to the tangent plane corresponding to each scanning trajectory point, and recording this as tangent plane profile point data.

[0046] Please see Figure 9 As shown, in one embodiment of the present invention, Figure 9 The flowchart shown is a specific implementation of step S30. Step S30 may include steps S31 to S32, which are described in detail below: Step S31: Obtain scan trajectory point data for multiple scan trajectory points; Step S32: Based on the scan trajectory point data and the section profile point data, generate a rotation transformation matrix, whereby the rotation transformation matrix represents the transformation matrix that converts the coordinates of the section profile points from the section corresponding to the scan trajectory points to the tangent plane; and Step S33: Based on the rotation transformation matrix and translation vector, transform the profile point data of the cross section to generate the profile point data of the tangent plane.

[0047] In one embodiment of the present invention, when step S31 is executed, scan trajectory point data of multiple scan trajectory points is acquired. Specifically, the multiple scan trajectory points acquired in step S10 can be recorded as scan trajectory point data, that is... , ..., , ..., , ... ,in, .

[0048] Please see Figure 8 As shown, in one embodiment of the present invention, when step S32 is executed, a rotation transformation matrix is ​​generated based on the scan trajectory point data and the section profile point data. The rotation transformation matrix represents the transformation matrix that converts the coordinates of the section profile points from the section corresponding to the scan trajectory point to the tangent plane. Specifically, firstly, the normal vectors of the section and the tangent plane are obtained. The shape of the section profile is expressed in the xoy plane of the three-dimensional coordinate axes, therefore its unit normal vector is... The unit normal vector of the tangent plane at the j-th scan trajectory point is: ,in, This represents the first derivative of the j-th discrete point with respect to the x-coordinate. This represents the first derivative of the j-th discrete point with respect to the y-coordinate. It represents the first derivative of the discrete point of the j-th scan line with respect to the z-axis coordinate.

[0049] Then, the quaternion method can be used to generate arrive The rotation transformation matrix between them. In this embodiment, the first step is to determine... and Whether they are collinear; when and When collinear, the rotation transformation matrix ;when and When they are not collinear, then according to the formula... , , ,use , , , Represent the first, second, third, and fourth columns of data in the quaternion; , , , Substitute into the transformation matrix Rotation transformation matrix The following formula can be satisfied:

[0050] That is Switch to The rotation transformation matrix is ​​also the rotation transformation matrix that transforms the j-th section profile point to the j-th tangent plane profile point.

[0051] In one embodiment of the present invention, the rotation transformation matrix can also be solved by methods such as Euler angles, RPY angles, and DH parameter method.

[0052] In one embodiment of the present invention, when step S32 is executed, the profile point data of the cross-section is transformed according to the rotation transformation matrix to generate the profile point data of the tangent plane. Specifically, the coordinates of each discrete point of the cross-section are first multiplied by the rotation transformation matrix on the right. We use a rotation vector to perform rotation transformations; and then add a translation vector, i.e., the coordinates of the corresponding tangent plane trajectory points, to perform translation transformations. This allows us to transform the contour points of each cross-section shape to the tangent plane corresponding to each scan trajectory point. The expression for transforming the j-th cross-section contour point to its corresponding tangent plane is:

[0053]

[0054] ...

[0055] That is Contour points after coordinate transformation to the tangent plane.

[0056] Please see Figure 10 As shown, in one embodiment of the present invention, Figure 10 The diagram shows a specific implementation of step S40. When step S40 is executed, tangent plane distance data is generated based on the tangent plane contour point data. The tangent plane distance data represents the distance between tangent planes corresponding to adjacent scan trajectory points. Specifically, step S40 may include steps S41 to S43, which are described in detail below: Step S41: Based on the contour point data of the tangent plane, determine whether adjacent tangent planes intersect; Step S42: When adjacent tangent planes do not intersect, generate tangent plane distance data based on the distance between the tangent planes corresponding to adjacent scan trajectory points; and Step S43: When adjacent tangent planes intersect, adjust the adjacent scanning trajectory points and generate the adjusted tangent plane distance data.

[0057] In one embodiment of the present invention, when step S41 is executed, it is determined whether adjacent tangent planes intersect based on the tangent plane contour point data. Specifically, firstly, the radius of curvature of the trajectory point of the tangent plane is calculated based on the tangent plane contour point data, and the radius of curvature of the j-th trajectory point is set as follows. ,in, Indicates arc length, This represents the tangential angle. In this embodiment, a method of substituting a straight line for a curved line is used. , ,in, Then, the distance between the contour points of the cutting plane and the corresponding scan trajectory points is calculated. ,in, Therefore, the maximum distance can be found. .like Then it can be determined that adjacent tangent planes do not intersect; if If so, it can be determined that adjacent tangent planes intersect.

[0058] Please see Figure 11 , Figure 12 As shown, in one embodiment of the present invention, Figure 11 This is a schematic diagram showing the distance between any point on the tangent plane contour and adjacent points on the tangent plane contour. Figure 12This is a schematic diagram showing the shortest distance between any point on the tangent plane contour and points on adjacent tangent plane contours. When step S42 is executed, i.e., when adjacent tangent planes do not intersect, tangent plane distance data is obtained. Specifically, the tangent plane distance data may include the maximum distance between adjacent tangent planes. and minimum distance First, take Inner tangent plane profile points , Then calculate arrive Distance between all tangent plane contour points , arrive The shortest distance between all points on the tangent plane contour. , By performing the above steps on all tangent plane contour points within the area, the shortest distance between adjacent tangent plane contour points can be found. .

[0059] Please see Figure 13 , Figure 14 As shown, in one embodiment of the present invention, Figure 13 This is a schematic diagram showing the shortest distance between adjacent tangent plane contour points; Figure 14 This diagram illustrates the maximum and minimum distances between adjacent tangent planes. It shows the maximum distance between the j-th tangent plane and the k-th plane. minimum distance .

[0060] In one embodiment of the present invention, when step S43 is executed, i.e., when adjacent tangent planes intersect, the adjacent scanning trajectory points are adjusted, and adjusted tangent plane distance data is generated. Specifically, when adjacent tangent planes intersect, step S10 can be executed again, i.e., the scanning trajectory lines are discretized again to adjust the adjacent scanning trajectory points until there is no intersection between the adjacent tangent planes; then steps S20 to S40 can be returned to obtain the adjusted tangent plane distance data between adjacent tangent planes.

[0061] Please see Figure 15 , Figure 16 As shown, in one embodiment of the present invention, Figure 15 This is a schematic diagram showing the intersection of adjacent tangent planes. Figure 16This is a schematic diagram illustrating the trajectory processing of the intersection of adjacent tangent planes. When adjacent tangent planes intersect, the distance data between the tangent planes can be obtained first, and the tangent plane contour point data of the intersection can be deleted. Specifically, the distance data between adjacent tangent planes is first obtained; then, all tangent plane contour points whose distance to the scan trajectory point is greater than the radius of curvature of the scan trajectory point are found and deleted; finally, the remaining tangent plane contour points are connected sequentially to form a new tangent plane contour shape, which is the printed trajectory.

[0062] Please see Figure 17 As shown, in one embodiment of the present invention, Figure 17 The diagram shows a specific implementation of step S50. When step S50 is executed, printing trajectory data is generated based on the cutting plane contour point data. Specifically, step S50 may include steps S51 to S53, which are described in detail below: Step S51: Obtain the line height range data of the 3D printer; Step S52: Based on the cutting plane distance data and line height range data, generate the slice layer data of the part to be printed; and Step S53: Generate printing trajectory data based on the cutting plane contour point data and slice layer data.

[0063] In one embodiment of the present invention, when step S51 is executed, the line height range data of the 3D printer is obtained. Specifically, the line height range data refers to the minimum line height of the lines printed by the 3D printer. Maximum line height The line height range data can be obtained through experiments with a 3D printer. In this embodiment, by changing the distance and relative speed between the printhead and the printing platform, lines of the same width but different line heights can be printed to obtain the line height range of the printed lines. Among them, the minimum line height of the printed lines. The method for determining this is that the distance between the printhead and the printing platform is less than... Discontinuous lines may occur; the maximum line height of the printed lines may also be affected. The method for determining this is that the distance between the printhead and the printing platform is greater than... Sometimes the lines don't stick to the printing platform.

[0064] Please see Figure 18 As shown, in one embodiment of the present invention, Figure 18 The diagram shows a specific implementation of step S52. When step S52 is executed, slice layer data of the part to be printed is generated based on the cutting plane distance data and line height range data. Specifically, step S52 may include steps S521 to S522, which are described in detail below: Step S521: Based on the cutting plane distance data and line height range data, determine whether the distance between adjacent cutting planes is within the line height range of the printer; and Step S522: When the distance between adjacent cutting planes is within the printer's line height range, the part to be printed is sliced ​​based on the scan trajectory point data and cutting plane contour point data to generate slice layer data; and Step S523: When the distance between adjacent cutting planes is not within the line height range of the printer, the scanning trajectory line is discretized again to generate slice layer data.

[0065] In one embodiment of the present invention, when step S521 is executed, it is determined whether the distance between adjacent cutting planes is within the line height range of the printer based on the cutting plane distance data and the line height range data. Specifically, it is determined whether the distance between adjacent cutting planes is within the line height range data of the printer based on the cutting plane distance data and the line height range data, i.e., whether the distance is satisfied. .

[0066] In one embodiment of the present invention, when step S522 is executed, i.e., when the distance between adjacent cutting planes is within the line height range of the printer, the part to be printed is sliced ​​according to the scan trajectory point data and the cutting plane contour point data to generate slice layer data. Specifically, if the following conditions are met... Then, based on the current scanning trajectory point data and the cutting plane contour point data, the part to be printed is sliced ​​to generate its slice layer data.

[0067] In one embodiment of the present invention, when step S523 is executed, i.e., when the distance between adjacent cutting planes is not within the line height range of the printer, the scan trajectory lines are re-discretized to generate slice layer data. Specifically, if the following conditions are not met... Then determine whether it satisfies If the conditions are met, it means that the part to be printed cannot be sliced ​​based on the current scan trajectory point data and cutting plane contour point data; if the conditions are not met, there are two possibilities: First, or In this case, one can first reduce the number of scan trajectory points, that is, let The scan trajectory line is re-discreteed, and the process returns to steps S20 to S50 until the printing conditions are met. Then, based on the scan trajectory point data and tangent plane contour point data generated after re-discretization, the part to be printed is sliced ​​to generate its slice layer data. The second method... or In this case, one can first increase the number of scan trajectory points, that is, let The scan trajectory line is re-discreteed, and the process returns to steps S20 to S50 until the printing conditions are met. Then, based on the scan trajectory point data and tangent plane contour point data generated after re-discretization, the part to be printed is sliced ​​to generate its slice layer data. If the above two cases, after re-discretization, can only satisfy... If so, it means that the part to be printed cannot be sliced.

[0068] Please see Figure 19 As shown, in one embodiment of the present invention, Figure 19 The diagram shows a specific implementation of step S53. When step S53 is executed, printing trajectory data is generated based on the cutting plane contour point data and the slice layer data. Specifically, step S53 may include steps S531 to S532, which are described in detail below: Step S531: Based on the tangent plane contour point data, connect the tangent plane contour points sequentially to generate single-layer trajectory planning data; and Step S532: Based on the slice layer data and single-layer trajectory planning data, connect the termination contour point of the cutting plane with the contour point on the next cutting plane that is closest to the starting contour point of the cutting plane to generate printing trajectory data.

[0069] In one embodiment of the present invention, when step S531 is executed, the contour points of the cutting plane are sequentially connected according to the contour point data of the cutting plane to generate single-layer trajectory planning data corresponding to the current cutting plane. Specifically, the contour points of the same cutting plane are sequentially connected to form a printing trajectory, thereby realizing single-layer trajectory planning. The section contour points generated in step S20 have been sorted according to defined rules. After coordinate transformation, the section contour point data is converted into cutting plane contour point data, which can be represented as: , ..., , , ..., By sequentially connecting the contour points of the tangent plane after coordinate transformation, single-layer trajectory planning can be achieved.

[0070] In one embodiment of the present invention, when step S532 is executed, i.e., based on the slice layer data and single-layer trajectory planning data, the termination contour point of the cutting plane is connected to the contour point on the next cutting plane that is closest to the starting contour point of the current cutting plane, thereby generating printing trajectory data. Specifically, connecting the termination contour point of the current cutting plane to the contour point on the next cutting plane that is closest to the starting contour point of the current cutting plane enables trajectory planning for the transition between layers. The adjacent cutting plane contour points after coordinate transformation are represented as follows: , ,in, This represents the starting contour point of the j-th tangent plane. Let the endpoint of the j-th tangent plane be represented by... For the k-th tangent plane and Connect the contour points with the smallest distance. and This allows for trajectory planning of transitions between layers. By connecting the tangent planes sequentially as described above, the print trajectory data can be generated.

[0071] Please see Figures 20-22 As shown, in one embodiment of the present invention, Figure 20 The image shows a schematic diagram of the sliced ​​part with a constant cross-section and a simple scan trajectory. Figure 21 The image shows a schematic diagram of the sliced ​​part with a complex scanning trajectory and variable cross-section. Figure 22 The diagram shows the sliced ​​result of a blade-like part. Specifically, printing speed data can be generated based on the cutting plane distance data and preset line width data generated in step S40. In this embodiment, the printing speed data may include the nozzle extrusion speed and the relative speed between the nozzle and the printing platform. Based on the cutting plane distance data and preset line width data, the cross-sectional shape information of the printed line can be obtained. Changing the nozzle extrusion speed and the relative speed between the nozzle and the printing platform can change the cross-sectional shape of the line, thereby achieving non-uniform single-layer printing. The volume of filament extruded by the printer nozzle per unit time = the volume of material accumulated on the printing platform, thus proposing the following equation: ,in, Indicates the cross-sectional area of ​​the printed line. This indicates the relative speed between the printhead and the printing platform. This indicates the material extrusion speed of the nozzle. This indicates the inner diameter of the nozzle. The cross-sectional shape of the line is elliptical, therefore the cross-sectional area is... ,in, Indicates line width. This represents the line height. Combining the two equations above, we can obtain... Therefore, it can be seen that changing the extrusion speed of the nozzle and the relative speed between the nozzle and the printing platform alters the cross-sectional shape of the lines. By performing layer-by-layer printing based on this, multi-degree-of-freedom unsupported printing can be achieved for parts with scanning features.

[0072] In one embodiment of the present invention, when step S70 is executed, 3D printing data of the part to be printed is generated based on the printing trajectory data and printing speed data. Specifically, based on the printing trajectory data generated in step S50 and the printing speed data generated in step S60, G-code of the part to be printed, i.e., 3D printing data that the printer can read, can be generated.

[0073] Please see Figure 23 As shown, Figure 23 This is a structural block diagram illustrating an exemplary embodiment of the present invention of a system for generating stereoscopic printing data for scanned feature parts. In one embodiment of the present invention, the system for generating stereoscopic printing data for scanned feature parts may include a scan trajectory processing module 100, a cross-sectional contour processing module 200, a coordinate transformation processing module 300, a tangent plane distance calculation module 400, a printing trajectory planning module 500, a printing speed planning module 600, and a printing code generation module 700. Detailed descriptions of each functional module are as follows.

[0074] The scanning trajectory processing module 100 is used to acquire multiple scanning trajectory points of the part to be printed; In one embodiment of the present invention, the scan trajectory processing module 100 can be used to acquire multiple scan trajectory points of the part to be printed. Specifically, firstly, the part to be printed is a part with scanning features, and its scan trajectory line is acquired; then, the scan trajectory line is discretized to obtain multiple scan trajectory points, the number of which can be denoted as... Finally, the coordinates of the scan trajectory points are recorded as scan trajectory point data.

[0075] The section profile processing module 200 is used to acquire multiple section profile points of the part to be printed at each scanning trajectory point and record them as section profile point data.

[0076] In one embodiment of the present invention, the cross-sectional profile processing module 200 can be used to acquire multiple cross-sectional profile points of the part to be printed at each scanning trajectory point and record them as cross-sectional profile point data. Specifically, firstly, all cross-sectional profile lines are acquired, with one cross-sectional profile line corresponding to one scanning trajectory point. Obviously, the cross-section enclosed by the cross-sectional profile lines is perpendicular to the vertical coordinate axis (z-axis) of the part to be printed, that is, the shape of the cross-sectional profile lines is expressed in the xoy plane of the three-dimensional coordinate axis of the part to be printed. Then, the cross-sectional profile lines are discretized to obtain multiple cross-sectional profile points; finally, the coordinates of the cross-sectional profile points are recorded as cross-sectional profile point data.

[0077] The coordinate transformation processing module 300 is used to perform coordinate transformation on the profile point data of the cross section to generate the profile point data of the tangent plane.

[0078] In one embodiment of the present invention, the coordinate transformation processing module 300 can be used to perform coordinate transformation on the cross-sectional contour point data to generate tangent plane contour point data. Specifically, the coordinate transformation processing of the cross-sectional contour point data can be performed by rotation transformation and translation transformation, transforming the coordinates of each cross-sectional contour point to the tangent plane corresponding to each scanning trajectory point, and recording them as tangent plane contour point data.

[0079] The tangent plane distance calculation module 400 is used to generate tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points.

[0080] In one embodiment of the present invention, the tangent plane distance calculation module 400 can be used to generate tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points. Specifically, the tangent plane distance calculation module 400 can be used to determine whether adjacent tangent planes intersect based on tangent plane contour point data. When adjacent tangent planes do not intersect, tangent plane distance data is obtained; the tangent plane distance data may include the maximum distance between adjacent tangent planes. and minimum distance When adjacent tangent planes intersect, the adjacent scanning trajectory points are adjusted, and the adjusted tangent plane distance data between the adjacent tangent planes is obtained. Specifically, when adjacent tangent planes intersect, step S10 can be re-executed, that is, the scanning trajectory line is re-discretized to adjust the adjacent scanning trajectory points until there is no intersection between the adjacent tangent planes; then steps S20 to S40 can be returned to obtain the adjusted tangent plane distance data between the adjacent tangent planes.

[0081] In one embodiment of the present invention, when adjacent tangent planes intersect, tangent plane distance data can be obtained first, and tangent plane contour point data of the intersecting portion of adjacent tangent planes can be deleted. Specifically, tangent plane distance data between adjacent tangent planes is obtained first; then, all tangent plane contour points whose distance to the scanning trajectory point is greater than the radius of curvature of the scanning trajectory point are found and deleted; finally, the remaining tangent plane contour points are connected in sequence to form a new tangent plane contour shape, i.e., the printing trajectory.

[0082] The printing trajectory planning module 500 is used to generate printing trajectory data based on the tangent plane contour point data.

[0083] In one embodiment of the present invention, the print trajectory planning module 500 can be used to generate print trajectory data based on the tangent plane contour point data. Specifically, the print trajectory planning module 500 is used to obtain the line height range data of the 3D printer. The line height range data refers to the minimum line height of the lines printed by the 3D printer. Maximum line height The printing trajectory planning module 500 can generate slice layer data of the part to be printed based on the cutting plane distance data and line height range data. Then, based on the cutting plane contour point data, it connects the cutting plane contour points in sequence to generate single-layer trajectory planning data. Then, based on the slice layer data and single-layer trajectory planning data, it connects the ending contour point of the cutting plane with the contour point on the next cutting plane that is closest to the starting contour point of the cutting plane to generate printing trajectory data.

[0084] The printing speed planning module 600 is used to generate printing speed data based on the cutting plane distance data and the preset line width data.

[0085] In one embodiment of the present invention, the printing speed planning module 600 can be used to generate printing speed data based on the cutting plane distance data and the preset line width data. Specifically, the printing speed data may include the nozzle extrusion speed and the relative speed between the nozzle and the printing platform. Based on the cutting plane distance data and the preset line width data, the cross-sectional shape information of the printed line can be obtained. Changing the nozzle extrusion speed and the relative speed between the nozzle and the printing platform can change the cross-sectional shape of the line, thereby enabling non-uniform single-layer printing. Layer-by-layer stacking printing can then be performed to achieve multi-degree-of-freedom unsupported printing of parts with scanning features.

[0086] The printing code generation module 700 is used to generate 3D printing data for the part to be printed based on the printing trajectory data and the printing speed data.

[0087] In one embodiment of the present invention, the print code generation module 700 can be used to generate 3D printing data of the part to be printed based on the print trajectory data and the print speed data. Specifically, the print code generation module 700 can generate G-code of the part to be printed, that is, 3D printing data that the printer can read, based on the print trajectory data generated by the print trajectory planning module 500 and the print speed data generated by the print speed planning module 600.

[0088] In summary, this invention provides a method and system for generating 3D printing data for scanned feature parts, applicable to the field of 3D printing technology. This invention can perform unsupported adaptive spatial slicing for parts with scanned features, solving the problems of supported printing and large step errors caused by slicing complex parts with spatial variations in a specific direction in existing STL model-based 3D printing technology. This results in saving support material and improving printing accuracy.

[0089] The above embodiments are merely illustrative of the principles and effects of the present invention and are not intended to limit the invention. Any person skilled in the art can modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by those skilled in the art without departing from the spirit and technical concept disclosed in the present invention should still be covered by the claims of the present invention.

Claims

1. A method for generating 3D printing data for scanned feature parts, characterized in that, include: Obtain multiple scan trajectory points of the part to be printed; Obtain multiple cross-sectional contour points of the part to be printed at each of the scanning trajectory points, and record them as cross-sectional contour point data; Acquire scanning trajectory point data of multiple scanning trajectory points; generate a rotation transformation matrix based on the scanning trajectory point data and the cross-sectional contour point data, wherein the rotation transformation matrix represents the transformation matrix of the coordinates of the cross-sectional contour point from the cross-section corresponding to the scanning trajectory point to the tangent plane; and perform transformation processing on the cross-sectional contour point data based on the rotation transformation matrix and translation vector to generate the tangent plane contour point data. Based on the distance between the tangent planes corresponding to adjacent scan trajectory points, generate tangent plane distance data; Based on the tangent plane contour point data, print trajectory data is generated; Based on the cutting plane distance data and the preset line width data, print speed data is generated; and Based on the printing trajectory data and the printing speed data, 3D printing data for the part to be printed is generated.

2. The method for generating stereoscopic printing data for scanned feature parts according to claim 1, characterized in that, The rotation transformation matrix satisfies the following formula: in, Let be the rotation transformation matrix. , , , This represents the first, second, third, and fourth columns of data in a quaternion.

3. The method for generating stereoscopic printing data for scanned feature parts according to claim 1, characterized in that, The step of generating tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points includes: Based on the contour point data of the cutting plane, determine whether adjacent cutting planes intersect; When adjacent tangent planes do not intersect, the tangent plane distance data is generated based on the distance between the tangent planes corresponding to adjacent scan trajectory points; and When adjacent tangent planes intersect, the adjacent scanning trajectory points are adjusted, and the adjusted tangent plane distance data is generated.

4. The method for generating stereoscopic printing data for scanned feature parts according to claim 1, characterized in that, The step of generating tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points includes: Based on the contour point data of the cutting plane, determine whether adjacent cutting planes intersect; When adjacent tangent planes do not intersect, the tangent plane distance data is generated based on the distance between the tangent planes corresponding to adjacent scan trajectory points; and When adjacent tangent planes intersect, delete the tangent plane contour point data of the intersecting portion of the adjacent tangent planes, and generate the tangent plane distance data of the non-intersecting portion.

5. The method for generating stereoscopic printing data for scanned feature parts according to claim 1, characterized in that, The step of generating printing trajectory data based on the tangent plane contour point data further includes: Obtain the line height range data of the 3D printer; Based on the cutting plane distance data and the line height range data, generate slice layer data for the part to be printed; and The printing trajectory data is generated based on the cutting plane contour point data and the slice layer data.

6. The method for generating stereoscopic printing data for scanned feature parts according to claim 5, characterized in that, The step of generating slice layer data for the part to be printed based on the cutting plane distance data and the line height range data includes: Based on the cutting plane distance data and the line height range data, determine whether the distance between adjacent cutting planes is within the line height range of the printer; When the distance between adjacent cutting planes is within the printer's line height range, the part to be printed is sliced ​​based on the scan trajectory point data and the cutting plane contour point data, generating the slice layer data; and When the distance between adjacent cutting planes is not within the line height range of the printer, the scanning trajectory points are re-discretized to generate the slice layer data.

7. The method for generating stereoscopic printing data for scanned feature parts according to claim 5, characterized in that, The step of generating the printing trajectory data based on the cutting plane contour point data and the slice layer data includes: Based on the tangent plane contour point data, the tangent plane contour points are connected sequentially to generate single-layer trajectory planning data; and Based on the slice layer data and the single-layer trajectory planning data, the termination contour point of the cutting plane is connected to the contour point on the next cutting plane that is closest to the starting contour point of the cutting plane, thereby generating the printing trajectory data.

8. The method for generating stereoscopic printing data for scanned feature parts according to claim 5, characterized in that, The distance and relative speed between the printhead and the printing platform of the 3D printer are changed to print lines with the same line width but different line heights, and the line height range data is calculated based on the printing state of the lines.

9. A system for generating stereoscopic printing data for scanned feature parts, characterized in that, include: The scanning trajectory processing module is used to acquire multiple scanning trajectory points of the part to be printed; The cross-sectional contour processing module is used to acquire multiple cross-sectional contour points of the part to be printed at each of the scanning trajectory points, and record them as cross-sectional contour point data; A coordinate transformation processing module is used to acquire scan trajectory point data of multiple scan trajectory points; generate a rotation transformation matrix based on the scan trajectory point data and the cross-sectional contour point data, wherein the rotation transformation matrix represents the transformation matrix of the coordinates of the cross-sectional contour points from the cross-section corresponding to the scan trajectory points to the tangent plane; and perform transformation processing on the cross-sectional contour point data based on the rotation transformation matrix and translation vector to generate the tangent plane contour point data. The tangent plane distance calculation module is used to generate tangent plane distance data based on the distance between tangent planes corresponding to adjacent scan trajectory points; The printing trajectory planning module is used to generate printing trajectory data based on the cutting plane contour point data; A printing speed planning module is used to generate printing speed data based on the cutting plane distance data and preset line width data; and The printing code generation module is used to generate 3D printing data for the part to be printed based on the printing trajectory data and the printing speed data.