Intelligent plane drawing method based on external data processing platform
By integrating the independently developed plan drawing method and efficient data processing process in the intelligent plan drawing system, the problems of three-dimensional and two-dimensional data synchronization and unique reference number allocation are solved, and fast and accurate plan generation and data linkage are achieved, which improves the design efficiency and data security of the engineering project.
Patent Information
- Application Number
- CN202411788484.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-06
- Publication Date
- 2025-04-11
AI Technical Summary
Existing systems are inefficient when processing complex three-dimensional data, making it difficult to achieve seamless and real-time synchronization of three-dimensional and two-dimensional data, and cannot automatically assign unique reference numbers to each floor plan during batch plan drawing, resulting in difficulty in subsequent management and retrieval work.
Using an intelligent plan drawing method based on an external data processing platform, the integrated independently developed plan drawing method, streamlined and efficient data processing process, and a stable data security management system, the rapid and accurate generation of plan drawings is achieved, and real-time and accurate alignment between three-dimensional and two-dimensional data is ensured.
It significantly improves the speed and accuracy of data processing, shortens the graph production cycle, improves work efficiency and accuracy, realizes real-time linkage between three-dimensional and two-dimensional data, optimizes the data processing process, strengthens data security management, and improves user experience and satisfaction.
Smart Images

Figure CN119810314A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of intelligent construction model views, and in particular to an intelligent plane drawing method based on an external data processing platform. Background Art
[0002] With the continuous advancement of computer technology, 3D modeling and plane drawing technology have occupied an important position in many engineering projects; however, traditional drawing methods rely too much on manual operation, which not only leads to low efficiency, but also makes the error rate remain high; although many automated drawing systems have appeared on the market, these systems still face severe challenges in processing large-scale 3D data, realizing real-time linkage between 3D and 2D data, and efficient batch drawing; specifically, the existing system is inefficient in processing complex 3D data, and it is difficult to achieve seamless and real-time synchronization of 3D and 2D data; in addition, in the process of batch plane drawing, the system often cannot automatically assign a unique reference number to each plane drawing, which brings great trouble to subsequent management and retrieval work. Summary of the invention
[0003] The technical problem to be solved by the present invention is to provide an intelligent plane drawing method based on an external data processing platform. By integrating an independently developed plane drawing method, a streamlined and efficient data processing flow, and a stable data security management system, the rapid and accurate generation of plane drawings is achieved, and the real-time and accurate alignment between three-dimensional and two-dimensional data is ensured.
[0004] The technical solution adopted by the present invention to solve its technical problem is:
[0005] An intelligent plane drawing method based on an external data processing platform comprises the following steps:
[0006] S1. Model import, upload the 3D model file, and determine whether the imported model is valid; if the model is invalid, provide an error prompt and guide the user to re-upload; if the model is valid, proceed to the next step;
[0007] After importing the model, the visual schedule is updated to show the progress of the "Model Import" step;
[0008] S2, data segmentation and preprocessing, data segmentation of the effective three-dimensional model, extraction of geometric information and attributes of each component, and preprocessing of the segmented data;
[0009] S3. Generate a PCF file corresponding to each segment according to the split data, wherein the PCF file includes all information required to generate a plan view;
[0010] S4, converting the PCF file into a two-dimensional plane drawing by plane drawing method;
[0011] S5. Generate a plan view and a unique reference number, output the generated two-dimensional plan view, ensure that the drawing quality meets the design requirements, and generate a unique reference number for each plan view;
[0012] S6. Generate coordinates and data version management, generate corresponding coordinate information for each element on the two-dimensional plane, ensure the accurate correspondence between the drawing and the three-dimensional model, implement data version management, and record the history of each modification;
[0013] S7, 2D model data is linked with 3D data. When the 3D model is changed, the corresponding 2D plan view is automatically updated; when the 2D model is changed, the corresponding 3D plan view is automatically updated;
[0014] S8, review and release, the review includes automatic review, manual review, modification and re-review, and the release includes release preparation and release operation;
[0015] S9, output and storage, output and store the generated floor plan, unique reference number, coordinate information and version management record to a designated location.
[0016] In step S1, the visual schedule is displayed in an intuitive form through a graphical interface, which includes a progress bar, a timeline and a task list, reflecting the current progress and status of each step in an intuitive manner.
[0017] In step S6, the modification history record includes the modification time, the modifier and the modification content.
[0018] In step S7, the linkage between the two-dimensional model data and the three-dimensional data includes converting the pipeline layout and pipe connection in the two-dimensional model into a three-dimensional model.
[0019] In step S8, the automatic review performs a preliminary review of the generated plan through an intelligent algorithm to check whether the plan meets the design specifications, whether the markings are clear, and whether the information is complete;
[0020] After the automatic review is passed, the drawings will be further reviewed manually by professional reviewers to ensure the accuracy and compliance of the drawings;
[0021] The modification and re-examination include if any problem is found in the drawings during the review process, the problem will be fed back to the relevant personnel, who will modify the drawings and resubmit them for review.
[0022] In step S8, the release preparation includes final arrangement and optimization after the drawings are reviewed and approved to ensure the quality and readability of the drawings;
[0023] The publishing operation includes publishing the sorted drawings to a designated platform or system for users to view and download; at the same time, recording information such as the publishing time, publishing platform and publishing status of the drawings.
[0024] The beneficial effects of the present invention are:
[0025] 1. By integrating the independently developed plane drawing method, streamlined and efficient data processing process, and a stable data security management system, the plane drawing is generated quickly and accurately, and the real-time and accurate alignment between three-dimensional and two-dimensional data is ensured; compared with the traditional method, which relies too much on manual operation, data processing and drawing are time-consuming and error-prone, especially when facing large-scale three-dimensional data processing, the efficiency is significantly reduced, and it is difficult to meet the high requirements of modern engineering projects for fast and accurate drawing; by greatly improving the speed and accuracy of data processing, the drawing cycle is significantly shortened, providing solid technical support for the efficient implementation of engineering projects.
[0026] 2. Improve work efficiency and accuracy: By introducing advanced graphics processing technology and independently developed plane drawing methods, it is able to quickly process large-scale three-dimensional data in engineering projects and quickly generate accurate plane drawings, significantly shortening the drawing cycle; automated processing and intelligent algorithms reduce the possibility of human errors and improve the accuracy of drawings.
[0027] 3. Realize real-time linkage between 3D and 2D data: ensure real-time and accurate synchronization between 3D and 2D data, so that when designers modify the 3D model, the floor plan can be automatically updated without manual adjustment, improving design efficiency and consistency; through the graphical interface and intuitive operation method, the linkage relationship between 3D and 2D data can be easily viewed and managed, reducing the difficulty of operation.
[0028] 4. Optimize data processing flow: By streamlining and optimizing the data processing flow, unnecessary steps and redundant information are reduced, and the efficiency and accuracy of data processing are improved; by introducing intelligent algorithms and automation technology, anomalies and errors in data can be automatically identified and processed, reducing the need for manual intervention.
[0029] 5. Strengthen data security management: A reinforced data security management mechanism is adopted to ensure the security and integrity of data during processing and storage; strict data access control and encryption technology are used to effectively prevent data leakage and illegal access, and protect the privacy and rights of users.
[0030] 6. Improve user experience and satisfaction: The graphical interface design is intuitive and easy to use, allowing users to easily get started and quickly master the operation methods; users can choose different modules and functions to combine and match according to their needs and preferences to achieve personalized customization, which improves user satisfaction and usage experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 Produce a flow chart for the intelligent plan drawing system;
[0032] Figure 2 Provide a visual progress flow chart for the intelligent plan drawing system;
[0033] Figure 3 It is a schematic diagram of the linkage between three-dimensional and two-dimensional data;
[0034] Figure 4 This is a schematic diagram for calculating the distance between two points on a plane;
[0035] Figure 5 It is a geometric diagram of vector addition;
[0036] Figure 6 It is a geometric diagram of vector subtraction;
[0037] Figure 7 This is a schematic diagram of the straight line segment straddling test;
[0038] Figure 8 Schematic diagram of the structure of various intersection points that may be encountered by the ray method. DETAILED DESCRIPTION
[0039] The present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0040] Implementation 1
[0041] An intelligent plane drawing method based on an external data processing platform comprises the following steps:
[0042] S1. Model import: upload or select a 3D model file. The system automatically determines whether the imported model is valid. The imported model includes checking the file format, integrity, and whether it meets the preset standards. If the model is invalid, an error prompt is provided and the user is guided to re-upload. If the model is valid, the system proceeds to the next step. Visual schedule control: after importing the model, the visual schedule is updated to display the progress of the "model import" step.
[0043] S2, data segmentation and preprocessing, data segmentation of the effective three-dimensional model, extraction of geometric information and attributes of each component, and preprocessing of the segmented data;
[0044] The preprocessing includes denoising and simplification to improve the efficiency of subsequent processing, and the visual schedule is updated to show that the "data splitting and preprocessing" step is in progress and the remaining time is estimated;
[0045] S3, generating a PCF file for each segment, and generating a PCF file corresponding to each segment according to the split data, wherein the PCF file includes all information required to generate a plan view;
[0046] When the PCF file is generated, the visualized schedule is updated to show that the "Generate PCF file" step has been completed;
[0047] S4, converting the PCF file into a two-dimensional plane drawing by plane drawing method;
[0048] The algorithm considers the readability of the drawing, the clarity of annotations, and the completeness of the information;
[0049] During the algorithm operation, the visual schedule is updated in real time to show the progress and estimated remaining time of the "plan drawing method operation";
[0050] S5. Generate a floor plan and a unique reference number, output the generated floor plan, ensure that the drawing quality meets the design requirements, and generate a unique reference number for each floor plan to facilitate subsequent management and search;
[0051] When the floor plan is generated, the visual schedule is updated to show that the "Generate Floor Plan and Unique Reference Number" step has been completed;
[0052] S6. Generate coordinates and data version management, generate corresponding coordinate information for each element on the plane, ensure accurate correspondence between the drawing and the 3D model, implement data version management, and record the history of each modification;
[0053] After generating the coordinates and data version management information, update the visualized schedule to show that the "Generate Coordinates and Data Version Management" step has been completed;
[0054] S7, 2D model data is linked with 3D data. When the 3D model is changed, the corresponding 2D plan view is automatically updated; when the 2D model is changed, the corresponding 3D plan view is automatically updated;
[0055] During the linkage update process, the visual schedule is updated in real time to display the progress and status of the "2D and 3D data linkage";
[0056] S8, review and release, the review includes automatic review, manual review, modification and re-review, and the release includes release preparation and release operation;
[0057] In the review and release process, the visual progress plan is updated in real time to show the overall progress and status of "review and release", including automatic review, manual review, modification and re-review, release preparation and release operation;
[0058] S9, output and storage, output and store the generated floor plan, unique reference number, coordinate information and version management record to a designated location.
[0059] Provide a user-friendly interface to facilitate users to view and manage generated drawings and data;
[0060] After the output and storage steps are completed, the visual schedule is updated to show that the entire output process has been completed.
[0061] In step S1, the visual schedule control is displayed in an intuitive form through a graphical interface, and the graphical interface includes a progress bar, a timeline and a task list, which reflects the current progress and status of each step in an intuitive manner.
[0062] In step S6, the modification history record includes the modification time, the modifier and the modification content.
[0063] In step S7, the linkage between the two-dimensional model data and the three-dimensional data includes converting the pipeline layout and pipe connection in the two-dimensional model into a three-dimensional model.
[0064] In step S8, the automatic review performs a preliminary review of the generated plan through an intelligent algorithm to check whether the plan meets the design specifications, whether the markings are clear, and whether the information is complete;
[0065] After the automatic review is passed, the drawings will be further reviewed manually by professional reviewers to ensure the accuracy and compliance of the drawings;
[0066] The modification and re-examination includes if any problem is found in the drawing during the review process, the problem will be fed back to the relevant personnel, who will modify the drawing and resubmit it for review; this process may be repeated until the drawing fully meets the requirements.
[0067] In step S8, the release preparation includes final arrangement and optimization after the drawings are reviewed and approved to ensure the quality and readability of the drawings;
[0068] The publishing operation includes publishing the sorted drawings to a designated platform or system for users to view and download; at the same time, recording information such as the publishing time, publishing platform and publishing status of the drawings.
[0069] By integrating the independently developed plan drawing method, a streamlined and efficient data processing process, and a stable data security management system, the plan drawings are generated quickly and accurately, and the real-time and accurate alignment between three-dimensional and two-dimensional data is ensured; compared with the traditional method, which relies too much on manual operation, data processing and drawing are time-consuming and error-prone, especially when facing large-scale three-dimensional data processing, the efficiency is significantly reduced, and it is difficult to meet the high requirements of modern engineering projects for fast and accurate drawing; by greatly improving the speed and accuracy of data processing, the drawing cycle is significantly shortened, providing solid technical support for the efficient implementation of engineering projects.
[0070] Improve work efficiency and accuracy: By introducing advanced graphics processing technology and independently developed plane drawing methods, it is possible to quickly process large-scale three-dimensional data in engineering projects and quickly generate accurate plane drawings, significantly shortening the drawing cycle; automated processing and intelligent algorithms reduce the possibility of human errors and improve the accuracy of drawings.
[0071] Realize real-time linkage between 3D and 2D data: ensure real-time and accurate synchronization between 3D and 2D data, so that when designers modify the 3D model, the floor plan can be automatically updated without manual adjustment, improving design efficiency and consistency; through the graphical interface and intuitive operation method, the linkage relationship between 3D and 2D data can be easily viewed and managed, reducing the difficulty of operation.
[0072] Optimize data processing flow: By streamlining and optimizing the data processing flow, unnecessary steps and redundant information are reduced, and the efficiency and accuracy of data processing are improved; by introducing intelligent algorithms and automation technology, anomalies and errors in data can be automatically identified and processed, reducing the need for human intervention.
[0073] Strengthen data security management: A reinforced data security management mechanism is adopted to ensure the security and integrity of data during processing and storage; strict data access control and encryption technology are used to effectively prevent data leakage and illegal access, and protect the privacy and rights of users.
[0074] Improve user experience and satisfaction: The graphical interface design is intuitive and easy to use, allowing users to easily get started and quickly master the operation methods; users can choose different modules and functions to combine and match according to their needs and preferences to achieve personalized customization, which improves user satisfaction and usage experience.
[0075] like Figure 1As shown in the figure, it covers everything from the initial 3D model import to the final high-quality plane drawing output; specifically, the process begins with the user importing the 3D model data of the engineering project into the system; then, the data will enter the preprocessing stage, including core links such as data cleaning and format conversion to ensure the efficiency and accuracy of subsequent processing; then, the system uses the self-developed plane drawing method to conduct in-depth analysis and conversion of the preprocessed data, and accurately extract the key information required to generate two-dimensional drawings; on this basis, the system can automatically generate two-dimensional plane drawings that are completely consistent with the 3D model; to ensure the accuracy and completeness of the drawings, the system also implements real-time linkage verification of 3D and 2D data; finally, the strictly verified two-dimensional plane drawings will be output by the system, and further optimized and adjusted according to project requirements; the entire process is presented through intuitive graphic elements and clear process lines, which is easy for users to understand and operate, and fully demonstrates the excellent performance of the intelligent plane drawing system in terms of efficiency, accuracy and flexibility.
[0076] like Figure 2 As shown in the figure, first, according to the actual needs of the engineering project, the specific number and type of floor plans that need to be generated are clarified; then, according to the structure and characteristics of the three-dimensional data, a reasonable visualization schedule is formulated; then, the system will automatically perform data processing and view division according to this plan; during the execution process, the system will conduct real-time monitoring and flexibly adjust the progress according to the actual situation to ensure that the plan can be completed on time; finally, the system will strictly verify and evaluate the execution results of the plan, and provide valuable references and improvement suggestions for future project implementation; the entire process is highly automated, which significantly improves the efficiency and accuracy of drawing work.
[0077] like Figure 3 As shown in the figure, the linkage mechanism between the two is clearly depicted; the whole process of importing 3D model and 2D drawing data into the external platform is shown in detail; after the external platform successfully reads these 2D or 3D data, it can intelligently reverse generate the corresponding 3D or 2D data, and automatically feed back the updated data to the corresponding original 3D model or 2D drawing; more importantly, when any modification or editing occurs to the 2D drawing or 3D model, the system can capture these changes in real time and send the modification information to the external platform for synchronous update; then, the updated data will be automatically synchronized back to the corresponding 3D model or 2D drawing to ensure the consistency and accuracy of the data; the whole process embodies a high degree of intelligence and automation, effectively ensuring the accuracy and consistency of the data.
[0078] In step S1, compression detection and decompression functions for model files are added to support uploading of larger model files while reducing upload time; the type judgment algorithm is optimized to improve judgment speed and accuracy and reduce import failures due to format mismatch or file corruption; a model preview function is introduced to view the model's thumbnail or basic form during the import process, allowing users to quickly confirm the validity of the model.
[0079] In step S2, the data splitting algorithm can be improved to improve the splitting efficiency and accuracy, ensuring that the data of each component can be correctly extracted; parallel processing technology can be introduced to process the data of multiple components simultaneously to further shorten the preprocessing time; the preprocessing process can be optimized to reduce unnecessary calculation steps and reduce resource consumption.
[0080] In step S3, the PCF generation algorithm is optimized to improve the generation speed and file quality, ensuring that the generated PCF file can accurately reflect the geometry and attribute information of the model; an intelligent caching mechanism is introduced to cache the generated PCF files to avoid repeated generation and improve overall efficiency; and user-defined PCF output format options are provided to meet the needs of different users.
[0081] In step S4, the plane drawing method is deeply optimized to improve the stability and accuracy of the algorithm and reduce the failure of drawing generation due to algorithm errors; adaptive layout technology is introduced to automatically adjust the layout according to the drawing content to ensure the readability and aesthetics of the drawing; and optimization processing functions for complex models are added, such as automatic simplification and denoising, to improve drawing efficiency and quality.
[0082] In step S5, the generation speed and quality are improved to ensure that the generated drawings meet the design requirements; an intelligent numbering system is introduced to automatically generate unique reference numbers, reduce manual intervention, and improve the accuracy and consistency of numbering. User-defined drawing output formats and size options are provided to meet the needs of different users.
[0083] In step S6, the accuracy and efficiency of coordinate calculation are improved; a version management system is introduced to record the history of each modification and provide a rollback function to ensure the traceability and security of the data; a user-friendly version management interface is provided to facilitate users to view and manage version information.
[0084] In step S7, the update speed and accuracy are improved to ensure real-time synchronization between the two-dimensional plan and the three-dimensional model; an intelligent conflict detection mechanism is introduced to automatically detect and handle potential conflicts during the linkage update process to avoid data inconsistency; and user-defined linkage update options are provided, such as manually triggered updates, scheduled updates, etc., to meet the needs of different users.
[0085] In step S8, an intelligent review assistant is introduced to assist reviewers in quickly identifying and handling issues in drawings. A parallel review mechanism is introduced to review multiple drawings simultaneously to improve review efficiency; the publishing process is optimized, a one-click publishing function is provided, publishing operations are simplified, and publishing speed is increased.
[0086] In step S9, a variety of output formats and size options are provided to meet the needs of different users; an intelligent storage mechanism is introduced to automatically classify and store the generated drawings and data for easy subsequent search and management. A user-friendly output and storage interface is provided to facilitate users to view and manage the generated drawings and data.
[0087] Implementation 2
[0088] A large-scale architectural design project is used as the background. The project requires the rapid and accurate generation of a large number of 2D construction drawings to support the smooth progress of the project. In order to improve the design efficiency, it is decided to use an intelligent plane drawing system and combine it with Figure 1 , Figure 2 and Figure 3 To optimize its design process.
[0089] First, the 3D model of the building was constructed using 3D modeling software; then, Figure 1 The process shown imports the 3D model data into the intelligent plane drawing system; at this point, the system automatically performs pre-processing operations such as data cleaning and format conversion to ensure the accuracy and consistency of the data.
[0090] Next, refer to Figure 2 The visual schedule formulation flow chart is set in the system, and a detailed drawing plan is set in the system; the plan includes key information such as the time node, drawing type, quantity, etc. of the drawing; the system automatically generates a visual schedule based on this plan to provide guidance for subsequent drawing work; at the same time, a linkage relationship is set between the 3D model and the 2D drawing; during the design process, whenever the 3D model is modified, the system will update the corresponding 2D drawing in real time; this linkage mechanism ensures the consistency between the 2D drawing and the 3D model, and improves the accuracy of the design. The linkage diagram is shown in the figure below Figure 3 shown.
[0091] Then, according to the visual schedule, the system automatically uses the plane drawing method to process the three-dimensional data and generate the corresponding two-dimensional plane drawings; the generated two-dimensional drawings are strictly verified by the system to ensure the accuracy and completeness of the drawings; if necessary, the drawings can be further adjusted and optimized; finally, the verified drawings are output by the system and optimized and adjusted according to actual needs; the optimized drawings are verified by the system again to ensure that they meet the project requirements.
[0092] Example 3
[0093] This example is based on a bridge reconstruction project. The project requires rapid response to design changes and generation of two-dimensional construction drawings that meet project requirements. In order to improve design efficiency, it is decided to use an intelligent plane drawing system and combine it with Figure 1 , Figure 2 as well as Figure 3 To optimize its design process.
[0094] First, follow Figure 1 The process shown imports the 3D model data into the intelligent plane drawing system, and performs pre-processing operations such as data cleaning and format conversion to ensure the accuracy and consistency of the data.
[0095] Then, refer to Figure 2 The system sets a detailed plan for drawing, clarifies the key information such as the time node, drawing type (such as bridge structure drawing, construction drawing, etc.) and quantity of drawing; at the same time, Figure 3 Under the guidance of the schematic diagram of the linkage between 3D and 2D data shown in the figure, a linkage relationship between the 3D model and the 2D drawings is set up; during the design process, whenever the 3D model of the bridge is modified, such as adjustment of the bridge structure or replacement of materials, the system will update the corresponding 2D drawings in real time to ensure the consistency between the 2D drawings and the 3D model.
[0096] Finally, based on the visual schedule, the system automatically uses the plane drawing method to generate two-dimensional plane drawings that meet project requirements, and undergoes strict verification to ensure the accuracy and completeness of the drawings. After the verified drawings are output by the system, they are optimized and adjusted according to actual needs.
[0097] The planar drawing method comprises the following steps:
[0098] K1. Computer graphics algorithms;
[0099] K1.1. Determine whether the point is within the rectangle as follows:
[0100] The relationship between computer graphics and mathematics: First, there is the algorithm for determining whether a point is within a rectangle. This is a very simple algorithm, but it is very important. For example, when you click the mouse on a button, how does the system know to trigger the event corresponding to this button instead of another button? This is the determination of whether a point is within a rectangle. The Windows API provides the PtInRect() function. The implementation method is actually to determine whether the x-coordinate and y-coordinate of the point fall within the x-coordinate range and y-coordinate range of the rectangle at the same time. The algorithm code is implemented as follows:
[0101] bool IsPointInRect(const Rect&rc,const Point&p)
[0102] {double xr=(px-rc.p1.x)*(px-rc.p2.x);
[0103] double yr=(py-rc.p1.y)*(py-rc.p2.y);
[0104] return((xr<=0.0)&&(yr<=0.0));}
[0105] The implementation of the IsPointInRect() function, if the hardware implementation of multiplication is difficult or is limited by the efficiency of the CPU multiplication instruction, can be replaced by the following function to avoid multiplication operations:
[0106] bool IsPointInRect(const Rect&rc,const Point&p)
[0107] double xl,xr,yt,yb;
[0108] if(rc.p1.x <rc.p2.x)
[0109] {xl = rc.p1.x;
[0110] xr = rc.p2.x;}
[0111] else
[0112] {xl = rc.p2.x;
[0113] xr = rc.p1.x;}
[0114] if(rc.p1.y <rc.p2.y)
[0115] {yt = rc.p2.y;
[0116] yb = rc.p1.y;}
[0117] else
[0118] {yt = rc.p1.y;
[0119] yb = rc.p2.y;}
[0120] return((px>=xl&&p.x<=xr)&&(py>=yb&&p.y<=yt));
[0121] Since the IsPointInRect() function does not assume that the two fixed points of the rectangle are arranged in ascending order of the coordinate axes, all possible coordinate ranges are considered in the algorithm implementation; the IsPointInRect() function uses the Cartesian coordinate system, and all algorithms are designed based on the Cartesian coordinate system; in addition, the IsPointInRect() function does not specify a special floating-point precision range, and the default is the maximum precision of the system floating-point number. Only in some cases where it is necessary to compare with 0, a precision of 10^-8 is adopted.
[0122] K1.2. To determine whether a point is inside a circle, as follows:
[0123] If the button on the graphical interface is a circle instead of a rectangle, then determine whether the point is inside the circle? The principle of the determination algorithm is to calculate the distance d from the point to the center of the circle, and then compare it with the radius r of the circle. If d < r, it means the point is inside the circle; if d = r, it means the point is on the circle; if d > r, it means the point is outside the circle; the algorithm for calculating the distance between two points on a plane; as follows Figure 4 For example, to calculate the distance between any two points on a plane based on the Pythagorean theorem, as follows:
[0124] double PointDistance(const Point&p1,const Point&p2)
[0125] {return std::sqrt((p1.x - p2.x)*(p1.x - p2.x)+(p1.y - p2.y)*(p1.y - p2.y))};
[0126] K1.3. To determine whether a point is inside a polygon, as follows:
[0127] Irregular polygon regions are usually represented by various irregular patterns as hot spots. Windows also provides the PtInRegion() API to determine whether a point is in an irregular region; to simplify the problem, just determine whether a point is inside a polygon? Determining whether a point P is inside a polygon is a very basic algorithm in computational geometry. The most commonly used method is the ray method; taking point P as the endpoint, draw a ray L to the left, and then move along L from infinity towards point P. When encountering a side of the polygon, it is recorded as the first intersection point with the polygon, indicating entering the interior of the polygon. Continuing to move, when encountering another intersection point, it indicates leaving the interior of the polygon; thus, it can be known that when the number of intersection points of L and the polygon is even, it means point P is outside the polygon, and when the number of intersection points of L and the polygon is odd, it means point P is inside the polygon.
[0128] K1.2. Vector basic algorithms, as follows:
[0129] (1) Vector: A vector is a quantity that has both magnitude and direction, and is often called a vector. Vectors can be expressed in many forms, including geometric, algebraic, and coordinate. If the endpoints of a line segment are in order, this line segment is called a directed segment. For example, line segment P 1 P 2 , if the starting endpoint P 1 is the coordinate origin (0,0), P 2 The coordinates of the line segment P are (x, y). 1 P 2 The two-dimensional vector coordinate representation is P = (x, y).
[0130] (2) Vector addition and subtraction are as follows:
[0131] First, let's talk about vector addition and subtraction. Assuming there are two-dimensional vectors P = (x1, y1), Q = (x2, y2), then vector addition is defined as:
[0132] P+Q=(x1+x2,y1+y2)
[0133] Similarly, vector subtraction is defined as:
[0134] PQ=(x1-x2,y1-y2)
[0135] According to the definition of vector addition and subtraction, vector addition and subtraction satisfy the following properties:
[0136] P+Q=Q+P
[0137] PQ=-(QP)
[0138] like Figures 5 to 6 As shown in the figure, the geometric meaning of vector addition and subtraction is that in geometry, two points on a straight line segment cannot be exactly at the origin, so the line segment P 1 P 2 The vector is actually OP 2 -OP 1 result.
[0139] Calculating the cross product of vectors is the core algorithm for determining the positional relationship between a straight line and a line segment, a line segment and a line segment, and a line segment and a point. Assuming there is a two-dimensional vector P = (x1, y1), Q = (x2, y2), the cross product of the vector is defined as: P×Q = x1*y2-x2*y1.
[0140] The geometric meaning of the vector cross product can be described as the area of the parallelogram formed by the coordinate origin (0,0), P, Q and P+Q, and it is a signed area. From this, we can see that the cross product of the vector has the following properties: P×Q=-(Q×P)
[0141] The result of the cross product, P×Q, is the normal vector of the plane where P and Q are located. Its direction is perpendicular to the plane where P and Q are located, and a right-hand system is formed in the order of P, Q, and P×Q. Therefore, another very important property of the cross product is that its sign can be used to determine whether the position relationship between the two vectors is clockwise or counterclockwise, as follows:
[0142] 1) If P×Q>0, then Q is counterclockwise of P;
[0143] 2) If P×Q<0, then Q is clockwise of P;
[0144] 3) If P×Q=0, then Q is collinear with P (but may be in opposite directions);
[0145] (4) Dot product (inner product) of vectors
[0146] The last concept to be introduced is the dot product (inner product) of vectors. Assuming there is a two-dimensional vector P = (x1, y1), Q = (x2, y2), the dot product of the vector is defined as: P·Q = x1*x2+y1*y2.
[0147] The result of the vector dot product is a scalar, whose algebraic representation is: P·Q=|P||Q|cos(P,Q).
[0148] (P,Q) represents the angle between vectors P and Q. If P and Q are not collinear, a very important property of the vector dot product can be obtained according to the above formula, as follows:
[0149] 1) If P·Q>0, the angle between P and Q is obtuse (greater than 90 degrees);
[0150] 2) If P·Q<0, then the angle between P and Q is acute (less than 90 degrees);
[0151] 3) If P·Q=0, then the angle between P and Q is 90 degrees;
[0152] Understanding the concept of vectors and the geometric and algebraic meanings of various vector operations can help us solve various simple problems in computational geometry and the relationship between points and polygons. The first thing to solve is to determine the positional relationship between points and straight line segments.
[0153] K1.3, vector judgment algorithm, as follows:
[0154] (1) Use the cross product of vectors to determine the relationship between a point and a line.
[0155] According to the geometric meaning of the vector cross product, if the cross product of the vector represented by the line segment and the vector of the point is 0, it means that the point is on the straight line where the line segment is located. Relative to the coordinate origin O, the vector of the line segment is actually the end point P of the line segment.2 =[x 2 ,y 2 ]'s vector OP 2 Starting point of the subtraction segment P 1 =[x 1 ,y 1 ]'s vector OP 1 As a result, the line segment P 1 P 2 The vector can be expressed as P 1 P 2 =(x 2 –x 1 ,y 2 –y 1 ); If you want to determine whether point P is on line segment P 1 P 2 We need to determine the vector P 1 P 2 Is the cross product of point P and line segment P 0? 1 P 2 The fact that the straight lines are collinear does not mean that point P will definitely fall on P 1 P 2 interval, so it is only a necessary condition. To correctly judge P on the line segment P 1 P 2 In addition, an exclusion test is required to check whether point P is in the rectangular space with the straight line segment as the diagonal. If the above two conditions are true, the point can be determined to be on the line segment. The algorithm for determining whether a point is on a line segment is as follows:
[0156] bool IsPointOnLineSegment(const LineSeg&ls,const Point&pt)
[0157] {Rect rc;
[0158] GetLineSegmentRect(ls,rc);
[0159] Double cp=CrossProduct(ls.pe.x-ls.ps.x,ls.pe.y-ls.ps.y,pt.x-ls.ps.x,pt.y-ls.ps.y);
[0160] return((IsPointInRect(rc,pt))&&IsZeroFloatValue(cp));}
[0161] K2. Use the cross product of vectors to determine whether straight line segments intersect;
[0162] Another common use of vector cross product calculation is to find the intersection of straight line segments. The intersection algorithm is the core algorithm of computer graphics and an important indicator of speed and stability. It is an efficient and stable intersection algorithm. Intersection contains two concepts, one is to determine whether there is intersection, and the other is to find the intersection point. The intersection algorithm of straight lines (segments) is relatively simple. First, let's take a look at how to determine whether two straight line segments intersect.
[0163] Conventional algebraic calculations usually consist of three steps. First, the equations of the lines where the two line segments are located are restored based on the line segments. Then, the system of equations is used to find the intersection. Finally, it is determined whether the intersection is on the line segment interval. Conventional algebraic methods are very cumbersome, and the system of equations must be solved every time to find the intersection. Especially when the intersection is not on the line segment interval, calculating the intersection is a waste of effort. The computational geometry method to determine whether a line segment has an intersection is usually completed in two steps, namely the rapid exclusion test and the straddle test. Suppose you want to determine whether the line segment P 1 P 2 and line segment Q 1 Q 2 If there is an intersection, then:
[0164] ① Rapid rejection test
[0165] Suppose line segment P 1 P 2 The diagonal rectangle is R 1 , let the line segment Q 1 Q 2 The diagonal rectangle is R 2 , if R 1 and R 2 If they do not intersect, the two line segments will not have an intersection point;
[0166] ②Straddle test
[0167] like Figure 7 As shown in the figure, if two line segments intersect, then the two line segments must straddle each other. The so-called straddling means that the two endpoints of one line segment are located on either side of the line where the other line segment is located. To determine whether it is straddling, we still need to use the geometric meaning of the vector cross product; if P 1 P 2 Straddling Q 1 Q 2 , then the vector (P 1 -Q 1 ) and (P 2 -Q 1 ) is located in the vector (Q 2 -Q 1 ), namely:
[0168] (P 1 -Q 1 )×(Q2 -Q 1 )*(P 2 -Q 1 )×(Q 2 -Q 1 )<0.
[0169] The above formula can be rewritten as:
[0170] (P 1 -Q 1 )×(Q 2 -Q 1 )*(Q 2 -Q 1 )×(P 2 -Q 1 )>0.
[0171] When (P 1 -Q 1 )×(Q 2 -Q 1 )=0, indicating that line segment P 1 P 2 and Q 1 Q 2 Collinear (but not necessarily have an intersection); judge Q in the same way 1 Q 2 Straddle P 1 P 2 The basis is:
[0172] (Q 1 -P 1 )×(P 2 -P 1 )*(Q 2 -P 1 )×(P 2 -P 1 )<0.
[0173] According to the geometric meaning of the vector cross product, the straddle test can only prove that the two endpoints of a line segment are located on both sides of the straight line where the other line segment is located, but it cannot guarantee that they are at the two ends of the other straight line segment. The straddle test is only a necessary condition to prove that two line segments have an intersection. It must be combined with the rapid repulsion test to form the necessary and sufficient conditions for the intersection of straight line segments.
[0174] K3, algorithms for the relationship between points and polygons;
[0175] Understand the meaning of vector cross product and the algorithm to determine whether straight line segments intersect; the core of how to determine whether a point is inside a polygon is to find out whether the ray emitted from point P intersects the edge of the polygon; the idea of abstracting and simplifying the model according to the scale and nature of the problem domain. Computers cannot represent infinity and infinitesimals. Every number processed by the computer has a definite value and must have a definite value; the problem domain is the coordinate system of the entire real number space, which is from negative infinity to positive infinity in each dimension. For example, a ray is a line connecting a clear point in the coordinate system to infinity; this is a bit... It is difficult to calculate, so we need to simplify the scale of the problem; assuming that the coordinates of each point of the polygon in the problem will not exceed the interval (-10000.0, +10000.0) (for example, common graphics output devices have size limitations), the problem domain can be simplified to a small area in the interval (-10000.0, +10000.0). For this area, >=10000.0 means infinity; after the mathematical model is simplified, the ray mentioned in the algorithm can be understood as a line segment from the model boundary to the internal point P, and the algorithm for line segments discussed earlier can be used.
[0176] The basic principle of the ray method is to determine the number of intersections between the ray emitted from point P and the polygon. An odd number of intersections means that point P is inside the polygon (the edge of the polygon is also considered as a special case of being inside the polygon). Under normal circumstances, the ray passing through point P should be as follows: Figure 8 (a), but there may be many abnormal situations, such as passing through a fixed point of the polygon, such as Figure 8 (b) This can be mistakenly interpreted as having intersections with both edges, and may also be collinear with one edge. Figure 8 (c) and (d) have infinite intersection points if they are collinear, which makes the judgment rule invalid. We also need to consider the case of concave polygons, as shown in the figure.
[0177] For these special cases, when judging each edge of the polygon, the following special cases should be considered. Assume that the edge currently being processed is P 1 P 2 , the following principles apply:
[0178] 1) If point P is on edge P 1 P 2 On, then directly determine that point P is inside the polygon;
[0179] 2) If the ray emitted from P passes through P 1 or P 2 , then this intersection will be counted twice (because in the processing of P 1 or P 2The principle for handling this situation is: if the y coordinate of P is the same as P 1 , P 2 If the smaller y coordinate is the same, ignore this intersection point;
[0180] 3) If the ray emitted from P is 1 P 2 If they are parallel, ignore this edge;
[0181] For the third principle, we need to determine whether two straight lines are parallel. The usual method is to calculate the slopes of the two straight lines. However, this algorithm is much simpler because it only involves straight line segments (the rays are also simplified into long line segments by the model). To determine whether the straight lines are horizontal, we only need to compare whether the y coordinates of the starting points of the line segments are equal. To determine whether the straight lines are vertical, we only need to compare whether the x coordinates of the starting points of the line segments are equal.
[0182] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various changes and variations. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. An intelligent plane drawing method based on an external data processing platform, characterized in that: The following steps are involved: S1. Model import, upload the 3D model file, and determine whether the imported model is valid; if the model is invalid, provide an error prompt and guide the user to re-upload; if the model is valid, proceed to the next step; After importing the model, the visualized schedule is updated to show the progress of the "Model Import" step; S2, data segmentation and preprocessing, data segmentation of the effective three-dimensional model, extraction of geometric information and attributes of each component, and preprocessing of the segmented data; S3. Generate a PCF file corresponding to each segment according to the split data, wherein the PCF file includes all information required to generate a plan view; S4, converting the PCF file into a two-dimensional plane drawing by plane drawing method; S5. Generate a plan view and a unique reference number, output the generated two-dimensional plan view, ensure that the drawing quality meets the design requirements, and generate a unique reference number for each plan view; S6. Generate coordinates and data version management, generate corresponding coordinate information for each element on the two-dimensional plane, ensure the accurate correspondence between the drawing and the three-dimensional model, implement data version management, and record the history of each modification; S7, 2D model data is linked with 3D data. When the 3D model is changed, the corresponding 2D plan view is automatically updated; when the 2D model is changed, the corresponding 3D plan view is automatically updated; S8, review and release, the review includes automatic review, manual review, modification and re-review, and the release includes release preparation and release operation; S9, output and storage, output and store the generated floor plan, unique reference number, coordinate information and version management record to a designated location.
2. The intelligent plane drawing method based on an external data processing platform according to claim 1, characterized in that: In step S1, the visual schedule is displayed in an intuitive form through a graphical interface, which includes a progress bar, a timeline and a task list, reflecting the current progress and status of each step in an intuitive manner.
3. The intelligent plane drawing method based on an external data processing platform according to claim 1, characterized in that: In step S6, the modification history record includes the modification time, the modifier and the modification content.
4. The intelligent plane drawing method based on an external data processing platform according to claim 1, characterized in that: In step S7, the linkage between the two-dimensional model data and the three-dimensional data includes converting the pipeline layout and pipe connection in the two-dimensional model into a three-dimensional model.
5. The intelligent plane drawing method based on an external data processing platform according to claim 1, characterized in that: In step S8, the automatic review performs a preliminary review on the generated plan to check whether the plan meets the design specifications, whether the markings are clear, and whether the information is complete; After the automatic review is passed, the drawings will be further reviewed manually by professional reviewers to ensure the accuracy and compliance of the drawings; The modification and re-examination include if any problem is found in the drawings during the review process, the problem will be fed back to the relevant personnel, who will modify the drawings and resubmit them for review.
6. The intelligent plane drawing method based on an external data processing platform according to claim 1, characterized in that: In step S8, the release preparation includes final arrangement and optimization after the drawings are reviewed and approved to ensure the quality and readability of the drawings; The publishing operation includes publishing the sorted drawings to a designated platform or system for users to view and download; at the same time, recording information such as the publishing time, publishing platform and publishing status of the drawings.
Citation Information
Patent Citations
CIM system working method based on BIM and GIS technologies
CN113268531A
CPIM-based three-dimensional visual full-life-cycle management platform for coal preparation plant
CN114386774A
Drawing examination method and system based on building information model
CN118314007A
Drawing mutual export drawing method and system based on two-dimensional and three-dimensional conversion
CN119026197A
Automatic labeling method and system for pipeline three-dimensional building information modeling
WO2024045615A1