Methods, apparatus, equipment and storage media for geometric processing

By receiving the mesh data and parameters of the geometry, creating modeling data blocks, and automatically processing the geometry using parameter sets, control sets, and modelers, the problem of low efficiency in creating or modifying geometry in existing modeling software tools is solved, achieving more efficient geometry processing.

CN119169220BActive Publication Date: 2025-10-28叁农数据(广州)有限公司
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202311643177.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-01
Publication Date
2025-10-28
Estimated Expiration
2043-12-01

AI Technical Summary

Technical Problem

Existing modeling software tools are inefficient at creating or modifying geometry, requiring manual input of all vertex and face data, which leads to complex operations.

Method used

By receiving the mesh data and parameters of the geometry, a modeling data block is created, and the geometry is automatically created or modified using parameter sets, control sets, and modelers, reducing manual intervention.

Benefits of technology

It improves the efficiency of creating or modifying geometry, reduces the dependence on vertex and face data, and simplifies the operation process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119169220B_ABST
    Figure CN119169220B_ABST
Patent Text Reader

Abstract

This application discloses a geometry processing method, apparatus, device, and storage medium, belonging to the field of modeling technology. This application receives mesh data and parameters of the geometry to be generated, then creates a modeling data block based on the mesh data. The modeling data block can automatically create or modify the geometry based on its parameters. Finally, the geometry's parameters are input into the created modeling data block to obtain the completed geometry. This application enables modeling software tools to automatically create or modify geometry based on its parameters.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of modeling, and in particular to methods, apparatus, devices and storage media for processing geometry. Background Technology

[0002] Geometry processing methods are a key technology in the field of modeling. Various modeling software tools use geometry processing methods to complete modeling quickly. Among them, the speed of geometry processing is particularly important.

[0003] In existing technologies, the steps for creating or modifying geometry using various modeling software tools are complex, requiring all vertex and face data of the geometry, and can only be created or modified manually, resulting in low efficiency in creating or modifying geometry using existing modeling software tools.

[0004] The above content is only used to help understand the technical solution of this application and does not represent an admission that the above content is prior art. Summary of the Invention

[0005] The main objective of this application is to provide a geometry processing method, apparatus, device, and storage medium, which aims to solve the technical problem of low efficiency in creating or modifying geometry using existing modeling software.

[0006] To achieve the above objectives, this application provides a geometry processing method, which includes the following steps:

[0007] Receive the mesh data and parameters of the geometry to be generated;

[0008] Based on the mesh data of the geometry, a modeling data block is created, wherein the modeling data block can automatically create or modify the geometry based on the parameters of the geometry;

[0009] Input the parameters of the geometry into the created modeling data block to obtain the created geometry.

[0010] Optionally, the step of creating a modeling data block based on the mesh data of the geometry includes:

[0011] Create a parameter set, wherein the parameter set can record the parameters of the geometry;

[0012] Based on a preset control set, the parameter set is connected to the default grid data, wherein the control set enables the parameter set to be bidirectionally synchronized with the grid data;

[0013] Based on the mesh data of the geometry, a shaper is created, wherein the shaper can generate geometry based on parameters within a parameter set;

[0014] The parameter set, control set, and modeler are merged to obtain the modeling data block.

[0015] Optionally, the step of connecting the parameter set with the default grid data based on a preset control set includes:

[0016] Obtain the default mesh data and read the vertex position information of the mesh data;

[0017] Based on the vertex position information, allocate mesh data space and calculate the index value of the vertex position information;

[0018] Write the vertex position information and index value into the parameter set;

[0019] Release the allocated grid data space.

[0020] Optionally, the step of creating a modeler based on the mesh data of the geometry includes:

[0021] Read the geometry type from the mesh data of the geometry;

[0022] Determine whether the preset general modeler can generate geometry of the specified type;

[0023] If a preset general modeler can generate geometry of the type, then the preset general modeler is used as the modeler for the modeling data block.

[0024] If the default general modeler cannot generate the geometry of the specified type, the structural characteristics of the geometry are returned so that the user can set a custom modeler for the geometry.

[0025] Optionally, the step of inputting the parameters of the geometry into the created modeling data block to obtain the created geometry includes:

[0026] The parameters of the geometry are input into the control set in the modeling data block so that the control set can update the data in the parameter set;

[0027] Based on the information data in the parameter set, the geometry is generated using the modeler in the modeling data block.

[0028] Optionally, the step of generating geometry using the modeler in the modeling data block based on the information data in the parameter set includes:

[0029] Read the segmented information data and grid data from the parameter set;

[0030] Based on the segmented information data, calculate the number of times the modeler needs to be called to generate the geometry;

[0031] If the modeler only needs to be called once, the geometry is drawn based on the modeler in the modeling data block and the data in the parameter set;

[0032] If the modeler needs to be called multiple times, the modeler is used to draw the geometry one by one, and the drawn geometry is combined to obtain the final geometry.

[0033] Optionally, the step of using the modeler to draw geometry one by one and combining the drawn geometry to obtain the final geometry if multiple modeling calls are required includes:

[0034] Based on the segmented information data, the grid data is divided into multiple segments;

[0035] The modeler is used to read the mesh data fragments one by one and draw the geometry.

[0036] Based on the grid data, the drawn geometry is connected by connecting the faces with the same coordinates to obtain the final geometry.

[0037] Furthermore, to achieve the above objectives, this application also provides a geometry processing apparatus, the apparatus comprising:

[0038] The receiving module is used to receive the mesh data of the geometry to be generated;

[0039] A creation module is used to create a modeling data block based on the mesh data of the geometry, wherein the modeling data block is based on directly or indirectly modifying the mesh data to achieve the modeling target;

[0040] The input module is used to input the parameters of the geometry into the created modeling data block to obtain the created geometry.

[0041] In addition, to achieve the above objectives, this application also provides a geometry processing device, the device comprising: a memory, a processor, and a geometry processing program stored in the memory and executable on the processor, the geometry processing program being configured to implement the steps of the geometry processing method as described above.

[0042] In addition, to achieve the above objectives, this application also provides a storage medium storing a geometry processing program, which, when executed by a processor, implements the steps of the geometry processing method described above.

[0043] This application provides a geometry processing method, apparatus, device, and storage medium. Compared with related technologies, where the steps for creating or modifying geometry using various modeling software tools are complex, requiring all vertex and face data of the geometry, and can only be created or modified manually, resulting in low efficiency in creating or modifying geometry using existing modeling software tools, this application receives the mesh data and parameters of the geometry to be generated, and then creates a modeling data block based on the mesh data of the geometry. The modeling data block can automatically create or modify the geometry based on the geometry parameters. Finally, the geometry parameters are input into the created modeling data block to obtain the created geometry. It can be understood that this application creates a modeling data block that can directly or indirectly create and modify mesh data to process geometry, enabling modeling software tools to automatically create or modify geometry based on the geometry parameters, thus solving the problem of low efficiency in creating or modifying geometry using modeling software tools. Attached Figure Description

[0044] Figure 1 This is a schematic diagram of the structure of the geometry processing device of the hardware operating environment involved in the embodiments of this application;

[0045] Figure 2 This is a flowchart illustrating the first embodiment of this application;

[0046] Figure 3 A schematic diagram illustrating the principle of creating geometric shapes for the modeling data blocks in this application;

[0047] Figure 4 A structural diagram illustrating the mesh data relationship between modeling data blocks and geometry in this application;

[0048] Figure 5 A simplified model of a three-section wall created using the modeling data blocks of this application;

[0049] Figure 6 This is a flowchart illustrating the second embodiment of this application;

[0050] Figure 7 This is a structural block diagram of the geometry processing device of this application.

[0051] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0052] It should be understood that the specific embodiments described herein are merely illustrative of this application and are not intended to limit this application.

[0053] Reference Figure 1 , Figure 1 This is a schematic diagram of the geometric processing device structure of the hardware operating environment involved in the embodiments of this application.

[0054] like Figure 1 As shown, the geometry processing device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display screen or an input unit such as a keyboard; optionally, the user interface 1003 may also include a standard wired interface or a wireless interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 1005 may be a high-speed random access memory (RAM) or a stable non-volatile memory (NVM), such as a disk drive. The memory 1005 may also optionally be a storage device independent of the aforementioned processor 1001.

[0055] Those skilled in the art will understand that Figure 1 The structures shown do not constitute a limitation on the geometry processing device and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0056] like Figure 1 As shown, the memory 1005, which serves as a storage medium, may include an operating system, a data storage module, a network communication module, a user interface module, and a geometry processing program.

[0057] exist Figure 1 In the geometry processing device shown, the network interface 1004 is mainly used for data communication with other devices; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the geometry processing device of this application can be set in the geometry processing device, and the geometry processing device calls the geometry processing program stored in the memory 1005 through the processor 1001 and executes the geometry processing method provided in the embodiment of this application.

[0058] This application provides a geometric processing method, referring to... Figure 2 The geometry processing method includes:

[0059] It should be noted that the method execution subject in this embodiment is a geometry processing device. The geometry processing device can be a modeling tool or terminal or other device with geometry data processing capabilities. This application does not impose any specific limitations.

[0060] It should be understood that the computer code in this embodiment is in Python language. In specific implementations, the computer code can also use any computer language such as Java or C. This application does not impose specific limitations. In this embodiment, the use of Python language is only for explaining the calculation method of this solution.

[0061] It is understandable that, such as Figure 3 As shown, this solution achieves the modeling purpose by directly or indirectly creating and modifying mesh data through modeling data blocks. The difference between this solution and the existing technology is that the existing technology requires users to manually create or modify the geometry. Not only do they need to input all the vertex and face information of the geometry, but they also need to input the parameters of the geometry. For example, a cube has 8 vertices, and every 4 vertices form a face, for a total of 6 faces. Manual creation requires inputting all the vertex information, face information, and the relationship information between vertices and faces. However, this solution only requires inputting the length, width, and height data of the geometry to generate the cube.

[0062] The following explanation uses modeling tools and equipment as geometry processing devices.

[0063] Step S10: Receive the mesh data and parameters of the geometry to be generated.

[0064] In practice, the geometry processing device receives the mesh data and parameters of the geometry to be generated.

[0065] It should be noted that the mesh data of the geometry is the specific location of the geometry in three-dimensional or two-dimensional space. Based on the mesh data, the orientation, orientation, or rotation of the geometry in the three-dimensional or two-dimensional space can be determined.

[0066] It should be understood that the parameters of the geometry are the length, width and height data of the geometry. If the geometry is a complex shape or has multiple sides, the length, width and height data can be the side length data of each side. The unit of the length, width and height data is not specifically limited and can be centimeters, millimeters or meters. The specific unit can be manually set based on business needs.

[0067] Step S20: Based on the mesh data of the geometry, create a modeling data block, wherein the modeling data block can automatically create or modify the geometry based on the parameters of the geometry.

[0068] In a specific implementation, the geometry processing device creates a modeling data block based on the mesh data of the geometry.

[0069] It should be understood that the data and logic of the modeling data block are part of the geometry to be modeled, and the parameters of the geometry of the modeling object can be viewed at any time. Modifying the parameters can change the geometry of the modeling object, such as... Figure 4 As shown, the modeling data block includes a parameter set, a control set, and a modeler. The parameter set, control set, and modeler work together to create or modify the geometry using the geometry's mesh data.

[0070] It should be understood that the parameter set is a set of parameters used to describe and represent the geometry. Different types of geometric components have different parameters. For example, walls have parameters such as length, height, width, and thickness, while cylinders have parameters such as column type, base radius, and height.

[0071] It should be noted that the control set is a logical set used to synchronize geometric mesh data and parameter set. When the data in the geometric parameter set is changed, the mesh data of the geometry is updated synchronously through the control set. Similarly, when the mesh data is updated (for example, when a vertex or edge of the geometry is moved), the data in the geometric parameter set is updated synchronously.

[0072] It is understood that the shaper is used to quickly process the shape changes caused by the complex shapes of the constructed geometry (e.g., geometry extension, folding or closing) and the associated constraints between them (e.g., geometry trimming, fitting or snapping). The shaper mainly consists of a series of data structures and methods, and there are some differences between the data structures and methods for different types of geometry.

[0073] The step of creating a modeling data block based on the mesh data of the geometry, wherein the modeling data block can automatically create or modify the geometry based on the geometry's parameters, specifically includes:

[0074] Step S21: Create a parameter set, wherein the parameter set can record the parameters of the geometry.

[0075] In practice, the geometry processing device creates a set of parameters.

[0076] It should be understood that the parameter set is only used to record the parameters of the geometry. After the geometry is created, the parameters of the geometry should be bidirectionally associated with the mesh data. When the parameters of the geometry change, the mesh data must change according to the data of the geometry, and when the mesh data changes, the data of the geometry must change according to the mesh data.

[0077] It is understood that the parameter set is a set of parameters summarized based on the characteristics of the geometry. The parameters are usually composed of name, type, default value and control set method. For parameters of a specific type, they also include data such as maximum value, minimum value, unit, and numerical precision.

[0078] For example, name: an identifier used to represent and use the parameter, which is unique within the parameter set, where the names of parameters in parameter sets of different types of geometry can be the same.

[0079] Type: Used to represent the type of the parameter. Parameters are divided into two types: basic and container. Basic type parameters include Int, Float, Bool, Enum, String or Pointer. Container type parameters include Vector and Collection. Vector can store parameters of type Int and Float. Collection can store parameters of any data type, including basic type parameters, container type parameters, custom type parameters, and even parameter sets.

[0080] Default value: The default value of the parameter is used to provide basic data for the parameter set during the creation process, so that the parameter set can be created successfully.

[0081] Control set method: The method that binds the parameters and the control set will be automatically called when the parameter value changes, and the control set will then update the grid data with the new parameter value.

[0082] Maximum and minimum values: The upper and lower limits of parameter values, used to limit the range of parameters in the parameter set.

[0083] Units & Numerical Precision: Units include parameters such as length, angle, time, and mass. Numerical precision is used to define the number of decimal places in a floating-point number.

[0084] Here, we define a wall with dimensions of 3×2×1, and its simple parameters are as follows:

[0085] class Wall_PropGroup:

[0086] length:FloatProperty(default=3,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0087] width:FloatProperty(default=2,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0088] height:FloatProperty(default=1,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0089] Here, Wall is used to represent the parameter name, PropGroup is the parameter type, default is used to represent the default value, min is the minimum value of the parameter, precision is the precision, unit='LENGTH' is used to represent the unit of the parameter, and update=update_mesh indicates the control set method being called.

[0090] Step S22: Based on a preset control set, connect the parameter set with the default grid data, wherein the control set enables the parameter set to be bidirectionally synchronized with the grid data.

[0091] In a specific implementation, the geometry processing device connects the parameter set with the default mesh data based on a preset control set, so that the geometry parameters in the parameter set can be synchronized bidirectionally with the default mesh data.

[0092] It is understood that the default grid data is used only for creating modeling data blocks and connecting the parameter set.

[0093] It should be noted that the control set includes multiple control set methods. These control set methods are used for bidirectional updates between the parameter set and the mesh data. Their main function is to calculate the positions of all vertices based on the parameter set and position information of the geometry, then combine the vertices into faces, and finally form the geometry. Conversely, if the vertex position information is available, all parameter values ​​can be calculated based on the parameter definitions.

[0094] The step of connecting the parameter set with the default grid data based on a preset control set, wherein the control set enables bidirectional synchronization between the parameter set and the grid data, specifically includes:

[0095] Step S221: Obtain the default mesh data and read the vertex position information of the mesh data.

[0096] In a specific implementation, the geometry processing device acquires the default mesh data and reads the vertex position information of the mesh data.

[0097] Step S222: Based on the vertex position information, allocate the mesh data space and calculate the index value of the vertex position information.

[0098] In a specific implementation, the geometry processing device allocates space based on the vertex position information and the mesh data, and calculates the index value of the vertex position information.

[0099] It should be noted that the space allocation based on grid data refers to allocating space in the two-dimensional or three-dimensional space of the modeling tool software based on the grid data, so that the geometry processing device can find the specific position of the vertex in the space based on the index value of the vertex position information.

[0100] Step S223: Overwrite the vertex position information and index value into the parameter set.

[0101] In a specific implementation, the geometry processing device overwrites the vertex position information and index value into the parameter set.

[0102] It should be noted that after receiving the vertex position information and index value that need to be saved, the parameter set deletes the originally saved data and then saves the vertex position information and index value.

[0103] Step S224: Release the allocated grid data space.

[0104] In practice, the geometry processing device releases the allocated mesh data space.

[0105] Step S23: Based on the mesh data of the geometry, create a shaper, wherein the shaper can generate geometry based on parameters in the parameter set.

[0106] In a specific implementation, the geometry processing device creates a shaper based on the mesh data of the geometry.

[0107] It should be noted that the modeler generates the corresponding geometry based on the parameters in the parameter set.

[0108] The step of creating a shaper based on the mesh data of the geometry, wherein the shaper can generate geometry based on parameters within a parameter set, specifically includes:

[0109] Step S231: Read the type of geometry in the mesh data of the geometry.

[0110] In a specific implementation, the geometry processing device reads the geometry type from the mesh data of the geometry.

[0111] Step S232: Determine whether the preset general modeler can generate the geometry of the type.

[0112] In a specific implementation, the geometry processing device determines whether a preset general modeler can generate geometry of the type described.

[0113] Step S233: If the preset general modeler can generate the geometry of the type, then use the preset general modeler as the modeler for the modeling data block.

[0114] In a specific implementation, if a preset general modeler can generate geometry of the type, the geometry processing device uses the preset general modeler as the modeler for the modeling data block.

[0115] Step S234: If the preset general modeler cannot generate the geometry of the type, the structural characteristics of the geometry are returned so that the user can set the exclusive modeler for the geometry.

[0116] In a specific implementation, if the preset general modeler cannot generate the geometry of the specified type, the geometry processing device returns the structural characteristics of the geometry so that the user can set a custom modeler for the geometry.

[0117] It should be noted that the aforementioned custom stylist is derived from the general stylist.

[0118] Step S24: Merge the parameter set, control set, and modeler to obtain the modeling data block.

[0119] In a practical implementation, the geometry processing device binds and merges the parameter set, control set, and modeler to obtain a usable modeling data block.

[0120] Step S30: Input the parameters of the geometry into the created modeling data block to obtain the created geometry.

[0121] In a specific implementation, the geometry processing device inputs the parameters of the geometry into the created modeling data block and obtains the created geometry.

[0122] It is understood that the completed geometry should include a modeling data block. If the geometry needs to be modified, the mesh data and parameter data of the geometry are directly input into the modeling data block. The modeling data block will automatically update the parameters, draw the geometry, and display the drawn geometry in the three-dimensional or two-dimensional space of the modeling tool software.

[0123] For example, such as Figure 5 As shown, a simplified design for a three-section wall is as follows:

[0124] Here, the parameter set is no longer the length, width, and height, but rather serves as a container for storing all segment wall parameters:

[0125] class Wall_Seg_PropGroup:

[0126] length:FloatProperty(default=3,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0127] width:FloatProperty(default=2,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0128] height:FloatProperty(default=1,min=0.1,precision=2,unit='LENGTH',update=update_mesh)

[0129] class Wall_PropGroup:

[0130] parts:CollectionProperty(type=Wall_Seg_PropGroup

[0131] The control set receives vertex and face arrays, and the core method for updating mesh data is as follows: o represents the geometry itself, and verts, faces, and edges are the vertex, face, and edge arrays, respectively. First, mesh data space is allocated. Then, the data structure and configuration are derived from the geometry. The mesh data is overwritten with new vertex and face information, and the vertex and face indices are updated. Finally, the allocated memory space is released.

[0132]

[0133]

[0134] The modeler is designed in two levels. The general modeler includes segmented structures, rotation matrices, and position information. Specific types of geometry undergo additional design based on the general modeler and their own structural characteristics. The core design of the general modeler is as follows: segs is the segmented structure, rot is the rotation matrix, and location is the position information:

[0135]

[0136] The core design of the wall shaper is as follows, where outside represents the outer contour surface of the wall, inside represents the inner contour surface of the wall, and axis represents the local coordinate system:

[0137]

[0138]

[0139] The shaper draws the shape piece by piece based on the segment information in the parameter set. The core method is as follows: part is one segment, co is the starting point of the segment, radius and da are the radius and arc increment angle of the arc when the segment is formed:

[0140]

[0141] This application provides a geometry processing method, apparatus, device, and storage medium. In this embodiment, the application receives the mesh data and parameters of the geometry to be generated, and then creates a modeling data block based on the mesh data of the geometry. The modeling data block can automatically create or modify the geometry based on the geometry parameters. Finally, the geometry parameters are input into the created modeling data block to obtain the created geometry. It can be understood that this application creates a modeling data block that can directly or indirectly create and modify the geometry processed by mesh data, so that modeling tool software can automatically create or modify the geometry based on the geometry parameters, thus solving the problem of low efficiency in creating or modifying geometry using modeling tool software.

[0142] Furthermore, based on the first embodiment of this application, a second embodiment of this application is proposed, with reference to... Figure 6 Step S30 specifically includes:

[0143] It should be noted that the modeling engine in this embodiment is designed to realize the association constraints between complex shapes and geometries. Based on a general part and segment structure, it supports both adding new features to existing geometry type modelers through scripts and adding support for new geometry types.

[0144] Step S31: Input the parameters of the geometry into the control set in the modeling data block so that the control set can update the data in the parameter set.

[0145] In a specific implementation, the geometry processing device inputs the parameters of the geometry into the control set in the modeling data block, so that the control set can update the data in the parameter set.

[0146] Step S32: Based on the information data in the parameter set, generate geometry using the modeler in the modeling data block.

[0147] In a specific implementation, the geometry processing device generates geometry using the modeler in the modeling data block based on the information data in the parameter set.

[0148] The step of generating geometry using the modeler in the modeling data block based on the information data in the parameter set specifically includes:

[0149] Step S321: Read the segmented information data and grid data from the parameter set.

[0150] In a specific implementation, the geometry processing device reads the segmented information data and mesh data from the parameter set.

[0151] It should be understood that the segmented information data is obtained by dividing the data based on geometric mesh data and parameters. Each segment of information data can be drawn once based on the modeler.

[0152] Step S322: Based on the segmented information data, calculate the number of times the modeler needs to be called to generate the geometry.

[0153] In a specific implementation, the geometry processing device calculates the number of times the modeler needs to be called to generate the geometry based on the segmented information data.

[0154] It should be understood that if the modeler can complete the drawing of the geometry in just one draw, then the modeler is only called once. If the modeler cannot complete the drawing of the geometry in one draw, then the geometry is split into several simple geometry shapes that can be drawn by the modeler in one draw. Then the modeler is used to draw the simple geometry shapes one by one. Finally, the simple geometry shapes are merged to obtain the complex geometry shape.

[0155] Step S323: If the modeler only needs to be called once, then draw the geometry based on the modeler in the modeling data block and the data in the parameter set.

[0156] In practice, if the modeler only needs to be called once, the geometry processing device will draw the geometry based on the modeler in the modeling data block and the data in the parameter set.

[0157] Step S324: If it is necessary to call the modeler multiple times, use the modeler to draw the geometry one by one, and combine the drawn geometry to obtain the final geometry.

[0158] In a practical implementation, if the modeler needs to be called multiple times, the geometry processing device uses the modeler to draw the geometry one by one, and combines the drawn geometry to obtain the final geometry.

[0159] It should be understood that if the geometry still requires multiple drawing operations by the modeler to obtain, the geometry needs to be further subdivided until it can be obtained by drawing it once by the modeler.

[0160] The step of using the modeler to draw geometric shapes one by one if multiple modeling calls are required, and then combining the drawn geometric shapes to obtain the final geometric shape, specifically includes:

[0161] Step S3241: Based on the segmented information data, divide the grid data into multiple segments.

[0162] In a specific implementation, the geometry processing device divides the mesh data into multiple segments based on the segmentation information data.

[0163] It should be noted that the multiple segments refer to the data of dividing a complex geometry into multiple simpler geometries, so that the modeler can draw the geometry. The mesh data and parameter data of each simple geometries are the information data of the segmentation.

[0164] Step S3242: Use the modeler to read the mesh data fragments one by one and draw the geometry.

[0165] In a specific implementation, the geometry processing device uses the modeler to read the mesh data fragments one by one and draw the geometry.

[0166] Step S3243: Based on the grid data, connect the faces with the same coordinates of the drawn geometry to obtain the final geometry.

[0167] It should be noted that the geometry processing device acquires the coordinate data of faces with the same coordinates of the drawn geometry, places the faces with the same coordinate data close together, calculates the contact point of the two geometry, retains the contact point, and then deletes the faces with the same coordinate data, so that the two simple geometry are merged into a complex geometry.

[0168] In a specific implementation, the geometry processing device connects the faces with the same coordinates of each geometry based on the grid data to obtain the final geometry.

[0169] In this embodiment, by inputting the parameters of the geometry into the control set in the modeling data block, the control set updates the data in the parameter set. Then, based on the information data in the parameter set, the modeler in the modeling data block is used to generate the geometry. This allows the geometry processing device to not only generate simple geometry on its own, but also to generate complex geometry using a specially configured modeling engine, making the geometry creation speed faster.

[0170] Furthermore, embodiments of this application also propose a geometry processing apparatus, referring to... Figure 7 The geometry processing device includes:

[0171] Receiver module 10 is used to receive the mesh data and parameters of the geometry to be generated;

[0172] A creation module 20 is used to create a modeling data block based on the mesh data of the geometry, wherein the modeling data block can automatically create or modify the geometry based on the parameters of the geometry;

[0173] The input module 30 is used to input the parameters of the geometry into the created modeling data block to obtain the created geometry.

[0174] Optionally, the creation module 20 includes:

[0175] The first creation unit is used to create a parameter set, wherein the parameter set can record the parameters of the geometry;

[0176] A connection unit is used to connect the parameter set with default grid data based on a preset control set, wherein the control set enables the parameter set to be bidirectionally synchronized with the grid data;

[0177] The second creation unit is used to create a shaper based on the mesh data of the geometry, wherein the shaper can generate geometry based on parameters in a parameter set;

[0178] The merging unit is used to merge the parameter set, control set, and modeler to obtain a modeling data block.

[0179] Optionally, the connection unit includes:

[0180] The read sub-unit is used to obtain the default mesh data and read the vertex position information of the mesh data;

[0181] The computational subunit is used to allocate mesh data space based on the vertex position information and to calculate the index value of the vertex position information;

[0182] The write sub-unit is used to overwrite the vertex position information and index value into the parameter set;

[0183] Release sub-cell, used to release allocated grid data space.

[0184] Optionally, the second creation unit includes:

[0185] The judgment subunit is used to determine whether a preset general modeler can generate geometry of the aforementioned type;

[0186] A sub-unit is used to use the preset general modeler as the modeler for the modeling data block if the preset general modeler can generate the geometry of the type.

[0187] The return sub-unit is used to return the structural characteristics of the geometry if the preset general modeler cannot generate the geometry of the type, so that the user can set the exclusive modeler for the geometry.

[0188] Optionally, the input module 30 includes:

[0189] The input submodule is used to input the parameters of the geometry into the control set in the modeling data block, so that the control set can update the data in the parameter set;

[0190] The generation submodule is used to generate geometry using the modeler in the modeling data block based on the information data in the parameter set.

[0191] Optionally, the generation submodule includes:

[0192] The reading unit is used to read the segmented information data and grid data in the parameter set;

[0193] The calculation unit is used to calculate the number of times the modeler needs to be called to generate the geometry based on the segmented information data.

[0194] The first drawing unit is used to draw geometry based on the modeler and parameter set in the modeling data block if the modeler only needs to be called once.

[0195] The second drawing unit is used to draw geometric shapes one by one using the modeler if multiple modeling calls are required, and to combine the drawn geometric shapes to obtain the final geometric shape.

[0196] Optionally, the second drawing unit includes:

[0197] A molecular unit is used to divide the grid data into multiple segments based on the segmentation information data;

[0198] The drawing sub-unit is used to read the mesh data fragments one by one using the modeler and draw the geometry;

[0199] The connecting sub-unit is used to connect the faces with the same coordinates of the drawn geometry based on the grid data to obtain the final geometry.

[0200] The specific implementation of the geometry processing device in this application is basically the same as the embodiments of the geometry processing method described above, and will not be repeated here.

[0201] This application provides a storage medium that stores one or more programs, which can be executed by one or more processors to implement the steps of the geometry processing method described in any of the above claims.

[0202] The specific implementation of the storage medium in this application is basically the same as the embodiments of the geometry processing method described above, and will not be repeated here.

[0203] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or system. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or system that includes that element.

[0204] The serial numbers of the above embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0205] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0206] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A method for processing geometric objects, characterized in that, The geometry processing method includes the following steps: Receive the mesh data and parameters of the geometry to be generated; Based on the mesh data of the geometry, a parameter set is created, wherein the parameter set can record the parameters of the geometry. Based on a preset control set, the parameter set is connected to the default mesh data, wherein the control set enables the parameter set to be bidirectionally synchronized with the mesh data. A modeling data block is created, wherein the modeling data block can automatically create or modify the geometry based on the parameters of the geometry. Input the parameters of the geometry into the created modeling data block to obtain the created geometry; Specifically, the parameters of the geometry are input into the control set in the modeling data block so that the control set can update the data in the parameter set; Based on the information data in the parameter set, the geometry is generated using the modeler in the modeling data block; This includes reading segmented information data and grid data from the parameter set; Based on the segmented information data, calculate the number of times the modeler needs to be called to generate the geometry; If the modeler only needs to be called once, the geometry is drawn based on the modeler in the modeling data block and the data in the parameter set; If the modeler needs to be called multiple times, the modeler is used to draw the geometry one by one, and the drawn geometry is combined to obtain the final geometry. The segmented information data is obtained by dividing the data based on geometric mesh data and parameters. Each segment of information data can be drawn once based on the modeler. Based on the segmented information data, the grid data is divided into multiple segments; The modeler is used to read the mesh data fragments one by one and draw the geometry. Obtain the coordinate data of the faces with the same coordinates of the drawn geometry, align the faces with the same coordinate data together, calculate the contact point of the two geometry, retain the contact point, and then delete the faces with the same coordinate data to merge the two geometry into one geometry; When the data in the parameter set of the geometry is changed, the mesh data of the geometry is updated synchronously through the control set. When the mesh data is updated, the data in the parameter set of the geometry is updated synchronously.

2. The geometry processing method as described in claim 1, characterized in that, The step of creating a modeling data block based on the mesh data of the geometry includes: Based on the mesh data of the geometry, a shaper is created, wherein the shaper can generate geometry based on parameters within a parameter set; The parameter set, control set, and modeler are merged to obtain the modeling data block.

3. The geometry processing method as described in claim 2, characterized in that, The step of connecting the parameter set with the default grid data based on the preset control set includes: Obtain the default mesh data and read the vertex position information of the mesh data; Based on the vertex position information, allocate mesh data space and calculate the index value of the vertex position information; Write the vertex position information and index value into the parameter set; Release the allocated grid data space.

4. The geometry processing method as described in claim 2, characterized in that, The step of creating a modeler based on the mesh data of the geometry includes: Read the geometry type from the mesh data of the geometry; Determine whether the preset general modeler can generate geometry of the specified type; If a preset general modeler can generate geometry of the type, then the preset general modeler is used as the modeler for the modeling data block. If the default general modeler cannot generate the geometry of the specified type, the structural characteristics of the geometry are returned so that the user can set a custom modeler for the geometry.

5. A geometric processing device, characterized in that, The device includes: The receiving module is used to receive the mesh data and parameters of the geometry to be generated; A creation module is used to create a parameter set based on the mesh data of the geometry. The parameter set can record the parameters of the geometry. Based on a preset control set, the parameter set is connected to the default mesh data. The control set enables the parameter set to be bidirectionally synchronized with the mesh data. A modeling data block is created. The modeling data block is based on directly or indirectly modifying the mesh data to achieve the modeling target. When the data in the parameter set of the geometry is changed, the mesh data of the geometry is synchronously updated through the control set. When the mesh data is updated, the data in the parameter set of the geometry is synchronously updated. The input module is used to input the parameters of the geometry into the created modeling data block to obtain the created geometry; The input module includes: The input submodule is used to input the parameters of the geometry into the control set in the modeling data block, so that the control set can update the data in the parameter set; A generation submodule is used to generate geometry using the modeler in the modeling data block based on the information data in the parameter set. The generation submodule includes: The reading unit is used to read the segmented information data and grid data in the parameter set; The calculation unit is used to calculate the number of times the modeler needs to be called to generate the geometry based on the segmented information data. The first drawing unit is used to draw geometry based on the modeler and parameter set in the modeling data block if the modeler only needs to be called once. The second drawing unit is used to draw the geometry one by one using the modeler if it is necessary to call the modeler multiple times, and combine the drawn geometry to obtain the final geometry. The segmented information data is obtained by dividing the geometry mesh data and parameters. Each segment of information data can be drawn once based on the modeler. The second drawing unit includes: A molecular unit is used to divide the grid data into multiple segments based on the segmentation information data; The drawing sub-unit is used to read the mesh data fragments one by one using the modeler and draw the geometry. The connecting subunit is used to obtain the coordinate data of the faces with the same coordinates of the drawn geometry, to align the faces with the same coordinate data together, to calculate the contact point of the two geometry, to retain the contact point, and then to delete the faces with the same coordinate data, so that the two geometry are merged into one geometry.

6. A geometric processing device, characterized in that, The device includes: a memory, a processor, and a geometry processing program stored in the memory and executable on the processor, the geometry processing program being configured to implement the steps of the geometry processing method as described in any one of claims 1 to 4.

7. A storage medium, characterized in that, The storage medium stores a geometry processing program, which, when executed by a processor, implements the steps of the geometry processing method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Automated Process for Parametric Modeling

    US20190073438A1