Interactive arc wall updating method and device and electronic equipment

By identifying the splicing points between arc wall objects and straight wall objects and updating the target parameter variables, the problem of inconvenient design of arc walls in the existing technology is solved, and flexible editing and efficient design of arc walls are realized.

CN119691858AActive Publication Date: 2025-03-25BEIJING CHENGSHI WANGLIN INFORMATION TECH CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202411747739.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-29
Publication Date
2025-03-25
Estimated Expiration
2044-11-29

AI Technical Summary

Technical Problem

Existing architectural design software is difficult to effectively support the drawing and interactive editing of curved walls, limiting designers' creativity and work efficiency.

Method used

By identifying the splicing points of the target wall object with the straight wall object on the starting and ending side, drawing the arc wall object, and updating the target parameter variables, including the start point, end point, arc center point, center and radius, in response to user interaction, to achieve movement and morphological changes of the arc wall.

Benefits of technology

It improves the operation flexibility and accuracy of curved walls, enhances the user's design tool capabilities, and significantly improves design efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119691858A_ABST
    Figure CN119691858A_ABST
Patent Text Reader

Abstract

The invention provides an interactive arc wall updating method and device and electronic equipment, and the method comprises the steps: drawing a target wall object which is an arc wall object according to a splicing point corresponding to a target wall object and straight wall objects at a starting point side and an end point side; in response to an interaction operation for the target wall body object, target parameter variables associated with the target wall body object are updated, the interaction operation is a wall body moving operation or a wall body form changing operation, and the target parameter variables at least comprise the following parameters: a starting point, an end point, an arc center point, a circle center and a radius; and according to the updated target parameter variable, performing arc wall information updating on the target wall object to determine a new arc wall object after movement or a new arc wall object with a changed form. The arc-shaped wall can be moved or the form of the arc-shaped wall can be adjusted based on the event interaction mechanism, so that a user can visually move and adjust the arc-shaped wall, and the operation flexibility of the arc-shaped wall in building design software is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of decoration design, and in particular to a method, device and electronic equipment for updating interactive curved walls. Background Art

[0002] Drawing wall structures is a common task in fields such as computer-aided design and building information modeling. In existing architectural design software, wall drawing is usually limited to straight walls and lacks flexible support for curved walls. Even if the curved wall drawing function is supported, there is a lack of intuitive interactive editing capabilities for curved walls, which limits the creativity and work efficiency of architects and affects the design effect of houses. Therefore, curved wall design has become a problem to be solved in house design scenarios. Summary of the invention

[0003] In view of the above problems, the embodiments of the present application provide an interactive curved wall updating method, device and electronic device that overcome the above problems or at least partially solve the above problems.

[0004] In a first aspect, an embodiment of the present application provides an interactive curved wall updating method, comprising:

[0005] Draw the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, where the target wall object is an arc wall object;

[0006] In response to an interactive operation on the target wall object, updating a target parameter variable associated with the target wall object, wherein the interactive operation is a wall moving operation or a wall shape changing operation, and the target parameter variable includes at least the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius;

[0007] According to the updated target parameter variable, the arc wall information of the target wall object is updated to determine a new arc wall object after the move or a new arc wall object with a changed shape.

[0008] In a second aspect, an embodiment of the present application provides an interactive curved wall updating device, comprising:

[0009] A drawing module, used for drawing the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, wherein the target wall object is an arc wall object;

[0010] A first updating module is configured to update a target parameter variable associated with the target wall object in response to an interactive operation on the target wall object, wherein the interactive operation is a wall moving operation or a wall shape changing operation, and the target parameter variable includes at least the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius;

[0011] The second updating module is used to update the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the movement or a new arc wall object with a changed shape.

[0012] In a third aspect, an embodiment of the present application provides an electronic device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the interactive curved wall updating method as described in the first aspect above.

[0013] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the interactive curved wall updating method described in the first aspect above are implemented.

[0014] The technical solution of the embodiment of the present application, after receiving an interactive operation on a target wall object, updates the target parameter variable associated with the target wall object in response to the interactive operation of moving the wall or changing the wall shape, and updates the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the move or a new arc wall object with a changed shape. The arc wall can be moved or the shape of the arc wall can be adjusted based on an event interaction mechanism, so that the user can intuitively move and adjust the arc wall, thereby improving the operational flexibility and accuracy of the arc wall in the architectural design software, providing users with more powerful tools, and the real-time interaction and editing functions greatly improve the design efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] Figure 1 A schematic diagram showing an interactive curved wall updating method provided in an embodiment of the present application;

[0016] Figure 2 A schematic diagram showing the splicing of a single side of a target wall object with multiple straight wall objects provided by an embodiment of the present application;

[0017] Figure 3 A schematic diagram showing the adsorption of an arc wall object and a straight wall object provided in an embodiment of the present application;

[0018] Figure 4 A schematic diagram showing the calculation arc center point provided by an embodiment of the present application;

[0019] Figure 5 A schematic diagram showing determination of a new arc center point provided in an embodiment of the present application;

[0020] Figure 6 A schematic diagram showing a change in the arc direction from the starting point to the end point of the arc wall object provided by an embodiment of the present application;

[0021] Figure 7 A schematic diagram showing left-right classification of walls based on vectors provided in an embodiment of the present application;

[0022] Figure 8 A schematic diagram showing the determination of the joint point of the arc wall object and the straight wall object provided by an embodiment of the present application;

[0023] Fig. 9 A schematic diagram showing an interactive curved wall updating device provided in an embodiment of the present application;

[0024] Fig.10 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0025] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0026] It should be understood that the "one embodiment" or "an embodiment" mentioned throughout the specification means that the specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. The multiple in the embodiments of the present application can include two and more than two.

[0027] In the various embodiments of the present application, it should be understood that the size of the serial numbers of the following processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0028] The present application embodiment provides an interactive arc wall updating method, such as Figure 1 As shown, the method includes:

[0029] Step 101: Draw a target wall object according to the corresponding splicing points of the target wall object and the straight wall objects on the starting point side and the end point side, where the target wall object is an arc wall object.

[0030] The embodiment of the present application is a scene in which an arc wall object (target wall object) is spliced ​​with adjacent wall objects (straight wall objects) on the end side and the start side. The arc wall object is an arc-shaped wall structure, and the straight wall object is a straight wall structure. In this scene, the target wall object is drawn based on the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the start side and the end side. Since the target wall object is spliced ​​with the straight wall objects on the start side and the end side, it is necessary to determine the splicing points before drawing the target wall object, and then ensure the splicing shapes of the start side and the end side based on the splicing points.

[0031] On the starting side or the end side, the target wall object is spliced ​​with one or more straight wall objects. If there is no adjacent wall on the starting side or the end side, the wall splicing is performed on one side. For example, Figure 2 As shown, at the starting point or end point side of the target wall object, the target wall object is spliced ​​with multiple straight wall objects, and there is no adjacent wall object to splice on the other side, so the target wall object is spliced ​​with the straight wall object on one side.

[0032] For the arc wall object, the corresponding key parameters are as follows: the starting point of the arc wall (start), the end point of the arc wall (end), the center of the circle where the arc wall is located (center), the radius of the circle where the arc wall is located (radius), the thickness of the arc wall (thickness), the direction of the arc (whether the starting point points to the end point clockwise or counterclockwise, where counterclockwise is true, indicating counterclockwise, and counterclockwise is false, indicating clockwise), the center point of the arc (topCenter), and the arc height (the distance between the midpoint of the chord between the starting point and the end point and the center point of the arc, represented by arcHeight).

[0033] Step 102: in response to an interactive operation on a target wall object, updating a target parameter variable associated with the target wall object, the interactive operation being a wall moving operation or a wall shape changing operation, and the target parameter variable at least includes the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius.

[0034] After the drawing of the target wall object is completed, when an interactive operation for the target wall object is received, the target parameter variable associated with the target wall object is updated in response to the interactive operation.

[0035] The target parameter variable associated with the target wall object stores at least the starting point, end point, arc center point, circle center and radius of the target wall object, and the content stored in the target parameter variable is used to determine the arc wall structure and position. When an interactive operation on the target wall object is received, the target parameter variable is updated to update the detailed parameters of the target wall object based on the interactive operation.

[0036] The interactive operation for the target wall object can be a wall moving operation or a wall shape changing operation. Based on the wall moving operation, the position of the target wall object can be updated while maintaining the shape of the target wall object. Based on the wall shape changing operation, the arc wall object can be adjusted to the required shape.

[0037] Step 103: Update the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the move or a new arc wall object with a changed shape.

[0038] After updating the target parameter variable associated with the target wall object based on the interactive operation, the arc wall information of the target wall object is updated according to the updated target parameter variable to change the position of the target wall object or adjust the wall shape of the target wall object, and then the movement or shape change of the arc wall can be realized based on the event interaction mechanism, so that the user can intuitively move and adjust the arc wall, which improves the operational flexibility and accuracy of the arc wall in the architectural design software, provides users with more powerful tools, and improves design efficiency.

[0039] In the process of adjusting the target wall object based on the interactive operation, an arc auxiliary contour matching the arc wall object is generated, and the arc auxiliary contour is updated in real time based on the adjustment of the target wall object to reflect the adjustment process of the target wall object. That is, in the process of adjusting the position or shape of the target wall object, the target parameter variable is updated in real time, and the arc auxiliary contour is updated in linkage based on the update of the target parameter variable, so as to enhance the visualization of the interactive operation by introducing the arc auxiliary contour.

[0040] When the interactive operation on the target wall object stops, such as when the movement of the target wall object stops or when the shape adjustment of the target wall object stops, the corresponding latest arc auxiliary contour matches the latest arc wall information, and the latest arc wall information is determined based on the currently corresponding updated target parameter variable. By updating the arc wall information of the target wall object based on the updated target parameter variable, a new arc wall object after movement or a new arc wall object with a changed shape can be determined.

[0041] It should be noted that the shape and position of the new arc wall object can be determined based on the updated arc wall information. When redrawing the new arc wall object, it is also necessary to consider the splicing of the new arc wall object with the adjacent wall, that is, the new arc wall object is redrawn according to the updated arc wall information combined with the splicing points with the adjacent wall.

[0042] The above-mentioned implementation scheme of the present application, after receiving an interactive operation on a target wall object, updates the target parameter variable associated with the target wall object in response to the interactive operation of moving the wall or changing the wall shape, and updates the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the move or a new arc wall object with a changed shape. The arc wall can be moved or the shape of the arc wall can be adjusted based on an event interaction mechanism, so that the user can intuitively move and adjust the arc wall, thereby improving the operational flexibility and accuracy of the arc wall in the architectural design software, providing users with more powerful tools, and the real-time interaction and editing functions greatly improve the design efficiency.

[0043] The following first introduces the case where the interactive operation is a wall moving operation. Optionally, in response to the interactive operation on the target wall object, when updating the target parameter variable associated with the target wall object, the following steps are included:

[0044] In response to a wall movement operation on a target wall object, recording a corresponding movement offset during the wall movement process;

[0045] Update the positions of the start and end points of the target wall object based on the movement offset;

[0046] After the moving target wall object stops, the target starting position and the target ending position are determined;

[0047] Update the target parameter variables based on the target start position and target end position.

[0048] In response to the mousedown event for the target wall object, the target wall object is selected, and an intermediate variable dragVariables is created to record the corresponding information when the target wall object does not move, dragVariables = {ox, oy, unv, length}, ox is the horizontal coordinate corresponding to the initial mouse press, oy is the vertical coordinate corresponding to the initial mouse press, unv is the unit vector pointing from the starting point to the end point, and length is the straight-line distance between the starting point and the end point.

[0049] In response to the mousemove event for the target wall object, adjust the position of the target wall object on the canvas, record the mouse coordinates {x, y} during the wall movement, and determine and record the offset ofx in the x direction and the offset ofy in the y direction based on the ox and oy recorded in the intermediate variables. During the wall movement, update the start and end points of the target wall object based on the offset ofx in the x direction and the offset ofy in the y direction. The start and end positions of the moving arc wall object are recorded as cStart and cEnd.

[0050] After stopping the movement of the target wall object, determine the target starting position and target end position corresponding to the arc wall object. In the process of wall movement, an adsorption event may occur. Based on the adsorption function, the target starting position or the target end position can be determined. After the target starting position or the target end position is determined, another position is determined based on the relationship between the starting point and the end point. If no adsorption occurs during the movement, the target starting position is determined based on the initial starting position and the final offset, and the target end position is determined based on the initial end position and the final offset.

[0051] Among them, in the case of an adsorption event, the following scheme is adopted when determining the target starting position and the target end position:

[0052] During the movement of the target wall object, when a first target endpoint whose distance from the first endpoint of the target wall object meets the adsorption threshold is identified, the first endpoint is adsorbed to the first target endpoint and the movement of the target wall object is stopped, the first endpoint being the starting point or the end point of the target wall object; the coordinates of the first endpoint are updated according to the coordinates of the first target endpoint; the coordinates of the second endpoint of the target wall object are updated according to the updated coordinates of the first endpoint, the unit vector and the straight-line distance between the starting point and the end point when no movement occurs, the second endpoint is another endpoint different from the first endpoint; based on the updated coordinates of the first endpoint and the coordinates of the second endpoint, the target starting point position and the target end point position are determined.

[0053] During the movement of the target wall object, the first target endpoint whose distance from the starting point or end point meets the adsorption threshold is identified in the canvas. The size of the adsorption threshold can be customized, for example, 10. When an endpoint whose distance from the starting point or end point is less than or equal to the adsorption threshold is identified, the endpoint is determined to be the first target endpoint. After the first target endpoint is identified, the first endpoint (the starting point or end point whose distance from the first target endpoint meets the adsorption threshold) is adsorbed to the first target endpoint and the target wall object is stopped from moving. The coordinates of the first endpoint are updated. At this time, the first endpoint coincides with the first target endpoint, and the coordinates of the first endpoint are the coordinates of the first target endpoint. As an example, during the movement of the target wall object, it is identified that the distance between cStart and an endpoint in the canvas is equal to the adsorption threshold, then the starting point of the target wall object is adsorbed to the endpoint, and the coordinates of cStart are updated based on the coordinates of the endpoint. It should be noted that during the adsorption process, the shape of the arc wall object remains unchanged, and because it is a moving operation for the entire target wall object, it will drive the starting point and end point to move synchronously. Figure 3 As shown, when the arc wall object moves on the canvas based on the drag operation, an adsorption event is generated between a certain endpoint and other endpoints on the canvas, driving the entire arc wall object to be connected to a straight wall object based on adsorption.

[0054] After determining the updated coordinates of the first endpoint, the updated coordinates corresponding to the second endpoint are calculated based on the updated coordinates of the first endpoint, the unit vector and the straight-line distance between the starting point and the end point when no movement occurs. Specifically, the direction is determined based on the unit vector, and the straight-line distance between the starting point and the end point is intercepted in the determined direction with the updated first endpoint as the reference to determine the updated coordinates corresponding to the second endpoint, thereby determining the position of the other endpoint based on the first endpoint, the unit vector and the distance between the starting point and the end point. For example, the first endpoint is the starting point, and after the first endpoint is adsorbed and the coordinates are updated, the first direction is determined based on the direction of the unit vector (starting point pointing to the end point), and the corresponding straight-line distance is intercepted in the determined first direction with the first endpoint as the reference to determine the updated coordinates corresponding to the second endpoint after the wall moves. If the first endpoint is the end point, the first direction is determined based on the opposite direction of the unit vector.

[0055] After the updated coordinates of the first endpoint and the second endpoint are determined, the target start position and the target end position are determined based on the updated coordinates of the first endpoint and the updated coordinates of the second endpoint.

[0056] After determining the target starting point position and the target end point position, the target parameter variable is updated according to the target starting point position and the target end point position. Since the target parameter variable stores the starting point, end point, arc center point, circle center and radius of the target wall object, the starting point and end point stored in the target parameter variable can be updated based on the target starting point position and the target end point position. Since the shape of the arc wall object has not changed, the radius remains unchanged and the arc height remains unchanged, the updated arc center point and circle center are determined based on the updated starting point, updated end point, radius and arc height (involving conventional mathematical operations, which will not be further elaborated here) to achieve the update of the target parameter variable.

[0057] After completing the update of the target parameter variable, the arc auxiliary contour is updated according to the target parameter variable to determine the final arc auxiliary contour. In response to the mouseup event of the target wall object, the arc wall information is updated, the arc wall is redrawn, the arc auxiliary contour is hidden, and the selected state of the target wall object is ended.

[0058] In the above implementation scheme, the position of the arc wall object is adjusted according to the interactive operation of moving the wall, so as to realize the movement of the arc wall object based on the event interaction mechanism, thereby improving the flexibility and accuracy of the movement of the arc wall object in the architectural design software and improving the design efficiency of the arc wall object.

[0059] The following continues to introduce the case where the interactive operation is a wall shape change operation. Optionally, the wall shape change operation includes an endpoint position change operation and an arc center point change operation; when responding to the interactive operation on the target wall object, updating the target parameter variable associated with the target wall object includes:

[0060] In response to an endpoint position change operation for a target wall object, the coordinates corresponding to the first endpoint after the position change are recorded, and the target parameter variable is updated according to the coordinates corresponding to the first endpoint, the initial coordinates of the second endpoint, and the arc height corresponding to the target wall object, wherein the first endpoint is a starting point or an end point, and the second endpoint is another endpoint different from the first endpoint;

[0061] or

[0062] In response to the arc center point change operation for the target wall object, an updated arc center point is determined, and the target parameter variable is updated according to the updated arc center point, the start point, and the end point.

[0063] In this embodiment, the wall shape change operation for the target wall object can be an endpoint position change operation or an arc center point change operation, that is, the wall shape of the target wall object can be triggered to change by changing the position of a certain endpoint of the target wall object, and the wall shape of the target wall object can be triggered to change by changing the arc center point of the target wall object. It should be noted that changing the position of the two endpoints of the target wall object may also cause the wall shape of the target wall object to change, but this process cannot be achieved through a single operation of the mouse. The corresponding scenario of this embodiment is: the position of a certain endpoint of the target wall object changes, and the arc height remains unchanged, so that the wall shape of the target wall object changes.

[0064] In case the first endpoint (starting point or end point) of the target wall object changes position, the coordinates corresponding to the first endpoint after the position change are recorded. In case the first endpoint changes position, the second endpoint remains stationary and the arc height remains unchanged. After obtaining the coordinates corresponding to the first endpoint after the position change, the target parameter variable is updated according to the coordinates corresponding to the first endpoint, the initial coordinates corresponding to the second endpoint and the arc height corresponding to the target wall object.

[0065] In the case where the arc center point of the target wall object changes, the two endpoints (starting point and end point) of the target wall object remain unchanged. After the arc center point changes and the updated arc center point is determined, the target parameter variables are updated based on the updated arc center point, starting point and end point.

[0066] Wherein, in the case where the position of the first endpoint of the target wall object changes, in response to the endpoint position change operation on the target wall object, recording the coordinates corresponding to the first endpoint after the position change includes:

[0067] In response to a dragging operation of changing an endpoint position of a first endpoint, identifying whether there is a second target endpoint whose distance from the first endpoint meets an adsorption threshold during the dragging process;

[0068] In response to the existence of the second target endpoint, the first endpoint is adsorbed to the second target endpoint and the dragging is stopped, and the coordinates corresponding to the first endpoint are updated and recorded according to the coordinates of the second target endpoint;

[0069] In response to the absence of the second target endpoint, the coordinates corresponding to the first endpoint after the dragging is stopped are determined and recorded.

[0070] The position of the first endpoint (such as the starting point) is changed based on the mousemove event, and the mousemove event is a drag event for dragging the first endpoint. During the dragging process, it is identified whether there is a second target endpoint in the canvas whose distance from the first endpoint meets the adsorption threshold. If the second target endpoint is identified, the first endpoint is directly adsorbed to the second target endpoint. At this time, the first endpoint coincides with the second target endpoint, and the coordinates of the first endpoint are updated to the coordinates of the second target endpoint and the updated coordinates of the first endpoint are recorded. The adsorption event involved here is the adsorption of the first endpoint, and the second endpoint of the target wall object remains unchanged in its initial state. In this case, the second endpoint maintains its position unchanged, the first endpoint changes its position, and the arc height of the arc wall object remains unchanged, resulting in a change in the shape of the arc wall object, that is, in this implementation, only a single endpoint changes its position, and the arc height of the arc wall object remains unchanged.

[0071] If the second target endpoint whose distance from the first endpoint meets the adsorption threshold is not identified during the dragging process, after the mouse stops dragging, the coordinates corresponding to the first endpoint after stopping dragging are determined and recorded. Similarly, since only the first endpoint changes position and the second endpoint remains in the initial state, the shape of the arc wall object will change. In this implementation, the arc height of the arc wall object remains unchanged when a single endpoint changes position.

[0072] That is, for situations involving a position change of the first endpoint, other endpoints adjacent to the first endpoint are identified in the canvas. If other endpoints are identified, only the first endpoint is adsorbed to update the coordinates of the first endpoint without affecting the second endpoint. If no other endpoints are identified, the coordinates of the first endpoint are updated based on the movement offset after the dragging ends.

[0073] After updating the coordinates of the first endpoint, updating the target parameter variable according to the coordinates corresponding to the first endpoint, the initial coordinates of the second endpoint and the arc height corresponding to the target wall object specifically includes the following steps:

[0074] Determine the coordinates of the center point according to the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint;

[0075] Determine an updated arc center point according to the center point coordinates, the initial coordinates of the second endpoint, the arc height corresponding to the target wall object, and the current pointing information from the starting point to the end point;

[0076] The first full circle information is determined according to the updated arc center point, the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint, and the target parameter variable is updated according to the first full circle information.

[0077] After updating the coordinates of the first endpoint based on the mousemove event for the first endpoint (such as the starting point), record the coordinates pStart of the first endpoint at this time, calculate the center point coordinates lineCenter (chord center point coordinates) based on pStart and the initial coordinates end of the second endpoint (such as the end point), and then calculate the topCenter (arc center point) at this time according to lineCenter (center point coordinates), end (initial coordinates of the second endpoint), arcHeight (arc height), and counterclockwise (used to indicate whether the starting point points to the end point in a clockwise direction or a counterclockwise direction).

[0078] After knowing pStart and end, determine which side of the chord corresponding to pStart and end is located by counterclockwise, and calculate the specific position of topCenter based on lineCenter, end, and arcHeight. Figure 4 As shown, since pStart and end are known, the coordinates (lineCenter x, lineCenter y) corresponding to lineCenter can be determined based on pStart and end, and the sum of ∠a and ∠c is equal to 90 degrees, and the sum of ∠b and ∠c is equal to 90 degrees, so ∠a and ∠b are equal. ∠a=∠b=Math.atan2(end y-lineCenter y, end x-lineCenter x). Figure 4 In the coordinate system shown, the positive direction of the X axis is to the right and the positive direction of the Y axis is downward. When ∠a and ∠b are known, the position of the arc center point is determined based on the coordinates corresponding to lineCenter, arc height arcHeight, ∠a and ∠b, as follows:

[0079] topCenter x=lineCenter x+arcHeight*sin(∠b);

[0080] topCenter y=lineCenter y-arcHeight*cos(∠b).

[0081] After determining the position of the arc center point, the first full circle information is calculated based on the topCenter, pStart, and end points, and then the target parameter variable is updated based on the first full circle information. Since topCenter, pStart, and end are all points on a circle, a circle is determined by knowing the three points on the circle, which is a conventional operation (for example, it can be solved according to the equation of the circle), and no further explanation is given here.

[0082] Since the target parameter variable stores the starting point, end point, arc center point, circle center and radius of the target wall object, after determining the first full circle information, the circle center and radius in the target parameter variable are updated based on the determined circle center and radius, and the starting point and arc center point in the target parameter variable are updated based on pStart (the first endpoint is the starting point) and the re-determined topCenter, and the end point in the target parameter variable remains unchanged.

[0083] After completing the update of the target parameter variable, the arc auxiliary outline is updated according to the information in the target parameter variable (such as the updated coordinates of the first endpoint, the updated center of the circle, the initial coordinates of the second endpoint, the updated radius) and counterclockwise (used to indicate whether the starting point points to the end point in a clockwise direction or a counterclockwise direction) to determine the final arc auxiliary outline, update the arc wall information in response to the mouseup event, redraw the arc wall, and hide the arc auxiliary outline.

[0084] In the above-mentioned implementation scheme of adjusting the shape of the arc wall based on the change of the endpoint position, the updated coordinates of the first endpoint are determined in response to the dragging operation on the first endpoint, the whole circle information is determined based on mathematical calculations using known information, thereby updating the target parameter variables, and the shape of the arc wall object is adjusted using the updated target parameter variables to achieve shape changes of the arc wall object based on an event interaction mechanism, thereby improving the flexibility and accuracy of the shape adjustment of the arc wall object in the architectural design software and improving the design efficiency of the arc wall object.

[0085] Wherein, in the case where the arc center point of the target wall object changes, in response to the arc center point change operation for the target wall object, determining the updated arc center point, and updating the target parameter variable according to the updated arc center point, the start point, and the end point, including:

[0086] In response to a drag operation on the arc center point of the target wall object, determining a projection point of the cursor on a perpendicular midline between a start point and an end point during the dragging process;

[0087] The second full circle information is determined according to the corresponding target projection point, starting point, and end point when dragging ends, and the target parameter variable is updated according to the second full circle information. The target projection point is the updated arc center point.

[0088] The center point of the arc is changed based on the mousemove event. The mousemove event is a drag event for dragging the center point of the arc. During the dragging process, the starting point and the end point remain stationary. In order to ensure that the distance from the center point of the arc to the starting point and the end point is the same, the cursor position needs to be projected onto the vertical midline between the starting point and the end point. During the dragging process, the projection point of the cursor on the vertical midline between the starting point and the end point is determined in real time. After the dragging is completed, the target projection point is determined. The determined target projection point is the updated arc center point. Figure 5 As shown, in the dragging event of dragging the arc center point, the start and end points of the arc wall object remain stationary. During the dragging process, the projection point of the cursor on the vertical midline between the start and end points is determined, and then the target projection point is determined at the end of the dragging. The determined target projection point is the new arc center point.

[0089] After determining the target projection point, the second full circle information is determined based on the target projection point, the starting point, and the end point. The process of determining the second full circle information is similar to the process of determining the first full circle information. After determining the second full circle information, the target parameter variable is updated according to the second full circle information.

[0090] Since the target parameter variable stores the starting point, end point, arc center point, circle center, and radius of the target wall object, after determining the second full circle information, the corresponding parameters in the target parameter variable are updated based on the determined circle center, radius, and arc center point, and the starting point and end point in the target parameter variable remain unchanged. It should be noted that after determining the updated arc center point, counterclockwise also needs to be updated to determine whether the arc direction from the current starting point to the end point is clockwise or counterclockwise. For example, Figure 6 As shown, in the initial state, the arc direction from the start point of the arc wall object to the end point is clockwise. As the arc center point is dragged, the arc direction from the start point of the arc wall object to the end point becomes counterclockwise. At this time, counterclockwise needs to be updated in time.

[0091] After completing the update of the target parameter variable, the arc auxiliary outline is updated according to the information in the target parameter variable to determine the final arc auxiliary outline, and the arc wall information is updated in response to the mouseup event, the arc wall is redrawn, and the arc auxiliary outline is hidden.

[0092] In the above-mentioned implementation scheme for adjusting the shape of the arc wall based on the change of the arc center point, the projection point of the cursor on the vertical midline between the starting point and the end point is determined in response to the dragging operation of the arc center point, the updated arc center point is determined based on the last projection point, and then the whole circle information is determined based on the updated arc center point, the starting point and the end point, so as to update the target parameter variable, and adjust the shape of the arc wall object using the updated target parameter variable to realize the shape change of the arc wall object based on the event interaction mechanism, thereby improving the flexibility and accuracy of the shape adjustment of the arc wall object in the architectural design software and improving the design efficiency of the arc wall object.

[0093] In an optional embodiment of the present application, the method further includes:

[0094] In the straight wall object corresponding to the starting point side of the target wall object, determine the first contour line and the second contour line that match the left and right wall sides of the starting point side of the target wall object, and determine the first outer contour spt and the first inner contour spt associated with the starting point according to the intersection of the first contour line, the second contour line and the left wall side and the right wall side of the starting point side of the target wall object;

[0095] In the straight wall object corresponding to the end point side of the target wall object, determine the third contour line and the fourth contour line that match the left and right wall sides of the end point side of the target wall object, and determine the second outer contour splicing point ept and the second inner contour splicing point epb associated with the end point according to the intersection of the third contour line, the fourth contour line and the left wall side and the right wall side of the end point side of the target wall object.

[0096] On the starting point side of the target wall object, the straight wall object is classified as a left wall or a right wall, and a first array for storing the left wall and a second array for storing the right wall are determined. Since the target wall object is an arc wall object, it is necessary to determine two tangent vectors at the starting point for the arc wall object, and then determine the first target vector among the two tangent vectors. The first target vector is the vector with the smaller angle between the two tangent vectors and the first reference vector (the vector determined by the starting point and the arc center point of the arc wall object). After determining the first target vector, the first target vector is used to classify the straight wall object on the starting point side as a left wall or a right wall. Among them, the straight wall object on the starting point side has a common point with the arc wall object. When using the first target vector to classify the left wall or the right wall, it is determined whether the other endpoint of the straight wall object (such as endpoint B) is on the left or right side of the straight line indicated by the first target vector to achieve wall classification. For example, Figure 7 As shown, a first target vector is determined at the starting point side of the arc wall object, and it is identified whether the endpoint B of the straight wall object is on the left or right side of the straight line indicated by the first target vector to determine whether the straight wall object belongs to the left wall or the right wall.

[0097] After the left and right walls are classified on the starting point side, the first contour line matching the left wall side of the target wall object is searched in the first array storing the left wall, and the second contour line matching the right wall side of the target wall object is searched in the second array storing the right wall. The first contour line is the contour line closest to the left wall side of the target wall object, and the second contour line is the contour line closest to the right wall side of the target wall object. Then, according to the intersection of the first contour line, the second contour line and the left wall side and the right wall side of the starting point side of the target wall object, the first outer contour spt and the first inner contour spb associated with the starting point are determined.

[0098] Among them, the contour points of the arc wall object are: startTop, startBottom, endTop, endBottom, where top represents the outer contour of the arc wall, and bottom represents the inner contour of the arc wall. It should be noted that if the first array is empty, it means that there is no left adjacent wall object on the starting side. At this time, the straight wall object with the largest angle with the target wall object can be screened out from at least one right adjacent wall object, and the straight wall object is added to the first array. If the second array is empty, it is processed based on similar logic. When distinguishing left and right on the starting side, the contour located on the left side of the straight line indicated by the first target vector is determined as the left contour, and the wall with the endpoint located on the left side of the straight line indicated by the first target vector is determined as the left wall. The contour located on the right side of the straight line indicated by the first target vector is determined as the right contour, and the wall with the endpoint located on the right side of the straight line indicated by the first target vector is determined as the right wall.

[0099] As an example, Figure 8 As shown, if the right contour (right wall side) of the arc wall is the outer contour (the radius of the outer contour is the radius of the arc wall trajectory plus half the wall thickness), find the intersection of the circle where the right contour is located and the straight line where the second contour line is located, and the intersection is defined as spt. If the number of intersections is 0, spt is the startTop corresponding to the right contour. If the number of intersections is 1, spt is the intersection. If the number of intersections is 2, determine the intersection closest to the starting point among the two intersections, and spt is the intersection; for the case where the distance between the two intersections and the starting point is the same, determine the corresponding intersection vectors for the two intersections (determined based on the starting point and the intersection), calculate the angle between the intersection vector and the first target vector, and determine the intersection corresponding to the intersection vector with the smaller angle as spt.

[0100] Then find the intersection of the circle where the left contour (inner contour) of the arc wall is located and the straight line where the first contour line is located. The intersection is defined as spb. If the number of intersections is 0, spb is the startBottom corresponding to the left contour. If the number of intersections is 1, spb is the intersection. If the number of intersections is 2, the processing method is the same as that of the outer contour.

[0101] The above content is an introduction to the situation on the starting point side. On the end point side, the same processing logic as the starting point side is used to classify the left and right walls of the straight wall object, and determine the third array storing the left wall and the fourth array storing the right wall. Two tangent vectors are determined at the end point of the arc wall object, and then the second target vector is determined in the two tangent vectors. The second target vector is the vector with the smaller angle between the second reference vector (the vector determined by the end point and the arc center point of the arc wall object) in the two tangent vectors. Then the second target vector is used to classify the left and right walls of the straight wall object on the end point side, and it is determined whether the other end point of the straight wall object is on the left or right side of the straight line indicated by the second target vector to achieve wall classification. After the left and right wall classification is completed on the end point side, the third contour line matching the left wall side of the target wall object on the end point side is searched in the third array storing the left wall, and the fourth contour line matching the right wall side of the target wall object is searched in the fourth array storing the right wall. Then, according to the intersection of the third contour line, the fourth contour line and the left wall side and the right wall side of the end point of the target wall object, the second outer contour splicing point ept and the second inner contour splicing point epb associated with the end point are determined. Accordingly, if the third array or the fourth array is an empty array, the processing method is similar to the case where the first array or the second array is empty; on the end point side, when distinguishing between left and right, the contour located on the left side of the straight line indicated by the second target vector is determined as the left contour, and the wall with the endpoint located on the left side of the straight line indicated by the second target vector is determined as the left wall, and the contour located on the right side of the straight line indicated by the second target vector is determined as the right contour, and the wall with the endpoint located on the right side of the straight line indicated by the first target vector is determined as the right wall.

[0102] As an example, Figure 8 As shown, at the end point, the right contour of the arc wall (right wall side) is the inner contour, and the intersection of the circle where the right contour is located and the straight line where the fourth contour line is located is determined by finding the intersection of the circle where the left contour is located and the straight line where the third contour line is located is determined by finding the intersection of the circle where the left contour is located and the straight line where the third contour line is located. The process of processing in different ways based on different numbers of intersections will not be repeated here. Figure 8 In the figure, epb and spb correspond to the case where the number of intersections is 0, and spt and ept correspond to the case where the number of intersections is 2.

[0103] After determining the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, drawing the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side includes the following steps:

[0104] Determine a first starting point angle and a first end point angle according to the first outer contour spt and the second outer contour splicing point ept, and determine a plurality of outer contour discrete points arranged clockwise on the outer contour according to the first starting point angle and the first end point angle;

[0105] Determine a second starting point angle and a second end point angle according to the first inner contour splicing point spb and the second inner contour splicing point epb, and determine a plurality of inner contour discrete points arranged clockwise on the inner contour according to the second starting point angle and the second end point angle;

[0106] The starting point, multiple outer contour discrete points, the end point, and multiple inner contour discrete points are placed in the target array as key points, and the target wall object is drawn according to the key points in the target array.

[0107] In determining Figure 8 After the first outer contour splicing point spt and the second outer contour splicing point ept shown, for the outer contour, according to the information of the center of the circle, the first starting angle startTopAngle and the first end angle endTopAngle are obtained by the Math.atan2 function. Taking the first starting angle startTopAngle as an example, startTopAngle = Math.atan2 (spt.y-center.y, spt.x-center.x). After obtaining the first starting angle and the first end angle, multiple outer contour discrete points arranged clockwise on the outer contour are calculated based on the first starting angle and the first end angle.

[0108] At this stage, we first need to determine whether the outer contour is clockwise or counterclockwise. If it is clockwise, we can directly calculate it. If it is counterclockwise, we need to permute the start and end points of the outer contour, and then determine the startTopAngle and endTopAngle. If the endTopAngle is smaller than the startTopAngle, we can add 2π to the endTopAngle.

[0109] When determining the discrete points on the outer contour by calculation, the angle range of the arc corresponding to the outer contour is determined to be endTopAngle minus startTopAngle, and the angle range is divided into n equal parts, then the angle t corresponding to each part is t = startTopAngle + i (endTopAngle - startTopAngle) / n, and the value of i is greater than or equal to 0 and less than or equal to n. For angle t, taking the positive half axis of the XY axis as an example, the corresponding coordinates on the arc are (center x + R*cos t, center y + R*sint). Based on the above calculation, multiple outer contour discrete points arranged clockwise on the outer contour can be determined.

[0110] In determining Figure 8After the first inner contour splicing point spb and the second inner contour splicing point epb are shown, for the inner contour, according to the information of the center of the circle, the second starting angle startBottomAngle and the second end angle endBottomAngle are obtained by the Math.atan2 function. After obtaining the second starting angle and the second end angle, multiple inner contour discrete points arranged clockwise on the inner contour are calculated based on the second starting angle and the second end angle. For the detailed process, please refer to the description of the outer contour, which will not be repeated here.

[0111] After determining multiple outer contour discrete points and multiple inner contour discrete points, identify whether the arc wall object is clockwise or counterclockwise (the direction from the start point of the arc wall object to the end point is clockwise or counterclockwise). If it is clockwise, you can first put the starting point into the target array, put multiple outer contour discrete points into the target array in positive order, put the end point into the target array, put multiple inner contour discrete points into the target array in reverse order, and draw the points in the target array in sequence to ensure that they are connected from beginning to end. If it is counterclockwise, you can first put the end point into the target array, put multiple outer contour discrete points into the target array in positive order, put the starting point into the target array, put multiple inner contour discrete points into the target array in reverse order, and draw the points in the target array in sequence to ensure that they are connected from beginning to end.

[0112] The above introduces the implementation process of splicing arc wall objects with straight wall objects and drawing arc wall objects. Because the existing technology has the following problems when dealing with the splicing of arc walls and straight walls: 1. The splicing is not smooth enough, affecting the overall aesthetics and practicality; 2. It is impossible to accurately handle complex splicing situations; 3. It is difficult to achieve filling effects in drawing environments such as Canvas, resulting in poor visual presentation; 4. Lack of flexibility, difficulty in adapting to different wall thicknesses and splicing angles and other problems. The above scheme achieves smooth splicing and filling effects in drawing environments such as Canvas by accurately calculating tangent vectors, judging the relationship between wall positions, handling special situations, and converting continuous arcs into discrete point sets, thereby improving visual effects, accurately handling complex multi-wall splicing situations, and achieving smooth splicing of arc walls and straight walls. It improves the applicability, aesthetics and practicality of the design, and has good flexibility and can adapt to different wall thicknesses and splicing angles.

[0113] The present application also provides an interactive arc wall updating device, such as Fig. 9 As shown, including:

[0114] A drawing module 901 is used to draw the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, wherein the target wall object is an arc wall object;

[0115] A first updating module 902 is configured to update a target parameter variable associated with the target wall object in response to an interactive operation on the target wall object, wherein the interactive operation is a wall moving operation or a wall shape changing operation, and the target parameter variable includes at least the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius;

[0116] The second updating module 903 is used to update the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the move or a new arc wall object with a changed shape.

[0117] Optionally, the first updating module includes:

[0118] A recording submodule, configured to record a corresponding movement offset during the wall movement process in response to a wall movement operation on the target wall object;

[0119] A first updating submodule, configured to update the positions of the start point and the end point of the target wall object based on the movement offset;

[0120] A first determination submodule is used to determine a target starting position and a target end position after stopping moving the target wall object;

[0121] The second updating submodule is used to update the target parameter variable according to the target starting position and the target ending position.

[0122] Optionally, the first determining submodule includes:

[0123] a first processing unit, configured to, when identifying a first target endpoint whose distance to a first endpoint of the target wall object satisfies an adsorption threshold during the movement of the target wall object, adsorb the first endpoint to the first target endpoint and stop moving the target wall object, wherein the first endpoint is a starting point or an end point of the target wall object;

[0124] A first updating unit, configured to update the coordinates of the first endpoint according to the coordinates of the first target endpoint;

[0125] A second updating unit, configured to update the coordinates of a second endpoint of the target wall object according to the updated coordinates of the first endpoint, the unit vector and the straight-line distance between the starting point and the end point when no movement occurs, wherein the second endpoint is another endpoint different from the first endpoint;

[0126] The first determining unit is used to determine the target starting position and the target ending position based on the updated coordinates of the first endpoint and the updated coordinates of the second endpoint.

[0127] Optionally, the wall shape change operation includes an endpoint position change operation and an arc center point change operation; and the first update module includes:

[0128] a record update submodule, configured to respond to an endpoint position change operation for the target wall object, record the coordinates corresponding to the first endpoint after the position change, and update the target parameter variable according to the coordinates corresponding to the first endpoint, the initial coordinates of the second endpoint, and the arc height corresponding to the target wall object, wherein the first endpoint is a starting point or an end point, and the second endpoint is another endpoint different from the first endpoint;

[0129] or

[0130] The determination update submodule is used to determine an updated arc center point in response to an arc center point change operation on the target wall object, and update the target parameter variable according to the updated arc center point, the start point and the end point.

[0131] Optionally, the record updating submodule includes:

[0132] An identification unit, configured to respond to a dragging operation that changes the endpoint position of the first endpoint and to identify whether there is a second target endpoint whose distance from the first endpoint satisfies an adsorption threshold during the dragging process;

[0133] A second processing unit is configured to, in response to the existence of the second target endpoint, adsorb the first endpoint to the second target endpoint and stop dragging, and update and record the coordinates corresponding to the first endpoint according to the coordinates of the second target endpoint;

[0134] A determination recording unit is used to determine and record the coordinates corresponding to the first endpoint after the dragging stops in response to the absence of the second target endpoint.

[0135] Optionally, the record updating submodule includes:

[0136] A second determining unit, configured to determine the coordinates of the center point according to the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint;

[0137] A third determining unit, configured to determine an updated arc center point according to the center point coordinates, the initial coordinates of the second end point, the arc height corresponding to the target wall object, and current pointing information from the starting point to the end point;

[0138] The first determination and updating unit is used to determine the first full circle information according to the updated arc center point, the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint, and update the target parameter variable according to the first full circle information.

[0139] Optionally, the determining and updating submodule includes:

[0140] A fourth determining unit, configured to determine, in response to a dragging operation on the arc center point of the target wall object, a projection point of the cursor on a vertical midline between the starting point and the end point during the dragging process;

[0141] The second determination and updating unit is used to determine the second full circle information according to the corresponding target projection point when the dragging ends, the starting point, and the end point, and update the target parameter variable according to the second full circle information, and the target projection point is the updated arc center point.

[0142] Optionally, the device further comprises:

[0143] A first determination module is used to determine, in a straight wall object corresponding to the starting point side of the target wall object, a first contour and a second contour matching the left and right wall edges on the starting point side of the target wall object, and determine a first outer contour spt and a first inner contour spt associated with the starting point according to the intersection of the first contour, the second contour and the left and right wall edges on the starting point side of the target wall object;

[0144] The second determination module is used to determine, in the straight wall object corresponding to the end point side of the target wall object, a third contour and a fourth contour that match the left and right wall sides of the end point side of the target wall object, and determine a second outer contour splicing point ept and a second inner contour splicing point epb associated with the end point according to the intersection of the third contour, the fourth contour and the left and right wall sides of the end point side of the target wall object.

[0145] Optionally, the drawing module includes:

[0146] A second determination submodule is used to determine a first starting point angle and a first end point angle according to the first outer contour spt and the second outer contour splicing point ept, and to determine a plurality of outer contour discrete points arranged clockwise on the outer contour according to the first starting point angle and the first end point angle;

[0147] A third determination submodule is used to determine a second starting point angle and a second end point angle according to the first inner contour splicing point spb and the second inner contour splicing point epb, and determine a plurality of inner contour discrete points arranged clockwise on the inner contour according to the second starting point angle and the second end point angle;

[0148] The drawing submodule is used to place the starting point, the multiple outer contour discrete points, the end point, and the multiple inner contour discrete points as key points in the target array, and draw the target wall object according to the key points in the target array.

[0149] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0150] An embodiment of the present application also provides an electronic device, including: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, the various processes of the above-mentioned interactive curved wall updating method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.

[0151] For example, Fig.10 FIG. 1 shows a schematic diagram of the physical structure of an electronic device. Fig.10 As shown, the electronic device may include: a processor 1010, a communication interface 1020, a memory 1030 and a communication bus 1040, wherein the processor 1010, the communication interface 1020 and the memory 1030 communicate with each other through the communication bus 1040. The processor 1010 may call the logic instructions in the memory 1030, and the processor 1010 is used to execute each process of the interactive curved wall updating method of the embodiment of the present application, which will not be described one by one here.

[0152] In addition, the logic instructions in the above-mentioned memory 1030 can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application.

[0153] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, each process of the above-mentioned interactive curved wall updating method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it is not repeated here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0154] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0155] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0156] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. An interactive curved wall updating method, characterized in that: include: Draw the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, where the target wall object is an arc wall object; In response to an interactive operation on the target wall object, updating a target parameter variable associated with the target wall object, wherein the interactive operation is a wall moving operation or a wall shape changing operation, and the target parameter variable includes at least the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius; According to the updated target parameter variable, the arc wall information of the target wall object is updated to determine a new arc wall object after the move or a new arc wall object with a changed shape.

2. The method according to claim 1, characterized in that: The updating of the target parameter variable associated with the target wall object in response to the interactive operation on the target wall object comprises: In response to a wall movement operation on the target wall object, recording a corresponding movement offset during the wall movement process; Based on the movement offset, the start point and the end point of the target wall object are updated; After stopping moving the target wall object, determining a target starting position and a target end position; The target parameter variable is updated according to the target starting position and the target ending position.

3. The method according to claim 2, characterized in that After stopping moving the target wall object, determining the target starting position and the target ending position includes: During the movement of the target wall object, when a first target endpoint whose distance to a first endpoint of the target wall object satisfies an adsorption threshold is identified, the first endpoint is adsorbed to the first target endpoint and the movement of the target wall object is stopped, the first endpoint being the starting point or the end point of the target wall object; updating the coordinates of the first endpoint according to the coordinates of the first target endpoint; According to the updated coordinates of the first endpoint, the unit vector and the straight-line distance between the starting point and the end point when no movement occurs, the coordinates of the second endpoint of the target wall object are updated, where the second endpoint is another endpoint different from the first endpoint; The target starting position and the target ending position are determined based on the updated coordinates of the first endpoint and the updated coordinates of the second endpoint.

4. The method according to claim 1, characterized in that The wall shape change operation includes an endpoint position change operation and an arc center point change operation; The updating of the target parameter variable associated with the target wall object in response to the interactive operation on the target wall object comprises: In response to an endpoint position change operation for the target wall object, the coordinates corresponding to the first endpoint after the position change are recorded, and the target parameter variable is updated according to the coordinates corresponding to the first endpoint, the initial coordinates of the second endpoint, and the arc height corresponding to the target wall object, wherein the first endpoint is a starting point or an end point, and the second endpoint is another endpoint different from the first endpoint; or In response to the arc center point change operation for the target wall object, an updated arc center point is determined, and the target parameter variable is updated according to the updated arc center point, the start point and the end point.

5. The method according to claim 4, characterized in that The step of recording the coordinates corresponding to the first endpoint after the position change in response to the endpoint position change operation on the target wall object includes: In response to a dragging operation of changing an endpoint position of the first endpoint, identifying whether there is a second target endpoint whose distance from the first endpoint meets an adsorption threshold during the dragging process; In response to the existence of the second target endpoint, the first endpoint is adsorbed to the second target endpoint and the dragging is stopped, and the coordinates corresponding to the first endpoint are updated and recorded according to the coordinates of the second target endpoint; In response to the absence of the second target endpoint, the coordinates corresponding to the first endpoint after the dragging is stopped are determined and recorded.

6. The method according to claim 5, characterized in that The updating of the target parameter variable according to the coordinates corresponding to the first endpoint, the initial coordinates of the second endpoint and the arc height corresponding to the target wall object includes: Determine the coordinates of the center point according to the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint; Determine an updated arc center point according to the center point coordinates, the initial coordinates of the second end point, the arc height corresponding to the target wall object, and the current pointing information from the starting point to the end point; The first full circle information is determined according to the updated arc center point, the coordinates corresponding to the first endpoint and the initial coordinates of the second endpoint, and the target parameter variable is updated according to the first full circle information.

7. The method according to claim 4, characterized in that The step of determining an updated arc center point in response to the arc center point change operation for the target wall object, and updating the target parameter variable according to the updated arc center point, the start point, and the end point includes: In response to a dragging operation on the arc center point of the target wall object, determining a projection point of the cursor on a vertical midline between the starting point and the end point during the dragging process; The second full circle information is determined according to the corresponding target projection point, the starting point, and the end point when dragging ends, and the target parameter variable is updated according to the second full circle information, and the target projection point is the updated arc center point.

8. The method according to claim 1, characterized in that: The method further comprises: In the straight wall object corresponding to the starting point side of the target wall object, determine the first contour and the second contour matching the left and right wall sides of the starting point side of the target wall object, and determine the first outer contour spt and the first inner contour spt associated with the starting point according to the intersection of the first contour, the second contour and the left wall side and the right wall side of the starting point side of the target wall object; In the straight wall object corresponding to the end point side of the target wall object, a third contour and a fourth contour matching the left and right wall sides of the end point side of the target wall object are determined, and a second outer contour splicing point ept and a second inner contour splicing point epb associated with the end point are determined according to the intersection of the third contour, the fourth contour and the left wall side and the right wall side of the end point side of the target wall object.

9. The method according to claim 8, characterized in that: Drawing the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting point side and the end point side includes: Determine a first starting point angle and a first end point angle according to the first outer contour spt and the second outer contour splicing point ept, and determine a plurality of outer contour discrete points arranged clockwise on the outer contour according to the first starting point angle and the first end point angle; Determine a second starting point angle and a second end point angle according to the first inner contour splicing point spb and the second inner contour splicing point epb, and determine a plurality of inner contour discrete points arranged clockwise on the inner contour according to the second starting point angle and the second end point angle; The starting point, the plurality of outer contour discrete points, the end point, and the plurality of inner contour discrete points are placed in a target array as key points, and the target wall object is drawn according to the key points in the target array.

10. An interactive curved wall updating device, characterized in that: include: A drawing module, used for drawing the target wall object according to the splicing points corresponding to the splicing of the target wall object with the straight wall objects on the starting side and the end side, wherein the target wall object is an arc wall object; A first updating module is configured to update a target parameter variable associated with the target wall object in response to an interactive operation on the target wall object, wherein the interactive operation is a wall moving operation or a wall shape changing operation, and the target parameter variable includes at least the following parameters: a starting point, an end point, an arc center point, a circle center point, and a radius; The second updating module is used to update the arc wall information of the target wall object according to the updated target parameter variable to determine a new arc wall object after the movement or a new arc wall object with a changed shape.

11. An electronic device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed by the processor, the steps of the interactive curved wall updating method as described in any one of claims 1 to 9 are implemented.

Citation Information

Patent Citations

  • A two-dimensional to three-dimensional house type design method

    CN109711018A

  • House type drawing method and system based on HTML5

    CN111008414A

  • Building wall drawing method

    CN113656871A

  • House type structure adjusting method based on single space

    CN113901555A

  • House plan processing method and device, readable storage medium and electronic equipment

    CN114329723A