A method and device for realizing closure of a female-male corner, electronic equipment and storage medium
By calculating the data structure of the inside and outside corners and performing oblique modeling in the wall design, an extension body is generated to achieve the closure of the inside and outside corners, which solves the problem of missing inside and outside corners, simplifies the calculation and makes it easier to handle corner lines and light strips.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HANGZHOU QUNHE INFORMATION TECHNOLOGIES CO LTD
- Filing Date
- 2024-10-24
- Publication Date
- 2026-07-03
Smart Images

Figure CN119442408B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of wall design technology, specifically relating to a method, device, electronic device, and storage medium for achieving closed corners. Background Technology
[0002] Currently, wall-based finished surface design, which simply involves raising the finished surface, cannot create a finished surface at the inside and outside corners. The existing data structure generally needs to include point, edge, and region information, with the region containing its raised height. The data structure expresses the region's geometric data and raised height, based on which 3D modeling is performed to generate surfaces, and then the corresponding tiles are generated based on these surfaces. From the modeling method, it can be seen that users create the finished surface using planar modeling tools. Since each planar modeling tool is an independent protrusion model, without any connection to the planar modeling on the other side, the technical problem of missing inside and outside corners arises.
[0003] Existing methods for generating inside and outside corners are based on modifying the topology to generate new edges and faces. For example, patent application CN117708944A discloses a method, apparatus, electronic device, and storage medium for generating inside and outside corners. The specific implementation involves: determining the area to be processed (inside and outside corners) in the floor plan data; selecting a target line style from multiple pre-configured inside and outside corner line styles; each of the multiple inside and outside corner line styles includes a line outline and the position information of a line reference point, and the line outlines are different in different inside and outside corner line styles; based on the position information of the line reference point in the target line style, determining a floor plan data reference point in the inside and outside corner area that matches the line reference point; and adding inside and outside corner lines with the same line outline as the target line style in the inside and outside corner area based on the floor plan data reference point. This method generally requires additional support for generating new edges and faces, as well as for corner lines or light strips and tiling. It also requires consideration of more boundary conditions and whether special processing is needed. Summary of the Invention
[0004] In view of the above, the object of the present invention is to provide a method, apparatus, electronic device and storage medium for realizing the closure of internal and external corners, so as to realize the generation and closure of internal and external corners.
[0005] To achieve the above-mentioned objective, an embodiment provides a method for closing internal and external corners, comprising the following steps:
[0006] The data structure of each plane shape at the corner is calculated based on the height of the plane shape on both sides of the corner and the angle of the corner. This data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the region to which it belongs.
[0007] Based on the data structure, oblique modeling is performed on each side of the planar shape to generate an extension body. The extension body forms the internal and external corners of the planar shape and achieves corner closure.
[0008] In one embodiment, the method further includes: at the location where a yin-yang corner needs to be generated, checking whether the planar shapes on both sides of the yin-yang corner meet the yin-yang corner conditions, that is, determining whether the longitudinal division of the shape area is consistent, and if the longitudinal division is consistent, it is considered that a yin-yang corner can be generated.
[0009] In one embodiment, the method further includes: when performing oblique modeling of each side planar shape according to the data structure, the corner lines on the planar shape will naturally extend; specifically, the curves bound to the respective corner lines of the extension bodies on the left and right sides of the internal and external corners are identified as lofting paths; these two lofting paths on both sides are regarded as a whole lofting path; based on this whole lofting path, corner lines with internal and external corner closure effects are generated by lofting.
[0010] In one embodiment, the method further includes: when performing oblique modeling of each side planar shape according to the data structure, the light strip on the planar shape will naturally extend; specifically, the curves bound to the respective light strips of the extension bodies on the left and right sides of the internal and external corners are identified as lofting paths; these two lofting paths on both sides are regarded as a whole lofting path; and based on this whole lofting path, a light strip with a closing effect of internal and external corners is generated by lofting.
[0011] To achieve the above-mentioned objective, the embodiment also provides a device for closing internal and external corners, comprising:
[0012] The data generation module is used to calculate the data structure of each side of the plane shape at the corner based on the height of the two sides of the plane shape and the angle of the corner. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the area to which it belongs.
[0013] The internal and external corner closure generation module is used to perform oblique modeling of each side of the planar shape based on the data structure to generate an extension body. The extension body forms the internal and external corners of the planar shape and realizes the closure of the internal and external corners.
[0014] To achieve the above-mentioned objectives, the embodiments also provide a computing device, including a memory and one or more processors, wherein the memory stores executable code, and when the one or more processors execute the executable code, they are used to implement the above-mentioned method for achieving the closure of internal and external corners.
[0015] To achieve the above-mentioned objectives, the embodiments also provide a computer-readable storage medium storing a program thereon, which, when executed by a processor, implements the above-mentioned method for achieving the closure of internal and external corners.
[0016] To achieve the above-mentioned objectives, the embodiment also provides a computer product comprising a computer program, characterized in that, when the computer program is executed by a processor, it implements the above-mentioned method for achieving the closure of internal and external corners.
[0017] Compared with the prior art, the beneficial effects of the present invention include at least the following:
[0018] When closing internal and external corners, the data structure of each side of the planar shape at the corner is calculated based on the height of the planar shapes on both sides and the angle of the corner. This data structure includes the elevation height, horizontal offset, and region ID of the points on the planar shape. Based on the data structure, each side of the planar shape is obliquely modeled to generate an extension body. The extension body forms the internal and external corners of the planar shape and achieves corner closure. This oblique modeling method does not change the topology; it only changes the position and length of points, edges, and faces. This makes subsequent related support features such as tiling, corner lines, and light strips naturally supported or relatively easy to implement. Furthermore, boundary condition judgment increases the computational complexity of the program. This invention does not need to consider too many boundary conditions, thereby reducing computational consumption. Attached Figure Description
[0019] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1 This is a flowchart of the method for achieving corner closure provided in the embodiment;
[0021] Figure 2 This is a schematic diagram of an existing planar protrusion provided in the embodiment;
[0022] Figure 3 This is the point correspondence relationship after stretching the planar protrusions provided in the embodiment;
[0023] Figure 4 This is a schematic diagram of the planar protrusion modeling provided in the embodiment;
[0024] Figure 5 This is a schematic diagram of the device for achieving corner closure provided in the embodiment. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and do not limit the scope of protection of this invention.
[0026] like Figure 2 As shown, the data structure for expressing protruding shapes in existing wall designs generally includes point, edge, and region information. The region contains the region's elevation height. The data structure expresses the region's geometric data and elevation height, based on which 3D modeling is performed to generate surfaces. Then, based on these surfaces, the corresponding tiles are generated. For example... Figure 3 As shown in the modeling method, when users create a finished surface using planar modeling tools, the problem of missing inner and outer corners arises. This is because each planar modeling tool creates an independent protrusion model, which has no connection with the planar model on the other side.
[0027] To address this technical problem, this invention provides a method for achieving closed internal and external corners. The core idea is to change the way planar protrusions are modeled, from simple vertical protrusions to allowing for oblique protrusions, such as... Figure 4 As shown, the modeling of the midpoint of the region is still done by raising the protrusion, only the modeling method of the edge points is changed to oblique modeling. This allows the closed internal and external corners to be formed directly after modeling.
[0028] Based on the above core ideas, such as Figure 1 As shown in the embodiment, a method for achieving closed internal and external corners includes the following steps:
[0029] S1 calculates the data structure of each side plane shape at the inside and outside corner based on the height of the two sides of the plane shape and the angle of the inside and outside corner. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the region to which it belongs.
[0030] Based on the oblique protrusion modeling proposed in this invention, firstly, when obtaining the corresponding point after the protrusion is stretched from a point on the planar shape, in addition to the heightening distance from the region, a certain horizontal offset is also required. Secondly, for a single point on the planar shape, the stretched protrusion can result in multiple points, which can belong to different regions, such as... Figure 3 As shown, Figure 3 After stretching point A0, two corresponding points, A1 and A2, are obtained, belonging to two different regions. Therefore, a region ID is needed to accurately represent the result of stretching all corresponding points after the original single-point protrusion. Thus, when modeling oblique protrusions, the required data structure is redefined to include the elevation height, horizontal offset, and region ID of the point on the planar shape. This data structure clarifies how to perform oblique modeling subsequently.
[0031] In this embodiment, the calculation of generating internal and external angles is triggered by user interaction. Afterward, the planar shapes that are adjacent to each other and constitute internal and external angles are traversed sequentially. At the point where an internal or external angle needs to be generated, it is checked whether the planar shapes on both sides of the angle meet the conditions for generating an internal or external angle. That is, it is determined whether the vertical division of the shape area is consistent. If the vertical division is consistent, it is considered that an internal or external angle can be generated. The outlines of the planar shapes on both sides of the angle are checked. If the vertical distribution of these outlines is consistent, so that the areas on both sides of the angle can correspond one-to-one, then it is considered that an internal or external angle can be generated.
[0032] Specifically, user interaction triggers the generation of internal and external corners. When internal and external corners are generated, the horizontal offset of each side of the plane at the internal and external corner and its corresponding region ID are calculated based on the height of the two planes on both sides of the internal and external corner and the angle of the internal and external corner. This data is then combined with the height of the raised points on the planes to form a new data structure.
[0033] S2, based on the data structure, performs oblique modeling of each side of the planar shape to generate an extension body, the extension body forms the inside and outside corners of the planar shape and achieves the closure of the inside and outside corners.
[0034] In this embodiment, based on the data structure, oblique modeling is performed on each side of the planar shape to generate an extension that forms the internal and external corners of the planar shape and achieves corner closure. This modeling method does not alter the topological structure. Therefore, subsequent related attachments such as corner trims, light strips, and tiling are relatively easy to implement.
[0035] For the corner lines of inside and outside corners, the corner lines are bound to the modeled curve. Because the topology of the curve itself remains unchanged during modeling and stretching, only its length changes, the corner lines can naturally reach the required length for inside and outside corners, which is the curve generated by the new modeling method. However, simply increasing the length is not enough. The inside and outside corners of the corner lines also need to be processed to generate the shape of the inside and outside corners.
[0036] Specifically, during oblique modeling, the corner lines on the planar shape will naturally extend. The curves bound to the corner lines of the extended bodies on both sides of the internal and external corners are identified as loft paths. These two loft paths on both sides are regarded as a whole loft path. Based on this whole loft path, corner lines with the closing effect of internal and external corners are generated by lofting.
[0037] For LED strips located at inside and outside corners, a recessed LED strip is placed on the planar model. Without considering the inside and outside corners, the recessed LED strip will alter the planar modeling and the generation of the LED strip model. However, considering the inside and outside corners, the curves modeled after the inside and outside corners are directly used to construct the LED strip. For example, if the curve at the outside corner is longer than the original curve, but the topology remains unchanged, the planar modeling changes and LED strip modeling caused by the recessed LED strip can still be used based on the changed length.
[0038] Specifically, when performing oblique modeling of each side planar shape based on the data structure, the light strips on the planar shape will naturally extend. Specifically, the curves bound to the light strips of the extended bodies on the left and right sides of the internal and external corners are identified as lofting paths. These two lofting paths on both sides are regarded as a whole lofting path. Based on this whole lofting path, a light strip with the effect of closing the internal and external corners is generated by lofting.
[0039] In the above method, based on the new data structure and corresponding oblique modeling method, the topological relationships of the modeled result remain unchanged. That is, the geometric elements such as points, edges, and regions are not added or removed, and their interrelationships remain unchanged. Only the length of the edges and the area of the regions change. These changes do not significantly affect corner lines, light strips, tiling, etc., making these elements relatively easy to process.
[0040] like Figure 5 As shown, the embodiment also provides a device 50 for achieving corner closure, including: a data generation module 51 and a corner closure generation module 52. The data generation module 51 is used to calculate the data structure of each side plane shape at the corner based on the height of the two sides of the corner and the corner angle. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the area ID. The corner closure generation module 52 is used to perform oblique modeling on each side plane shape according to the data structure to generate an extension body. The extension body forms the corner of the plane shape and achieves corner closure.
[0041] It should be noted that the device for achieving corner closure provided in the above embodiments should be illustrated using the above-described functional module division. The functions can be assigned to different functional modules as needed, i.e., the internal structure of the terminal or server can be divided into different functional modules to complete all or part of the functions described above. Furthermore, the device for achieving corner closure and the method for achieving corner closure provided in the above embodiments belong to the same concept; the specific implementation process is detailed in the method embodiment for achieving corner closure, and will not be repeated here.
[0042] Based on the same inventive concept, the embodiment also provides a computing device, including a memory and one or more processors. The memory stores executable code, and when the one or more processors execute the executable code, it is used to implement the above-mentioned method for achieving the closure of internal and external corners, specifically including the following steps:
[0043] S1, calculate the data structure of each side of the plane shape at the corner based on the height of the two sides of the plane shape and the angle of the corner. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the area to which it belongs.
[0044] S2, based on the data structure, performs oblique modeling of each side of the planar shape to generate an extension body, the extension body forms the inside and outside corners of the planar shape and achieves the closure of the inside and outside corners.
[0045] The computing device provided in this embodiment, at the hardware level, includes not only a processor and memory, but also other hardware required for business operations, such as an internal bus, network interface, and memory. The memory is non-volatile memory. The processor reads the corresponding computer program from the non-volatile memory into memory and then runs it to implement the method for achieving corner closure described in S1-S2 above. Of course, besides software implementation, this invention does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. That is to say, the execution entity of the following processing flow is not limited to individual logic units, but can also be hardware or logic devices.
[0046] Based on the same inventive concept, the embodiments also provide a computer-readable storage medium storing a program thereon, which, when executed by a processor, implements the above-described method for achieving the closure of internal and external corners, specifically including the following steps:
[0047] S1, calculate the data structure of each side of the plane shape at the corner based on the height of the two sides of the plane shape and the angle of the corner. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the area to which it belongs.
[0048] S3, based on the data structure, performs oblique modeling of each side of the planar shape to generate an extension body, the extension body forms the inside and outside corners of the planar shape and achieves the closure of the inside and outside corners.
[0049] In this embodiment, computer-readable media includes both permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0050] The specific embodiments described above illustrate the technical solution and beneficial effects of the present invention in detail. It should be understood that the above description is only the most preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, additions, and equivalent substitutions made within the scope of the principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method of achieving closure of a rabbet, characterized in that, Includes the following steps: The data structure of each plane shape at the corner is calculated based on the height of the plane shape on both sides of the corner and the angle of the corner. This data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the region to which it belongs. Based on the data structure, oblique modeling is performed on each side of the planar shape to generate an extension body. The extension body forms the inside and outside corners of the planar shape and achieves corner closure. When oblique modeling is performed on each side of the planar shape according to the data structure, the corner lines and / or light strips on the planar shape will naturally extend. Specifically, the curves bound to the corner lines and / or light strips of the extension bodies on the left and right sides of the inside and outside corners are identified as lofting paths. These two lofting paths on both sides are regarded as a whole lofting path. Based on this whole lofting path, corner lines and / or light strips with inside and outside corner closure effect are generated by lofting.
2. The method of achieving closure of a rabbet according to claim 1, wherein, Also includes: At the location where a corner needs to be generated, check whether the planar shapes on both sides of the corner meet the conditions for a corner, that is, determine whether the vertical division of the shape area is consistent. If the vertical division is consistent, it is considered that a corner can be generated.
3. The method of achieving closure of a rabbet according to claim 2, wherein, Determine whether the vertical division of the shape area is consistent. If the vertical division is consistent, it is considered that the internal and external corners can be generated. This includes checking the outline of the planar shape area on both sides of the internal and external corners. If the distribution of these area outlines in the vertical direction is consistent, so that the areas on both sides of the internal and external corners can correspond one by one, then it is considered that the internal and external corners can be generated.
4. A device for achieving closure of a rabbet, characterized in that include: The data generation module is used to calculate the data structure of each side of the plane shape at the corner based on the height of the two sides of the plane shape and the angle of the corner. The data structure includes the elevation height of the point on the plane shape, the horizontal offset, and the ID of the area to which it belongs. The internal and external corner closure generation module is used to perform oblique modeling of each side of the planar shape according to the data structure to generate extended bodies. The extended bodies form the internal and external corners of the planar shape and achieve internal and external corner closure. Specifically, when performing oblique modeling of each side of the planar shape according to the data structure, the corner lines and / or light strips on the planar shape will naturally extend. Specifically, the curves bound to the respective corner lines and / or light strips of the extended bodies on the left and right sides of the internal and external corners are identified as lofting paths. These two lofting paths on both sides are regarded as a whole lofting path. Based on this whole lofting path, corner lines and / or light strips with internal and external corner closure effect are generated by lofting.
5. A computing device comprising a memory and one or more processors, wherein the memory stores executable code, characterized in that, When the one or more processors execute the executable code, they are used to implement the method for achieving the closure of internal and external corners as described in any one of claims 1-3.
6. A computer readable storage medium characterized by, It stores a program that, when executed by a processor, implements the method for achieving the closure of internal and external corners as described in any one of claims 1-3.
7. A computer product comprising a computer program, characterized in that When the computer program is executed by the processor, it implements the method for achieving the closure of internal and external corners as described in any one of claims 1-3.