Design drawing generation method and device, equipment and storage medium
By generating and processing the vector data of the inner and outer wall lines of the house, combining the position relationship and ruler data of the wall attachments, the design drawings are automatically generated, which solves the cumbersome and inefficient problems of manual measurement and drawing of CAD diagrams in the existing technology, and realizes the Efficient and accurate design drawing generation.
Patent Information
- Application Number
- CN202411456373.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-10-17
AI Technical Summary
In the prior art, it is necessary to manually measure and record the dimension information of the walls, doors and windows of the house, and then draw sketches and draw CAD diagrams in professional software. The operation is cumbersome, time-consuming and difficult to ensure the drawing accuracy, resulting in the drawing effect of the CAD diagram. Poor.
By generating the first representation data of the exterior wall line based on the inner wall line vector data of the target house, and combining the data of the inner wall line and wall attachment, the position relationship between the wall attachment and the inner wall and the outer wall and the ruler are determined as well as the ruler of the wall attachment and the wall attachment and the wall attachment and the wall attachment as well as the Data, and finally generate design drawings.
It realizes automatic generation of design drawings without manual participation, improves the generation efficiency and accuracy of design drawings, and ensures that the display effect of design drawings is good and cost-effective.
Smart Images

Figure CN119416316A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a method, device, equipment and storage medium for generating a design drawing. Background Art
[0002] In many fields, such as home decoration and architectural design, it is usually necessary to use computer-aided design (CAD) drawings to complete relevant designs. At present, it is necessary to manually measure and record the size information of the walls, doors, and windows of the house, and then draw a sketch, and then draw a CAD drawing in professional software based on the sketch. This method is cumbersome, time-consuming and labor-intensive, and it is difficult to ensure the drawing accuracy, which leads to poor drawing effect of CAD drawings.
[0003] Therefore, how to automatically generate CAD drawings is a technical issue that deserves attention. Summary of the invention
[0004] In order to solve the above technical problems, the present disclosure is proposed. The embodiments of the present disclosure provide a method, device, equipment and storage medium for generating a design drawing.
[0005] According to one aspect of an embodiment of the present disclosure, a method for generating a design drawing is provided, comprising:
[0006] Based on the inner wall line vector data of the target house, generating first characterization data of the outer wall line, wherein the inner wall line vector data includes second characterization data of the inner wall line and third characterization data of the wall attachment;
[0007] Based on the first characterization data, the second characterization data, and the third characterization data, determining the positional relationship between the wall attachment and the inner wall and the outer wall and scale data, wherein the scale data includes outer scale data and inner scale data;
[0008] Determine a display area of each data in the internal scale data, wherein the display areas of each data in the internal scale data do not overlap each other;
[0009] A design drawing of the target house is generated based on the first characterization data, the second characterization data, the positional relationship, the scale data, and the display area.
[0010] In some embodiments of the present disclosure, the generating first representation data of the exterior wall line based on the interior wall line vector data of the target house includes:
[0011] Determining at least one first polygon formed by the interior wall lines based on the second characterization data of the interior wall lines;
[0012] Expand at least one first polygon by a first distance to obtain at least one second polygon;
[0013] Retracting at least one second polygon by a second distance to obtain at least one third polygon, wherein the difference between the first distance and the second distance is a value representing the thickness of the exterior wall;
[0014] Based on at least one third polygon, first representation data of the exterior wall line is generated.
[0015] In some other embodiments of the present disclosure, generating the first representation data of the exterior wall line based on at least one third polygon includes:
[0016] In response to the number of the third polygon being one, optimizing the third polygon to obtain a fourth polygon formed by the exterior wall line, wherein the characterization data of the fourth polygon is the first characterization data of the exterior wall line;
[0017] In response to the number of the third polygons being more than two, sequentially performing a union and a convex hull process on at least one third polygon to obtain a fifth polygon;
[0018] The fifth polygon is optimized to obtain a sixth polygon formed by the outer wall line, and the characterization data of the sixth polygon is the first characterization data of the outer wall line.
[0019] In some other embodiments of the present disclosure, the third characterization data includes two endpoints of the line segment where the wall attachment is located;
[0020] The determining, based on the first characterization data, the second characterization data, and the third characterization data, a positional relationship between the wall attachment and the inner wall and the outer wall includes:
[0021] Based on the two endpoints, draw a line segment with a set length in a direction perpendicular to the inner wall line and / or the outer wall line;
[0022] Based on the intersection of the line segment and the inner wall line and / or the outer wall line, the positional relationship between the wall attachment and the inner wall or the outer wall is determined.
[0023] In some other embodiments of the present disclosure, determining scale data based on the first characterization data, the second characterization data, and the third characterization data includes:
[0024] Based on the positional relationship between each endpoint in the first characterization data, the second characterization data and the third characterization data and the center point of the target house, project in the direction of the closest distance to obtain the intersection point with the three-layer scale line, and generate external scale data; and
[0025] The internal scale data is generated based on the size information of the wall attachment in the third representation data and the size information of each room of the target house.
[0026] In some other embodiments of the present disclosure, the determining the display area of each data in the internal scale data includes:
[0027] Abstract each data in the inner scale data into a component respectively, and obtain at least two components;
[0028] The display area of each component is determined in sequence, wherein the display area of each component does not overlap with the occupied space area, and the occupied space area includes the space area occupied by the data of the determined display area.
[0029] In some other embodiments of the present disclosure, sequentially determining the display area of each component includes:
[0030] Creating an occupied space region, wherein the initial value of the occupied space region is empty;
[0031] Selecting a target component of a display area to be determined from the at least two components;
[0032] Determining an overlap state between an initial occupied area of the target component and the occupied space area;
[0033] In response to the overlap state indicating no overlap, determining an initial occupied area of the target component as a display area of the target component, and adding the initial occupied area to the occupied space area;
[0034] In response to the overlap state indicating overlap, adjusting the display area of the target component until it does not overlap with the occupied space area, and adding the adjusted display area of the target component to the occupied space area;
[0035] The operation of selecting a target component whose display area is to be determined from the at least two components is iterated until the at least two components have determined display areas.
[0036] According to another aspect of an embodiment of the present disclosure, there is provided a device for generating a design drawing, comprising:
[0037] A first generating module, configured to generate first characterization data of an exterior wall line based on interior wall line vector data of a target house, wherein the interior wall line vector data includes second characterization data of the interior wall line and third characterization data of a wall attachment;
[0038] A first determination module, configured to determine, based on the first characterization data, the second characterization data, and the third characterization data, a positional relationship between the wall attachment and the inner wall and the outer wall, and scale data, wherein the scale data includes outer scale data and inner scale data;
[0039] A second determination module is used to determine the display area of each data in the internal scale data, wherein the display areas of each data in the internal scale data do not overlap each other;
[0040] The second generating module is used to generate a design drawing of the target house based on the first characterization data, the second characterization data, the positional relationship, the scale data and the display area.
[0041] In some embodiments of the present disclosure, the first generation module includes:
[0042] A first determining submodule, configured to determine at least one first polygon formed by the interior wall lines based on second characterization data of the interior wall lines;
[0043] An expansion submodule, used to expand at least one first polygon by a first distance to obtain at least one second polygon;
[0044] A retraction submodule, used for retracting at least one second polygon by a second distance to obtain at least one third polygon, wherein the difference between the first distance and the second distance is a value representing the thickness of the exterior wall;
[0045] The first generating submodule is used to generate first representation data of the exterior wall line based on at least one third polygon.
[0046] In some other embodiments of the present disclosure, the first generation submodule includes:
[0047] A first optimization unit is used for optimizing the third polygon in response to the number of the third polygon being one, to obtain a fourth polygon formed by the outer wall line, wherein the characterization data of the fourth polygon is the first characterization data of the outer wall line;
[0048] a processing unit, configured to, in response to the number of the third polygons being more than two, sequentially perform a union process and a convex hull process on at least one third polygon to obtain a fifth polygon;
[0049] The second optimization unit is used to optimize the fifth polygon to obtain a sixth polygon formed by the exterior wall line, and the characterization data of the sixth polygon is the first characterization data of the exterior wall line.
[0050] In some other embodiments of the present disclosure, the third characterization data includes two endpoints of the line segment where the wall attachment is located;
[0051] The first determining module comprises:
[0052] A second generation submodule is used to make a line segment with a set length based on the two endpoints in a direction perpendicular to the inner wall line and / or the outer wall line;
[0053] The second determination submodule is used to determine the positional relationship between the wall attachment and the inner wall or the outer wall based on the intersection of the line segment and the inner wall line and / or the outer wall line.
[0054] In some other embodiments of the present disclosure, the first determining module includes:
[0055] A projection submodule is used to project in the direction of the shortest distance based on the positional relationship between each endpoint in the first characterization data, the second characterization data and the third characterization data and the center point of the target house, obtain the intersection points with the three-layer scale lines, and generate external scale data; and
[0056] The third generating submodule is used to generate the internal scale data based on the size information of the wall attachments in the third characterization data and the size information of each room of the target house.
[0057] In some other embodiments of the present disclosure, the second determining module includes:
[0058] An abstract submodule, used for abstracting each data in the inner scale data into a component respectively, and obtaining at least two components;
[0059] The third determination submodule is used to determine the display area of each component in turn, wherein the display area of each component does not overlap with the occupied space area, and the occupied space area includes the space area occupied by the data of the determined display area.
[0060] In some other embodiments of the present disclosure, the third determining submodule includes:
[0061] A creation unit, used to create an occupied space area, wherein the initial value of the occupied space area is empty;
[0062] A selection unit, configured to select a target component of a display area to be determined from the at least two components;
[0063] A first determining unit, configured to determine an overlapping state between an initial occupied area of the target component and the occupied space area;
[0064] a second determining unit, configured to determine, in response to the overlapping state indicating no overlap, an initial occupied area of the target component as a display area of the target component and add the initial occupied area to the occupied space area;
[0065] an adjusting unit, configured to adjust the display area of the target component until it does not overlap with the occupied space area in response to the overlap state indicating overlap, and add the adjusted display area of the target component to the occupied space area;
[0066] The iterative unit is used to iteratively execute the operation of selecting a target component whose display area is to be determined from the at least two components until the at least two components have determined the display area.
[0067] According to another aspect of the present disclosure, a computer-readable storage medium is provided, wherein the storage medium stores computer program instructions, and when the computer program instructions are executed, the above-mentioned method for generating a design drawing is implemented.
[0068] According to another aspect of the present disclosure, an electronic device is provided, the electronic device comprising:
[0069] a memory for storing a computer program product;
[0070] The processor is used to execute the computer program product stored in the memory, and when the computer program product is executed, the method for generating the design drawing is implemented.
[0071] According to another aspect of the present disclosure, a computer program product is provided, comprising computer program instructions, which, when executed by a processor, implement the above-mentioned method for generating a design drawing.
[0072] Based on the design drawing generation method, device, equipment and storage medium provided by the above-mentioned embodiments of the present disclosure, when generating a design drawing, first characterization data of the exterior wall line can be generated based on the interior wall line vector data of the target house, and the interior wall line vector data includes second characterization data of the interior wall line and third characterization data of the wall attachment; based on the first characterization data, the second characterization data and the third characterization data, the positional relationship between the wall attachment and the interior wall line and the exterior wall line and the scale data are determined; the display area of each data in the interior scale data is determined, wherein the display area of each data in the interior scale data does not overlap; based on the first characterization data, the second characterization data, the positional relationship, the scale data and the display area, the design drawing of the target house is generated. Therefore, the technical solution of the present disclosure can automatically generate a design drawing based on the interior wall line vector data of the target house, and the display of each data in the generated design drawing does not overlap, the display effect is good, and no manual participation is required, and the generation cost is low.
[0073] The technical solution of the present disclosure is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0074] The above and other purposes, features and advantages of the present disclosure will become more apparent by describing the embodiments of the present disclosure in more detail in conjunction with the accompanying drawings. The accompanying drawings are used to provide a further understanding of the embodiments of the present disclosure and constitute a part of the specification. Together with the embodiments of the present disclosure, they are used to explain the present disclosure and do not constitute a limitation of the present disclosure. In the drawings, the same reference numerals generally represent the same components or steps.
[0075] The present disclosure may be more clearly understood from the following detailed description with reference to the accompanying drawings, in which:
[0076] Figure 1 A schematic diagram of a flow chart of a method for generating a design drawing provided by an exemplary embodiment of the present disclosure;
[0077] Figure 2 A schematic diagram of a flow chart of determining exterior wall line data in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure;
[0078] Figure 3 The exterior wall line optimization effect of the design drawing provided by an exemplary embodiment of the present disclosure Figure 1 ;
[0079] Figure 4 The exterior wall line optimization effect of the design drawing provided by an exemplary embodiment of the present disclosure Figure 2 ;
[0080] Figure 5 A schematic diagram of a flow chart of determining the position of a wall attachment in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure;
[0081] Figure 6 A schematic diagram of a flow chart of determining a display area of ruler data in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure;
[0082] Figure 7 A schematic diagram of a flow chart of determining a display area of each component in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure;
[0083] Figure 8 A rendering of a design diagram provided for an exemplary embodiment of the present disclosure;
[0084] Fig. 9 An adjustment effect diagram of a continuous window provided by an exemplary embodiment of the present disclosure;
[0085] Fig.10 A schematic structural diagram of another embodiment of a device for generating a design drawing disclosed in the present invention;
[0086] Fig.11 A schematic structural diagram of another embodiment of a device for generating a design drawing disclosed in the present invention;
[0087] Fig.12 A structural diagram of an electronic device provided for an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION
[0088] Below, the exemplary embodiments according to the present disclosure will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present disclosure, rather than all the embodiments of the present disclosure, and it should be understood that the present disclosure is not limited to the exemplary embodiments described here.
[0089] It should be noted that the relative arrangement of components and steps, the numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present disclosure unless specifically stated otherwise.
[0090] Those skilled in the art can understand that the terms "first" and "second" in the embodiments of the present disclosure are only used to distinguish different steps, devices or modules, etc., and neither represent any specific technical meaning nor indicate the necessary logical order between them.
[0091] It should also be understood that in the embodiments of the present disclosure, “plurality” may refer to two or more than two, and “at least one” may refer to one, two, or more than two.
[0092] It should also be understood that any component, data or structure mentioned in the embodiments of the present disclosure can generally be understood as one or more, unless explicitly limited or otherwise indicated in the context.
[0093] In addition, the term "and / or" in the present disclosure is only a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in the present disclosure generally indicates that the associated objects before and after are in an "or" relationship.
[0094] It should also be understood that the description of the various embodiments in the present disclosure focuses on the differences between the various embodiments, and the same or similar aspects thereof can be referenced to each other, and for the sake of brevity, they will not be described one by one.
[0095] At the same time, it should be understood that for the convenience of description, the sizes of the various parts shown in the drawings are not drawn according to the actual proportional relationship.
[0096] The following description of at least one exemplary embodiment is merely illustrative in nature and is in no way intended to limit the present disclosure, its application, or uses.
[0097] Technologies, methods, and equipment known to ordinary technicians in the relevant art may not be discussed in detail, but where appropriate, the technologies, methods, and equipment should be considered as part of the specification.
[0098] It should be noted that like reference numerals and letters refer to similar items in the following figures, and therefore, once an item is defined in one figure, it need not be further discussed in subsequent figures.
[0099] The disclosed embodiments can be applied to electronic devices such as terminal devices, computer systems, servers, etc., which can operate with many other general or special computing system environments or configurations. Examples of well-known terminal devices, computing systems, environments and / or configurations suitable for use with electronic devices such as terminal devices, computer systems, servers, etc. include, but are not limited to: personal computer systems, server computer systems, thin clients, thick clients, handheld or laptop devices, microprocessor-based systems, set-top boxes, programmable consumer electronics, network personal computers, small computer systems, large computer systems, and distributed cloud computing technology environments including any of the above systems, etc.
[0100] Electronic devices such as terminal devices, computer systems, servers, etc. can be described in the general context of computer system executable instructions (such as program modules) executed by computer systems. Generally, program modules can include routines, programs, object programs, components, logic, data structures, etc., which perform specific tasks or implement specific abstract data types. Computer systems / servers can be implemented in a distributed cloud computing environment, where tasks are performed by remote processing devices linked through a communication network. In a distributed cloud computing environment, program modules can be located on local or remote computing system storage media including storage devices.
[0101] SUMMARY OF THE DISCLOSURE
[0102] The technical solution provided by the embodiment of the present disclosure is used to solve the problem of automatic generation of house design drawings, and can be applied to a variety of business fields, such as home decoration, architectural design, house transactions, etc. The design drawings generated by the technical solution of this embodiment can also be called computer-aided design drawings (CAD drawings). In related technologies, CAD drawings require manual measurement and professional software design and generation, which is cumbersome and time-consuming.
[0103] The technical solution disclosed in the present invention can automatically generate CAD drawings based on the inner wall line vector data without manual intervention, with high efficiency and accuracy.
[0104] Exemplary Methods
[0105] Figure 1 1 is a flow chart of an embodiment of a method for generating a design drawing of the present disclosure; the method for generating a design drawing can be applied to electronic devices (such as computer systems, servers), such as Figure 1 As shown, the method for generating the design drawing includes the following steps:
[0106] In step 101, first representation data of exterior wall lines are generated based on interior wall line vector data of a target house.
[0107] In the present disclosure, the inner wall line vector data includes the second characterization data of the inner wall line and the third characterization data of the wall attachment. Among them, the second characterization data of the inner wall line may include the starting point coordinates and the end point coordinates of each wall corresponding to the inner wall line and the line data of the inner wall line, and the line data of the inner wall line may be described by a sequence coordinate chain with uniform or uneven intervals. The wall attachment may be an object such as a window, door, weak current box, etc. on the wall. The third characterization data of the wall attachment may include information such as the height and width used to characterize the size of the wall attachment, as well as coordinate information used to characterize the position of the wall attachment.
[0108] In this embodiment, the polygon formed by the outer wall line can be obtained by expanding and contracting the inner wall line, and then the third characterization data of the outer wall line can be obtained. Figure 2 The illustrated embodiment will not be described in detail here.
[0109] The first characterization data of the exterior wall line may include the starting point coordinates and the end point coordinates of the exterior wall line corresponding to each wall and the line data of the exterior wall line. The line data of the exterior wall line may be described by a sequence coordinate chain with uniform or uneven intervals.
[0110] In step 102, based on the first characterization data, the second characterization data and the third characterization data, the positional relationship between the wall attachment and the inner wall and the outer wall and the scale data are determined.
[0111] In the present disclosure, a wall attachment, such as a window, may be located on an outer wall or an inner wall. The positional relationship between the wall attachment and the inner wall or the outer wall is used to indicate the position of the wall attachment on the wall. The position of the wall attachment on the outer wall or the inner wall may be determined by judging whether the wall attachment intersects with the outer wall line or the inner wall line.
[0112] In the present disclosure, the scale data may include external scale data and internal scale data. The external scale data is used to indicate the three-layer scale lines and dimension information marked on the outermost side of the CAD drawing, and is composed of dimension lines, extension lines (i.e., dimension boundaries), dimension text (i.e., dimension numbers), etc. The external scale data is usually located at the outermost side of the CAD drawing, with three dimension lines marked in the horizontal direction and the vertical direction, such as Figure 8As shown, the external scale data may include the total dimensions of the house in the horizontal direction, such as the total length and total width, as well as the axial dimensions of the house such as the span and depth, and the detailed dimensions of the wall sections of the house's exterior walls and door and window openings.
[0113] In specific implementation, based on the positional relationship between each endpoint in the first characterization data, the second characterization data, and the third characterization data and the center point of the target house, projection can be performed in the direction of the closest distance to obtain the intersection point with the three-layer ruler line and generate the external ruler data. For example, a point located at the upper left position of the center point of the target house can be projected to the left and upper sides respectively, and fall on the three-layer ruler lines on the left and upper sides. A point located at the lower right position of the center point of the target house can be projected to the right and lower sides respectively, and fall on the three-layer ruler lines on the right and lower sides. See Figure 8 Among them, the target house center point can be understood as the point at the center position of the target house.
[0114] Internal ruler data is used to indicate the annotation information marked inside the apartment area of the CAD drawing. It can be generated based on the size information of each wall attachment (such as the height and width of the window), the location information of the attachment (such as the height of the window from the ground), and the size information of each room of the target house (such as the width, length, and area of the master bedroom). See Figure 8 .
[0115] In this embodiment, the dimension information of the room can be determined based on the point data and line data of the second characterization data of the inner wall line, and the detailed dimensions of the door and window openings, etc. can be determined based on the third annotation information of the wall attachments; the dimension information such as the wall section of the outer wall of the house can be determined based on the first characterization data of the outer wall line. Therefore, the outer scale data and the inner scale data can be determined by combining the first characterization data, the second characterization data and the third characterization data.
[0116] In this embodiment, the specific implementation method of determining the position of the wall attachment according to the first characterization data, the second characterization data and the third characterization data can be found in Figure 5 The illustrated embodiment will not be described in detail here.
[0117] In step 103, the display area of each data in the inner scale data is determined, wherein the display areas of each data in the inner scale data do not overlap with each other.
[0118] In the present disclosure, each data in the internal scale data may include the size information of the wall attachments and the size information of each room, for example, the width (CK: 1007mm), height (CH: 1387mm), height from the ground (CX: 777mm) of window 1, the width (CK: 1307mm), height (CH: 1387mm), height from the ground (CX: 777mm) of window 2, etc. The display areas of the size information of different wall attachments or different rooms cannot overlap to avoid collision of size information.
[0119] In this embodiment, the specific implementation method of determining the display area of each data in the inner scale data can be found in Figure 6 The illustrated embodiment will not be described in detail here.
[0120] In step 104, a design drawing of the target house is generated based on the first characterization data, the second characterization data, the positional relationship, the scale data, and the display area.
[0121] In the present disclosure, the design drawing is a directly usable and editable CAD file, such as a Drawing Web Format (DWG) file and a Drawing Exchange Format (DXF) file.
[0122] In this embodiment, a design drawing can be obtained by drawing according to the first characterization data, the second characterization data, the position relationship, the scale data, and the display areas of the different scale data.
[0123] In the above steps 101 to 104, when generating a design drawing, the first characterization data of the exterior wall line can be generated based on the interior wall line vector data of the target house, and the interior wall line vector data includes the second characterization data of the interior wall line and the third characterization data of the wall attachment; based on the first characterization data, the second characterization data and the third characterization data, the positional relationship between the wall attachment and the interior wall line and the exterior wall line and the scale data are determined; the display area of each data in the interior scale data is determined, wherein the display area of each data in the interior scale data does not overlap; based on the first characterization data, the second characterization data, the positional relationship, the scale data and the display area, the design drawing of the target house is generated. Therefore, the technical solution disclosed in the present invention can automatically generate a design drawing based on the interior wall line vector data of the target house, and the display of each scale data in the generated design drawing does not overlap, the display effect is good, and no manual participation is required, and the generation cost is low.
[0124] In order to better illustrate the scheme for generating the design drawing of the present invention, another embodiment is used below for illustration.
[0125] Figure 2FIG. 1 is a flow chart of determining exterior wall line data in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure; this embodiment takes how to determine exterior wall line data as an example for exemplary description, such as Figure 2 As shown, the following steps are included:
[0126] In step 201, at least one first polygon formed by the interior wall lines is determined based on second characterization data of the interior wall lines.
[0127] In this embodiment, one or more first polygons may be obtained based on the second characterization data of the interior wall line. Multiple first polygons can represent multiple groups of continuous interior wall lines. For example, if there is a patio in the house, there is an independent first polygon inside the house, or if there is an independent space area indoors that is connected to other indoor areas only through windows, then the independent space area can also form a first polygon.
[0128] In this embodiment, in order to facilitate subsequent operations, each first polygon can be corrected to counterclockwise or clockwise, and the starting point and end point of the wall attachment can be adjusted. For example, the first polygon is adjusted to the clockwise direction, and the direction from the starting point to the end point of the window 1 on the first polygon does not conform to the clockwise direction, then the starting point and the end point can be swapped, that is, the starting point is used as the end point, and the end point is used as the starting point. In this implementation, by correcting the order of the first polygons to counterclockwise or clockwise, and adjusting the starting point and end point of the wall attachment accordingly, a group of orderly wall attachments can be obtained, which is helpful for subsequent CAD drawing.
[0129] In step 202, at least one first polygon is expanded by a first distance to obtain at least one second polygon.
[0130] In the present disclosure, the first distance is a distance that exceeds the value of the exterior wall thickness corresponding to the value in the CAD drawing. For example, the exterior wall thickness is a fixed value of 40 cm, which corresponds to 1 cm in the CAD drawing. The first distance can be a value exceeding 1 cm, such as 2 cm.
[0131] In some implementations, the operation of expanding the first polygon refers to expanding each side of a polygon outward by a fixed distance to form a new second polygon.
[0132] In step 203, at least one second polygon is retracted by a second distance to obtain at least one third polygon, and the difference between the first distance and the second distance is a value representing the thickness of the exterior wall.
[0133] In the present disclosure, the second distance is a value smaller than the first distance, and the difference between the second distance and the first distance is a value representing the thickness of the exterior wall. For example, the thickness of the exterior wall is a fixed value of 40 cm, which corresponds to 1 cm in the CAD drawing. The first distance can be a value greater than 1 cm, such as 2 cm. The second distance can be 1 cm.
[0134] In this embodiment, shrinking the second polygon means moving each side of the second polygon inward by a certain distance to form a new, smaller polygon. In this implementation, the buffer tool can be used to set a negative distance to achieve polygon shrinkage, and polygons with an area smaller than a specific value can be screened out.
[0135] In this embodiment, the expansion and contraction operations of step 202 and step 203 can be implemented through buffer operations, thereby generating at least one third polygon corresponding to at least one first polygon formed by the inner wall line, and the obtained third polygon realizes the flattening of the irregular corners of the first polygon, while only expanding the first polygon by 1 times the characterization value of the outer wall thickness cannot achieve the effect of flattening the irregular corners of the first polygon.
[0136] In step 204, first characterization data of the exterior wall line is generated based on at least one third polygon.
[0137] In specific implementation, the third polygons can be optimized according to the number of the third polygons to obtain the first characterization data of the outer wall line. In response to the number of the third polygons being one, the third polygons are optimized to obtain the fourth polygon formed by the outer wall line, and the characterization data of the fourth polygon is the first characterization data of the outer wall line; in response to the number of the third polygons being two or more, at least one third polygon is sequentially subjected to the union and convex hull processing to obtain the fifth polygon, and then the fifth polygon is optimized to obtain the sixth polygon formed by the outer wall line, and the characterization data of the sixth polygon is the first characterization data of the outer wall line.
[0138] In some embodiments, the obtained third polygon may be uneven, which makes the CAD drawing effect poor. However, by optimizing the third polygon to be smooth, a better effect can be achieved. For example, when there are some short and small line segments on the third polygon, the short and small line segments and the adjacent edge lines can be smoothed, such as Figure 3 As shown; or, when the angle of the adjacent edge lines on the third polygon is less than a certain threshold, the adjacent edge lines can be flattened into one edge line, such as Figure 4 In this implementation, by optimizing the third polygon, a better outer wall line polygon can be obtained, thereby obtaining more accurate first representation data.
[0139] In other embodiments, if there are more than two third polygons, the third polygon areas can be unioned and then the polygons after the union can be convex hull processed to obtain the fifth polygon. Some unevenness that may exist in the fifth polygon can be smoothed and optimized to achieve better results.
[0140] In this embodiment, the convex hull processing performed on the polygon refers to an operation of finding the smallest convex polygon that contains all vertices of the original polygon (the polygon after taking the union in the present disclosure).
[0141] In some implementations, after the polygon is optimized, the characterization data of the optimized polygon may be determined as the first characterization data of the exterior wall line.
[0142] Through the above steps 201 to 204, the characterization data of the exterior wall line is determined based on the second characterization data of the interior wall line, and by expanding and then contracting the polygons of the interior wall line and further optimizing the obtained exterior wall line polygons, the contour of the obtained exterior wall line can be made smooth, which is beneficial to improving the effect of the subsequent CAD drawing.
[0143] Figure 5 The present invention provides a schematic flow chart of determining the position of a wall attachment in a method for generating a design drawing according to an exemplary embodiment of the present invention; this embodiment uses how to determine the position of a wall attachment as an example for exemplary description, such as Figure 5 As shown, the following steps are included:
[0144] In step 501, based on two endpoints, a line segment with a length of a set value is drawn in a direction perpendicular to the inner wall line and / or the outer wall line.
[0145] In this embodiment, for each wall attachment, the corresponding third characterization data may include the coordinates of the two end points of the wall attachment, and two line segments with a set length may be drawn along the vertical direction of the wall line from the two end points to the outer wall line and the inner wall line, or the center points of the two end points of the wall attachment may be determined first, and then line segments with a set length may be drawn along the vertical direction of the wall line from the center point to the outer wall line and the inner wall line, respectively. The set value may be determined based on the thickness of the wall attachment, for example, the thickness of the window usually does not exceed the thickness of the wall, and the size of the set value cannot exceed the characterization value corresponding to the window thickness in the CAD drawing.
[0146] In step 502, based on the intersection of the line segment and the inner wall line and / or the outer wall line, the positional relationship between the wall attachment and the inner wall or the outer wall is determined.
[0147] In some embodiments, if the line segment intersects with the outer wall line but not the inner wall line, it can be determined that the wall attachment is located on the outer wall; if the line segment intersects with the inner wall line but not the outer wall line, it can be determined that the wall attachment is located on the inner wall.
[0148] In some optional implementations, it is further possible to determine whether adjacent windows are a continuous window based on the distance between the windows. For example, two windows located on two adjacent walls may be an L-shaped window. Fig. 9 , since the distance between the two windows numbered 91 and 92 is 0, it can be determined that the two windows are a complete continuous window, and the window can be adjusted to a continuous L-shaped window. In this implementation, the display effect and accuracy of the wall attachments can be further improved.
[0149] Through the above steps 501 to 502, the position of each wall attachment can be calculated and the wall attachments can be further grouped and integrated, which provides a good solution for improving the accuracy of the wall attachments in the subsequently generated CAD drawing.
[0150] Figure 6 The present invention provides a flowchart of determining a display area of ruler data in a method for generating a design drawing according to an exemplary embodiment of the present invention. The present embodiment provides an exemplary description by taking how to determine a display area of ruler data as an example.
[0151] In step 601, each data in the internal scale data is abstracted into a component to obtain at least two components.
[0152] In the present disclosure, each data in the internal ruler data can be abstracted into components according to different granularities. In some embodiments, it can be abstracted into components according to the granularity of the object. For example, the ruler data of each wall attachment is abstracted into a component, such as the width, height, and height from the ground of window 1 are abstracted as component 1; the width, height, and height from the ground of window 2 are abstracted as component 2, and the length, width, and area information of room 1 are abstracted as component 3, etc. In other embodiments, it can also be abstracted into a component according to a smaller granularity, such as a text or a legend. For example, the width of window 1 is abstracted as component 1, the height of window 1 is abstracted as component 2, and the height of window 1 from the ground is abstracted as component 3. The present disclosure does not limit the granularity of abstracting each data in the internal ruler data into components.
[0153] In step 602, the display area of each component is determined in sequence, wherein the display area of each component does not overlap with the occupied space area, and the occupied space area includes the space area occupied by the data of the determined display area.
[0154] In the present disclosure, determining the display area of each component in sequence can be understood as determining the display area of each component one by one, and the display area of each component does not overlap with the occupied space area.
[0155] In some embodiments, the method of determining the display area of each component can be seen in Figure 7 The illustrated embodiment will not be described in detail here.
[0156] Through the above steps 601 to 602, the display area of each component can be determined by abstracting each data in the internal scale data into a component. The display areas of each component do not collide with each other, which helps to improve the display effect of the CAD drawing.
[0157] Figure 7 A schematic diagram of a flow chart of determining the display area of each component in a method for generating a design drawing provided by an exemplary embodiment of the present disclosure; this embodiment takes how to determine the display area of each component as an example for exemplary description, such as Figure 7 As shown, the following steps are included:
[0158] In step 701, an occupied space area is created, and the initial value of the occupied space area is empty.
[0159] The occupied space area is used to indicate the space area occupied by each component of the determined display area, and its initial value is empty, that is, before the display area of any component is determined, the occupied space area is empty.
[0160] In step 702, a target component of a display area to be determined is selected from at least two components.
[0161] In some implementations, at least two components abstracted from the inner scale data may be added to a component list in advance, and the target component of the current display area to be determined may be selected by traversing the component list.
[0162] It can be understood that the components in the component list can be sorted in a spatial order. For example, each wall attachment can be added to the component list in a clockwise order on the wall. This allows the display area of each component to be determined in a certain order. For example, if window 1 is in front of window 2 in a clockwise direction, the display area of window 1 can be determined first, and then the display area of window 2 can be determined.
[0163] In step 703, the overlapping state between the initial occupied area of the target component and the occupied space area is determined.
[0164] In the present disclosure, the initial occupied area is the original occupied area generated when the internal scale data is abstracted to obtain the component. The initial occupied area of each component is usually related to the position of the wall attachment corresponding to the component. For example, the initial occupied area of the component corresponding to the scale data of window 1 is located below the position of window 1, and the initial occupied area of the component corresponding to the scale data of room 1 is located in the middle of room 1, etc.
[0165] The initial occupied area can be characterized according to information such as the area center point, width, height, etc. The occupied space area can be composed of multiple discontinuous occupied areas. For example, the occupied space area includes display area 1 of the component corresponding to the scale data of window 1 and display area 2 of the component corresponding to the scale data of window 2. The two display areas may be two isolated space areas, and the characterization information (area center point, width, height) of the two display areas can be recorded separately.
[0166] According to the characterization information of the initial occupied area and the characterization information of the occupied space area, it can be determined whether there is overlap between the two, and the overlapping area can be further determined.
[0167] Further, when the overlapping state indicates no overlap, step 704 may be executed; further, when the overlapping state indicates overlap, step 705 may be executed.
[0168] In step 704, in response to the overlap status indicating no overlap, the initial occupied area of the target component is determined as the display area of the target component, and the initial occupied area is added to the occupied space area.
[0169] The above step 702 is iteratively performed until all components have determined display areas, that is, all internal scale data have determined display areas.
[0170] In step 705 , in response to the overlap status indicating overlap, the display area of the target component is adjusted until it does not overlap with the occupied space area, and the initial occupied area is added to the occupied space area.
[0171] In some embodiments, when the initial occupied area of the target component overlaps with the occupied space area, multiple candidate components can be defined in sequence based on a fixed step size, and the occupied areas of all candidate components can be constituted into a large auxiliary occupied area. The difference between the auxiliary occupied area and the occupied area is determined to obtain an area where no overlap will occur, and the display area of the target component can be adjusted to the area where no overlap will occur.
[0172] In other embodiments, the target component may be moved from the initial occupied area to a direction opposite to the overlapping portion until it no longer overlaps with the occupied space area, thereby obtaining a display area of the target component.
[0173] After the display area of the target component is determined, the display area can be added to the occupied space area to obtain an updated occupied space area.
[0174] The above step 702 is iteratively performed until all components have determined display areas, that is, all inner scale data have determined display areas, and the display areas of all inner scale data will not collide.
[0175] In the above steps 701 to 705, by constructing the occupied space area and iteratively determining the display area of each component based on the occupied space area, it is possible to achieve anti-collision display of all internal scale data and improve the display effect of the CAD drawing.
[0176] Corresponding to the embodiments of the aforementioned method for generating a design drawing, the present disclosure also provides embodiments corresponding to a device for generating a design drawing.
[0177] Exemplary Devices
[0178] Fig.10 FIG. 1 is a schematic diagram of a structure of an embodiment of a device for generating a design drawing of the present disclosure, wherein the device is applied to an electronic device (such as a computer system or a server), such as Fig.10 As shown, the device comprises:
[0179] A first generating module 11 is used to generate first characterization data of the exterior wall line based on the interior wall line vector data of the target house, wherein the interior wall line vector data includes second characterization data of the interior wall line and third characterization data of the wall attachment;
[0180] A first determination module 12 is used to determine the positional relationship between the wall attachment and the inner wall and the outer wall and the scale data based on the first characterization data, the second characterization data and the third characterization data, wherein the scale data includes the outer scale data and the inner scale data;
[0181] A second determination module 13 is used to determine the display area of each data in the internal scale data, wherein the display areas of each data in the internal scale data do not overlap each other;
[0182] The second generating module 14 is used to generate a design drawing of the target house based on the first characterization data, the second characterization data, the position relationship, the scale data and the display area.
[0183] Fig.11 FIG. 1 is a schematic diagram of a structure of another embodiment of the device for generating a design drawing of the present disclosure, as shown in FIG. Fig.11 As shown, in Fig.10 Based on the illustrated embodiment, in one embodiment, the first generating module 11 includes:
[0184] A first determining submodule 111 is used to determine at least one first polygon formed by the interior wall lines based on the second representation data of the interior wall lines;
[0185] An expansion submodule 112, configured to expand at least one first polygon by a first distance to obtain at least one second polygon;
[0186] The indentation submodule 113 is used to indent the at least one second polygon by a second distance to obtain at least one third polygon, and the difference between the first distance and the second distance is a value representing the thickness of the external wall;
[0187] The first generating submodule 114 is used to generate first representation data of the exterior wall line based on at least one third polygon.
[0188] In one embodiment, the first generation submodule 114 includes:
[0189] The first optimization unit 1141 is used for optimizing the third polygon in response to the number of the third polygon being one, to obtain a fourth polygon formed by the exterior wall line, wherein the representation data of the fourth polygon is the first representation data of the exterior wall line;
[0190] A processing unit 1142 is configured to, in response to the number of the third polygons being more than two, sequentially perform a union process and a convex hull process on at least one third polygon to obtain a fifth polygon;
[0191] The second optimization unit 1143 is used to optimize the fifth polygon to obtain a sixth polygon formed by the exterior wall line, and the representation data of the sixth polygon is the first representation data of the exterior wall line.
[0192] In one embodiment, the third characterization data includes two endpoints of the line segment where the wall attachment is located;
[0193] The first determination module 12 includes:
[0194] The second generation submodule 121 is used to make a line segment with a set length based on two endpoints in a direction perpendicular to the inner wall line and / or the outer wall line;
[0195] The second determining submodule 122 is used to determine the positional relationship between the wall attachment and the inner wall or the outer wall based on the intersection of the line segment and the inner wall line and / or the outer wall line.
[0196] In one embodiment, the first determining module 12 includes:
[0197] The projection submodule 123 is used to project in the direction closest to the center point of the target house based on the positional relationship between each endpoint in the first characterization data, the second characterization data and the third characterization data, obtain the intersection point with the three-layer scale line, and generate external scale data; and
[0198] The third generating submodule 124 is used to generate internal scale data based on the size information of the wall attachments in the third representation data and the size information of each room of the target house.
[0199] In one embodiment, the second determining module 13 includes:
[0200] Abstraction submodule 131, used for abstracting each data in the inner scale data into a component respectively, and obtaining at least two components;
[0201] The third determination submodule 132 is used to determine the display area of each component in turn, wherein the display area of each component does not overlap with the occupied space area, and the occupied space area includes the space area occupied by the data of the determined display area.
[0202] In one embodiment, the third determining submodule 132 includes:
[0203] A creating unit 1321 is used to create an occupied space area, where the initial value of the occupied space area is empty;
[0204] A selection unit 1322, configured to select a target component of a display area to be determined from at least two components;
[0205] A first determining unit 1323 is used to determine an overlapping state between an initial occupied area and an occupied space area of a target component;
[0206] A second determining unit 1324 is configured to determine, in response to the overlap state indicating no overlap, an initial occupied area of the target component as a display area of the target component, and add the initial occupied area to the occupied space area;
[0207] An adjusting unit 1325, configured to adjust the display area of the target component until it does not overlap with the occupied space area in response to the overlap state indicating overlap, and add the adjusted display area of the target component to the occupied space area;
[0208] The iteration unit 1326 is used to iteratively perform the operation of selecting a target component whose display area is to be determined from at least two components until at least two components have determined the display area.
[0209] The modules and units in the device disclosed in the present invention can also be divided into finer granularity according to actual needs, and can be specifically set according to actual needs.
[0210] The device of the embodiment of the present disclosure can be used to implement the methods of the above-mentioned embodiments of the present disclosure. The two correspond to each other in specific implementation, and the specific implementations of related parts are referenced to each other, which will not be repeated here.
[0211] Exemplary electronic devices, computer program products, and computer-readable storage media
[0212] An embodiment of the present disclosure further provides an electronic device, comprising: a memory for storing a computer program; a processor for executing the computer program stored in the memory, and when the computer program is executed, the method for generating a design drawing of any of the above embodiments of the present disclosure is implemented.
[0213] Below, reference Fig.12 An electronic device according to an embodiment of the present disclosure is described, in which a device for implementing the method according to an embodiment of the present disclosure may be integrated. Fig.12 A structural diagram of an electronic device provided in an exemplary embodiment of the present disclosure, such as Fig.12 As shown, the electronic device includes one or more processors 121, one or more computer-readable storage media memory 122, and a computer program stored in the memory and executable on the processor. When executing the program in the memory 122, the above-mentioned design drawing generation method can be implemented.
[0214] Specifically, in practical applications, the electronic device may further include components such as an input device 123 and an output device 124, and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown). Those skilled in the art will appreciate that Fig.12 The structure of the electronic device shown in the figure does not constitute a limitation of the electronic device, and may include more or less components than shown in the figure, or certain components, or different component arrangements.
[0215] in:
[0216] The processor 121 can be a central processing unit (CPU) or other forms of processing units with the ability to generate design drawings and / or execute instructions. It performs various functions and processes data by running or executing software programs and / or modules stored in the memory 122, and calling data stored in the memory 122, thereby monitoring the electronic device as a whole.
[0217] The memory 122 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and / or cache memory (cache), etc. Non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on a computer-readable storage medium, and the processor 121 may run the program instructions to implement the above-mentioned method for generating the design drawings of the various embodiments of the present disclosure and / or other desired functions. Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.
[0218] The input device 123 may be used to receive input digital or character information, and to generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function controls.
[0219] The output device 124 can output various information to the outside, including the determined distance information, direction information, etc. The output device 124 can include, for example, a display, a speaker, a printer, a communication network and a remote output device connected thereto, and the like.
[0220] The electronic device may also include a power supply for supplying power to various components, which may be logically connected to the processor 121 through a power management system, so as to manage charging, discharging, power consumption and other functions through the power management system. The power supply may also include one or more DC or AC power supplies, recharging systems, power failure detection circuits, power converters or inverters, power status indicators and other arbitrary components.
[0221] Of course, to simplify, Fig.12 Only some of the components related to the present disclosure in the electronic device are shown, and components such as a bus, an input / output interface, etc. are omitted. In addition, according to specific application situations, the electronic device may further include any other appropriate components.
[0222] In addition to the above-mentioned methods and devices, an embodiment of the present disclosure may also be a computer program product, which includes computer program instructions, which, when executed by a processor, enable the processor to execute the steps in the method for generating design drawings according to various embodiments of the present disclosure described in the above-mentioned "Exemplary Method" section of this specification.
[0223] The computer program product may be written in any combination of one or more programming languages to write program code for performing the operations of the disclosed embodiments, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0224] In addition, an embodiment of the present disclosure may also be a computer-readable storage medium on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor executes the steps in the method for generating design drawings according to various embodiments of the present disclosure described in the above "Exemplary Method" section of this specification.
[0225] Computer readable storage media can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0226] The basic principles of the present disclosure are described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, effects, etc. mentioned in the present disclosure are only examples and not limitations, and it cannot be considered that these advantages, strengths, effects, etc. are required by each embodiment of the present disclosure. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, and are not limitations. The above details do not limit the present disclosure to the necessity of adopting the above specific details to be implemented.
[0227] Each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the system embodiment, since it basically corresponds to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0228] A person of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above method embodiment; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk, etc., various media that can store program codes.
[0229] The method and apparatus of the present disclosure may be implemented in many ways. For example, the method and apparatus of the present disclosure may be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above order of steps for the method is for illustration only, and the steps of the method of the present disclosure are not limited to the order specifically described above, unless otherwise specifically stated. In addition, in some embodiments, the present disclosure may also be implemented as a program recorded in a recording medium, which includes machine-readable instructions for implementing the method according to the present disclosure. Therefore, the present disclosure also covers a recording medium storing a program for executing the method according to the present disclosure.
[0230] The description of the present disclosure is given for the purpose of illustration and description, and is not intended to be exhaustive or to limit the present disclosure to the disclosed form. Many modifications and variations will be apparent to those of ordinary skill in the art. The embodiments are selected and described in order to better illustrate the principles and practical applications of the present disclosure, and to enable those of ordinary skill in the art to understand the present disclosure and thereby design various embodiments with various modifications suitable for specific uses.
Claims
1. A method for generating a design drawing, characterized in that: include: Based on the inner wall line vector data of the target house, generating first characterization data of the outer wall line, wherein the inner wall line vector data includes second characterization data of the inner wall line and third characterization data of the wall attachment; Based on the first characterization data, the second characterization data, and the third characterization data, determining the positional relationship between the wall attachment and the inner wall and the outer wall and scale data, wherein the scale data includes outer scale data and inner scale data; Determine a display area of each data in the internal scale data, wherein the display areas of each data in the internal scale data do not overlap each other; A design drawing of the target house is generated based on the first characterization data, the second characterization data, the positional relationship, the scale data, and the display area.
2. The method according to claim 1, characterized in that The step of generating first representation data of exterior wall lines based on the interior wall line vector data of the target house includes: Determining at least one first polygon formed by the interior wall lines based on the second characterization data of the interior wall lines; Expand at least one first polygon by a first distance to obtain at least one second polygon; Retracting at least one second polygon by a second distance to obtain at least one third polygon, wherein the difference between the first distance and the second distance is a value representing the thickness of the exterior wall; Based on at least one third polygon, first representation data of the exterior wall line is generated.
3. The method according to claim 2, characterized in that The step of generating first representation data of the exterior wall line based on at least one third polygon comprises: In response to the number of the third polygon being one, optimizing the third polygon to obtain a fourth polygon formed by the exterior wall line, wherein the characterization data of the fourth polygon is the first characterization data of the exterior wall line; In response to the number of the third polygons being more than two, sequentially performing a union and a convex hull process on at least one third polygon to obtain a fifth polygon; The fifth polygon is optimized to obtain a sixth polygon formed by the outer wall line, and the characterization data of the sixth polygon is the first characterization data of the outer wall line.
4. The method according to any one of claims 1 to 3, characterized in that: The third characterization data includes two endpoints of the line segment where the wall attachment is located; The determining, based on the first characterization data, the second characterization data, and the third characterization data, a positional relationship between the wall attachment and the inner wall and the outer wall includes: Based on the two endpoints, draw a line segment with a set length in a direction perpendicular to the inner wall line and / or the outer wall line; Based on the intersection of the line segment and the inner wall line and / or the outer wall line, the positional relationship between the wall attachment and the inner wall or the outer wall is determined.
5. The method according to any one of claims 1 to 4, characterized in that: Determining scale data based on the first characterization data, the second characterization data, and the third characterization data includes: Based on the positional relationship between each endpoint in the first characterization data, the second characterization data and the third characterization data and the center point of the target house, project in the direction of the closest distance to obtain the intersection point with the three-layer scale line, and generate external scale data; and The internal scale data is generated based on the size information of the wall attachment in the third representation data and the size information of each room of the target house.
6. The method according to any one of claims 1 to 5, characterized in that: The step of determining a display area of each data in the inner scale data comprises: Abstract each data in the inner scale data into a component respectively, and obtain at least two components; The display area of each component is determined in sequence, wherein the display area of each component does not overlap with the occupied space area, and the occupied space area includes the space area occupied by the data of the determined display area.
7. The method according to claim 6, characterized in that The step of sequentially determining the display area of each component includes: Creating an occupied space region, wherein the initial value of the occupied space region is empty; Selecting a target component of a display area to be determined from the at least two components; Determining an overlap state between an initial occupied area of the target component and the occupied space area; In response to the overlap state indicating no overlap, determining an initial occupied area of the target component as a display area of the target component, and adding the initial occupied area to the occupied space area; In response to the overlap state indicating overlap, adjusting the display area of the target component until it does not overlap with the occupied space area, and adding the adjusted display area of the target component to the occupied space area; The operation of selecting a target component whose display area is to be determined from the at least two components is iterated until the at least two components have determined their display areas.
8. A device for generating a design drawing, characterized in that: include: A first generating module, configured to generate first characterization data of an exterior wall line based on interior wall line vector data of a target house, wherein the interior wall line vector data includes second characterization data of the interior wall line and third characterization data of a wall attachment; A first determination module, configured to determine, based on the first characterization data, the second characterization data, and the third characterization data, a positional relationship between the wall attachment and the inner wall and the outer wall, and scale data, wherein the scale data includes outer scale data and inner scale data; A second determination module is used to determine the display area of each data in the internal scale data, wherein the display areas of each data in the internal scale data do not overlap each other; The second generating module is used to generate a design drawing of the target house based on the first characterization data, the second characterization data, the positional relationship, the scale data and the display area.
9. A computer-readable storage medium, wherein the storage medium stores computer program instructions, and when the computer program instructions are executed, the method according to any one of claims 1 to 7 is implemented.
10. An electronic device, comprising: a memory for storing a computer program product; A processor is used to execute the computer program product stored in the memory, and when the computer program product is executed, it implements the method described in any one of claims 1 to 7.
Citation Information
Patent Citations
House type drawing method based on room splicing
CN107480333A
Room wall drawing method and device
CN110782505A
House type drawing method and system based on HTML5
CN111008414A
Proportional scale identification method and three-dimensional model establishment system based on facsimile
CN113742810A
Broken line data processing method and device, equipment and storage medium
CN115828398A