A method, system and medium for picking up feature points of an EDA model
Patent Information
- Application Number
- CN202311483530.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-08
- Publication Date
- 2026-10-30
- Estimated Expiration
- 2043-11-08
AI Technical Summary
[0004]针对现有模型特征点拾取精度差且效率慢的问题,本发明提供一种EDA模型拾取特征点的方法、系统及介质
[0028](1)本发明通过几何特征点数据库,使得能够通过模型ID快速查到该模型边和面上的特征点数据以及特殊点数据,提高查找效率;同时通过建立渲染数据与几何特征点数据库之间的映射关系表,并且采用特定的方式进行判断是否有效拾取到模型的特征点,进而快速索引到模型几何特征点,能够实现对模型几何特征点的快速拾取的同时确保拾取精度,继而提高了用户操作适应体验;
Smart Images

Figure CN117435762B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of EDA modeling technology, and more specifically, relates to a method, system and medium for picking feature points in an EDA model. Background Technology
[0002] Feature point picking in EDA models is crucial for referencing existing models and obtaining geometric coordinates, making it an indispensable function in EDA software. Feature points in EDA models include the center point of a face, the vertices of an edge, the center point of an edge, the quarter points of an edge, the endpoints of an arc, the midpoints and quarter points of an arc, the center of a sphere, and grid points of the reference system. Currently, some software in the industry does not pick up model feature points completely; for example, HFSS cannot pick up the center of a sphere. Other software has accuracy errors in picking model feature points, failing to meet accuracy requirements when manually creating new models based on existing models. Existing technologies often use the rendering engine to display feature points from the rendered model data. However, due to the accuracy error between rendered data and actual geometric data, users may mistakenly believe that manually built models using feature points from existing models are highly accurate. However, subsequent simulations often fail to yield the expected results because feature points with relatively low accuracy were picked. Therefore, ensuring accurate feature point picking is a vital function of EDA simulation software, significantly improving the user experience. Summary of the Invention
[0003] 1. The problem to be solved
[0004] To address the problems of poor accuracy and slow efficiency in existing model feature point picking, this invention provides a method, system, and medium for picking feature points in EDA models. This invention establishes a mapping table between rendering data and a geometric feature point database, and uses a specific method to determine whether model feature points have been effectively picked, thereby quickly indexing the model's geometric feature points. This achieves rapid picking of model geometric feature points while ensuring picking accuracy, thus improving the user's operational experience.
[0005] 2. Technical Solution
[0006] To solve the above problems, the present invention adopts the following technical solution.
[0007] A method for picking feature points using an EDA model includes the following steps:
[0008] Obtain the geometric data of the EDA model and construct a geometric feature point database: The geometric feature point database includes constructing geometric feature point IDs for all geometric feature points, and creating a mapping table between edge IDs and feature point IDs at both ends of the edge, creating a mapping table between face IDs and feature point IDs at the center of the face, and creating a mapping table between face IDs and several edge IDs of the face.
[0009] The EDA model is rendered based on geometric data to obtain rendered triangular facet data. Triangular facet IDs are created for each triangular facet, and a mapping table between triangular facet IDs and face IDs in the geometric feature point database is constructed.
[0010] Feature point picking: Obtain the picking position, determine the triangular facet where it is located based on the picking position, obtain the feature point position based on the mapping relationship table between the triangular facet ID and the face ID in the geometric feature point database, and render and display the feature point position.
[0011] Furthermore, the specific steps for picking up feature points are as follows:
[0012] Obtain the pick position, and determine the triangular facet containing the pick position and the triangular facet ID of the triangular facet based on the pick position;
[0013] Calculate the distance between the picking position and the triangle facet point. If it is less than the threshold, then index the geometric feature point data through the mapping relationship table between the triangle facet ID and the face ID in the geometric feature point database. Then index all the vertices on the model through the geometric feature point database. Calculate the distance between the picking position and all the vertices respectively. If it is less than the threshold, it means that the vertex of the model has been picked.
[0014] If the distance between the picking position and all vertices is greater than the threshold, then all edges on the model are indexed through the geometric feature point database to obtain the data of the edge center and quarter edge. The distance between the picking position and the edge center, and the distance between the picking position and the quarter edge are calculated. If the distance is less than the threshold, it means that the edge center or quarter edge of the model has been picked.
[0015] If the distance between the picking position and the edge center, and the distance between the mouse point and the quarter edge are both greater than the threshold, then all faces on the model are indexed through the geometric feature point database, and the distance between the picking position and the face center is calculated. If it is less than the threshold, it means that the face center of the model has been picked.
[0016] The geometric feature points picked up on the model are rendered and displayed, thus realizing the picking of feature points.
[0017] Furthermore, for 3D models, a mapping table is established between entity IDs and multiple Face IDs; for 2D models, a mapping table is established between Sheet IDs and Face IDs.
[0018] Furthermore, the specific steps for rendering the EDA model based on geometric data include: obtaining all the triangular faces of the EDA model, creating triangular face IDs for each triangular face, and constructing a mapping table between the triangular face IDs and the face IDs in the geometric feature point database.
[0019] Furthermore, when picking feature points on the center of a sphere or an arc, a mapping table between model IDs and feature points is constructed when rendering EDA model geometry data. When picking feature points, the model ID of the mouse point is directly obtained, all feature points are obtained through the model ID, and the distance between the mouse point and the feature point is calculated. If it is less than a threshold, it means that the model's feature point has been picked.
[0020] A system for picking feature points using an EDA model as described in any of the preceding claims, comprising:
[0021] Geometric feature point database creation module: used to acquire geometric data of EDA models and build a geometric feature point database;
[0022] The mapping table construction module renders the EDA model based on geometric data, obtains the rendered triangular facet data, creates triangular facet IDs for the triangular facets, and constructs a mapping table between the triangular facet IDs and the face IDs in the geometric feature point database.
[0023] Feature point picking module: used to pick geometric feature points of the model;
[0024] Display module: Used to render and display the geometric feature points picked up on the model.
[0025] A computer-readable storage medium storing a computer program, which, when executed by a processor, implements a method for picking feature points using an EDA model as described in any of the preceding claims.
[0026] 3. Beneficial effects
[0027] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0028] (1) This invention uses a geometric feature point database to enable the quick lookup of feature point data and special point data on the edges and faces of a model by model ID, thereby improving search efficiency. At the same time, by establishing a mapping relationship table between rendering data and the geometric feature point database, and using a specific method to determine whether the model's feature points have been effectively picked up, the geometric feature points of the model can be quickly indexed. This enables the rapid picking of geometric feature points of the model while ensuring picking accuracy, thereby improving the user's operational experience.
[0029] (2) The system of the present invention has a simple composition. By establishing the mapping relationship between geometric data and model entity, and the mapping relationship between geometric data and rendering data, when the user's mouse approaches the feature point of the model, the screen pixel distance between the mouse point and the feature point of the rendering data is judged. If it is less than the threshold, the geometric feature data point of the model is quickly indexed through the mapping relationship, so as to realize the fast and accurate picking of the model feature point and the user experience is high. Attached Figure Description
[0030] Figure 1 This is a schematic diagram of the overall process of the present invention;
[0031] Figure 2 This represents the intended mapping relationship between geometric data and rendering data. Detailed Implementation
[0032] The present invention will now be further described with reference to specific embodiments and accompanying drawings.
[0033] Example 1
[0034] Please see Figure 1 and Figure 2 , Figure 1 This is a schematic diagram of the overall process of this application; Figure 2 This represents the intended mapping relationship between geometric data and rendering data.
[0035] In this embodiment, as Figure 1 and Figure 2 As shown, a method for picking feature points using an EDA model includes the following steps:
[0036] S1: Obtain the geometric data of the EDA model and construct a geometric feature point database: The geometric feature point database includes constructing geometric feature point IDs for all geometric feature points, as well as creating a mapping table between edge IDs and feature point IDs at both ends of the edge, creating a mapping table between face IDs and feature point IDs at the center of the face, and creating a mapping table between face IDs and several edge IDs of the face.
[0037] In step S1, the geometric feature point database includes constructing geometric feature point IDs for all geometric feature points, enabling unique identification of all feature points and improving accuracy; simultaneously, mapping tables are established for all edges and faces among the geometric feature points, allowing for quick retrieval of feature point data on the edges and faces of the model using a unique model ID, improving search efficiency; and for 3D models, a mapping table is established between entity IDs and multiple face IDs; for 2D models, a mapping table is established between sheet IDs and face IDs.
[0038] S2: Render the EDA model based on the geometric data to obtain the rendered triangular facet data, create triangular facet IDs for the triangular facets, and construct a mapping table between the triangular facet IDs and the face IDs in the geometric feature point database.
[0039] In step S2, specifically, rendering the EDA model based on geometric data involves obtaining all the triangular faces of the EDA model, setting the triangular face IDs corresponding to the face IDs in the rendering engine, and constructing a mapping table between the triangular face IDs and the face IDs in the geometric feature point database. This step only constructs a mapping table between the rendered triangular face IDs and the face IDs in the geometric feature point database, thus eliminating the need to construct a mapping table between each rendered triangular face ID and each edge ID in the geometric feature point database, reducing subsequent computation and improving the overall efficiency of feature point picking.
[0040] S3: Pick Feature Points: Obtain the pick position, determine the triangular facet where it is located based on the pick position, obtain the feature point position based on the mapping relationship table between the triangular facet ID and the face ID in the geometric feature point database, and render and display the feature point position.
[0041] In step S3, the position and ID of the corresponding rendered triangle are determined by picking the location. Then, the face ID corresponding to the rendered triangle ID is obtained from the geometric feature point database through the mapping table between the triangle ID and the face ID in the geometric feature point database. Finally, the feature points of the model are determined through the mapping tables between face ID and edge ID, and between edge ID and point ID in the geometric feature point database. This is different from the existing technology that directly displays the feature points of the rendered data through the rendering engine, which has a large accuracy error and affects the subsequent simulation process. This step establishes a mapping table between the rendered data and the geometric data, and obtains accurate geometric data through the rendered data, thereby determining the accuracy of feature point picking.
[0042] Furthermore, the specific steps for S3 to pick up feature points are as follows:
[0043] S31: Get the pick position, which is the mouse point. Determine the triangle facet and its ID based on the pick position.
[0044] S32: Calculate the distance between the picking position and the triangle facet point. If it is less than the threshold, index the geometric feature point data through the mapping relationship table between the triangle facet ID and the face ID in the geometric feature point database, and then index all the vertices on the model through the geometric feature point database. Calculate the distance between the picking position and all the vertices respectively. If it is less than the threshold, it means that the vertex of the model has been picked.
[0045] S33: If the distance between the picking position and all vertices is greater than the threshold, then index all edges on the model through the geometric feature point database to obtain the data of the edge center and quarter edge, calculate the distance between the picking position and the edge center, and the picking position and the quarter edge. If it is less than the threshold, it means that the edge center or quarter edge of the model has been picked.
[0046] S34: If the distance between the picking position and the edge center, and the distance between the mouse point and the quarter edge are both greater than the threshold, then all faces on the model are indexed through the geometric feature point database, and the distance between the picking position and the face center is calculated. If it is less than the threshold, it means that the face center of the model has been picked.
[0047] S35: Render and display the geometric feature points picked up on the model to achieve feature point picking.
[0048] This invention establishes a mapping table by classifying and organizing geometric feature points in a database, and creates a mapping table between the rendered triangular facet IDs and the face IDs in the geometric feature point database. Subsequently, the geometric feature points of the model are quickly indexed based on the mapping relationship between the rendered data and the geometric data, simplifying the feature point determination method. This enables rapid picking of geometric feature points of the model while ensuring picking accuracy, thereby improving the user's operational experience.
[0049] Furthermore, when picking feature points on the center of a sphere or an arc, since triangular faces cannot be obtained, the model ID is set into the rendering engine during the rendering stage, i.e., when rendering the geometric data of the EDA model, and a mapping table between the model ID and feature points is constructed. When picking feature points, the model ID of the mouse point is directly obtained through the rendering engine interface, all feature points are obtained through the model ID, and the distance between the mouse point and the feature point is calculated. If it is less than a threshold, it means that the model's feature point has been picked.
[0050] Example 2
[0051] A system for picking feature points using an EDA model as described in any of the preceding claims, comprising:
[0052] Geometric feature point database creation module: used to acquire geometric data of EDA models and build a geometric feature point database;
[0053] The mapping table construction module renders the EDA model based on geometric data, obtains the rendered triangular facet data, creates triangular facet IDs for the triangular facets, and constructs a mapping table between the triangular facet IDs and the face IDs in the geometric feature point database.
[0054] Feature point picking module: used to pick geometric feature points of the model;
[0055] Display module: Used to render and display the geometric feature points picked up on the model.
[0056] The system of this invention has a simple composition. By establishing a mapping relationship between geometric data and model entities, and a mapping relationship between geometric data and rendering data, when the user's mouse approaches a feature point of the model, the screen pixel distance between the mouse point and the feature point of the rendering data is determined. If it is less than a threshold, the geometric feature data point of the model is quickly indexed through the mapping relationship, thereby achieving fast and accurate picking of model feature points and providing a high level of user experience.
[0057] Example 3
[0058] A computer-readable storage medium storing a computer program, which, when executed by a processor, implements the associative update method for EDA model modeling as described in any of the preceding claims. It is worth noting that, for those skilled in the art, besides implementing the system and modules provided in this application in purely computer-readable program code, the same program can be implemented by logically programming the method steps, making the system and modules provided in this application take the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers, etc. Therefore, the system and its modules provided in this application can be considered a hardware component, and the modules included therein for implementing various programs can also be considered structures within the hardware component. Furthermore, the modules for implementing various functions can be considered both software programs implementing the method and structures within the hardware component.
[0059] The examples described herein are merely preferred embodiments of the invention and are not intended to limit the concept and scope of the invention. Any modifications and improvements made by those skilled in the art to the technical solutions of the invention without departing from the design concept of the invention should fall within the protection scope of the invention.
Claims
1. A method for picking feature points in an EDA model, characterized in that: Includes the following steps: Obtain the geometric data of the EDA model and construct a geometric feature point database: The geometric feature point database includes constructing geometric feature point IDs for all geometric feature points, and creating a mapping table between edge IDs and feature point IDs at both ends of the edge, creating a mapping table between face IDs and feature point IDs at the center of the face, and creating a mapping table between face IDs and several edge IDs of the face. The EDA model is rendered based on geometric data to obtain rendered triangular facet data. Triangular facet IDs are created for each triangular facet, and a mapping table between triangular facet IDs and face IDs in the geometric feature point database is constructed. Pick up feature points: Obtain the pick position, determine the triangular facet where it is located based on the pick position, obtain the feature point position based on the mapping relationship table between the triangular facet ID and the face ID in the geometric feature point database, and render and display the feature point position; The specific steps for picking up feature points are as follows: Obtain the pickup position, and determine the triangular facet containing it and the triangular facet ID of the triangular facet based on the pickup position; Calculate the distance between the picking position and the triangle facet point of the triangle facet. If the distance is less than a threshold, index the geometric feature point data through the mapping table between the triangle facet ID and the face ID in the geometric feature point database. Then, index all vertices on the model through the geometric feature point database. Calculate the distance between the picking position and each vertex. If the distance is less than the threshold, it means that a vertex of the model has been picked. The triangle facet point is the rendering data feature point corresponding to the triangle facet. If the distance between the picking position and all vertices is greater than the threshold, then all edges on the model are indexed through the geometric feature point database to obtain the data of the edge center and quarter edge. The distance between the picking position and the edge center, and the distance between the picking position and the quarter edge are calculated. If the distance is less than the threshold, it means that the edge center or quarter edge of the model has been picked. If the distance between the picking position and the edge center, and the distance between the picking position and the quarter edge are both greater than the threshold, then all faces on the model are indexed through the geometric feature point database, and the distance between the picking position and the face center is calculated. If it is less than the threshold, it means that the face center of the model has been picked. The geometric feature points picked up on the model are rendered and displayed to achieve feature point picking; When picking feature points on the center of a sphere or an arc, a mapping table between model IDs and feature points is constructed when rendering the geometric data of the EDA model. When picking feature points, the model ID of the picking position is directly obtained, all feature points are obtained through the model ID, and the distance between the picking position and the feature point is calculated. If it is less than a threshold, it means that the feature point of the model has been picked.
2. The method for picking feature points in an EDA model according to claim 1, characterized in that: For 3D models, establish a mapping table between entity IDs and multiple Face IDs; for 2D models, establish a mapping table between Sheet IDs and Face IDs.
3. The method for picking feature points in an EDA model according to claim 1, characterized in that: The specific steps for rendering an EDA model based on geometric data include: obtaining all the triangular faces of the EDA model, creating triangular face IDs for each triangular face, and constructing a mapping table between the triangular face IDs and the face IDs in the geometric feature point database.
4. A system for using the method for picking feature points using an EDA model as described in any one of claims 1-3, characterized in that: include: Geometric feature point database creation module: used to acquire geometric data of EDA models and build a geometric feature point database; The mapping table construction module renders the EDA model based on geometric data, obtains the rendered triangular facet data, creates triangular facet IDs for the triangular facets, and constructs a mapping table between the triangular facet IDs and the face IDs in the geometric feature point database. Feature point picking module: used to pick geometric feature points of the model; Display module: Used to render and display the geometric feature points picked up on the model.
5. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by the processor, it implements a method for picking feature points in an EDA model as described in any one of claims 1-3.
Citation Information
Patent Citations
Mesh classification display method for EDA (Electronic Design Automation) model
CN115358123A
Local information pickup method and device of rendering entity, equipment and storage medium
CN116301519A