CN103544720A - Method for rapidly drawing doors and windows on plane room graph - Google Patents

Method for rapidly drawing doors and windows on plane room graph Download PDF

Info

Publication number
CN103544720A
CN103544720A CN201310517486.1A CN201310517486A CN103544720A CN 103544720 A CN103544720 A CN 103544720A CN 201310517486 A CN201310517486 A CN 201310517486A CN 103544720 A CN103544720 A CN 103544720A
Authority
CN
China
Prior art keywords
point
line segment
rectangle
line
curve
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201310517486.1A
Other languages
Chinese (zh)
Other versions
CN103544720B (en
Inventor
肖波
朱怡璇
张甜
蔺志青
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
WUXI BUPT PERCEPTIVE TECHNOLOGY INDUSTRY INSTITUTE Co Ltd
Original Assignee
WUXI BUPT PERCEPTIVE TECHNOLOGY INDUSTRY INSTITUTE Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by WUXI BUPT PERCEPTIVE TECHNOLOGY INDUSTRY INSTITUTE Co Ltd filed Critical WUXI BUPT PERCEPTIVE TECHNOLOGY INDUSTRY INSTITUTE Co Ltd
Priority to CN201310517486.1A priority Critical patent/CN103544720B/en
Publication of CN103544720A publication Critical patent/CN103544720A/en
Application granted granted Critical
Publication of CN103544720B publication Critical patent/CN103544720B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Processing Or Creating Images (AREA)

Abstract

The invention discloses a method for rapidly drawing doors and windows on a plane room graph. The method comprises the following steps of (1) determination of the positions of the doors and the windows, (2) judgment, (3) calculation and (4) drawing, wherein in the step (1), the positions of the doors to be drawn and the windows to be drawn are determined at the straight line side or the curved line side of the plane room graph, line segments are drawn on the portions where the doors and the windows are arranged, the line segments and the straight line side or the curved line side intersect and serve as the positions of the doors and the windows at the straight line side or the curved line side; in the step (2), the conditions of intersection of the drawn line segments and the straight line side or the curved line side are judged one by one; in the step (3), the line segments serve as diagonals, coordinates of four points of a rectangle to be drawn are calculated, one side of the rectangle is parallel to the straight line side or parallel to a tangent line on the intersecting portion of each line segment and the curved line side; in the step (4), according to the calculated coordinates of the four points of the rectangle, the current line segments serve as the diagonals, the four points are connected, so that the rectangle is established, and the simple doors and the simple windows are drawn. According to the method for rapidly drawing the doors and the windows on the plane room graph, the doors and the windows can be rapidly drawn on the plane room graph.

Description

The method of Fast Drawing door and window on plane room figure
Technical field
The present invention relates to computer software picture technical field, especially a kind of on plane room figure the method for Fast Drawing door and window.
Background technology
People mapped on paper with pen in the past, and the length that expends time in, once and the wrong perfect correction that is difficult to of picture.Computing machine has become an indispensable part in human being's production life now, and a lot of people utilize various software to draw on computers the various required figures such as engineering drawing, architectural drawing, plane design drawing, machine drawing, circuit diagram, process flow diagram, schematic diagram.Utilize software to replace the mapping of paper pen not only to save time, raise the efficiency, and can repeatedly change, long preservation, increasing people starts study and utilizes software to draw, and more people has started to be accustomed to and has enjoyed modern science and technology to bring their comfortable convenient.
Present drawing software is varied, relatively common are Photoshop, freehand, AutoCAD, Matlab etc., and every kind of software has own different feature, most of software has toolbar clearly to provide instrument to help to draw, can draw different lines, shape, color.
For draw door and window on easy plane room figure, existing two schemes is available:
The first is to utilize straight line tool to draw four edges to surround door and window general shape or draw rectangle and replace door and window shape, and can Selective filling color, completes the drafting of simple and easy door and window figure.
The second is in toolbar, to have simple and easy door and window figure, utilizes mouse drag to be placed in correct position in drawing interface, then adjusts size by other functions, and the indexs such as color, to reach the effect of drawing simple and easy door and window.
In the technology of Internet of things more and more rising now, often need to draw in computer terminal plane room figure and come room layout that is virtually reality like reality, do not need too attractive in appearancely, only demand simple and clearly, give top priority to what is the most important.And door and window is the indispensable part of plane room figure, if utilize above-mentioned two schemes, can draw good door and window figure, but fixedly the step of flow process, while especially drawing a plurality of door and window, needs repeatedly fixing step, relatively the labor intensive material resources time, efficiency is not very high.
Summary of the invention
The present invention is directed to the deficiencies in the prior art, propose a kind of on plane room figure the method for Fast Drawing door and window, simple and fast, effective.
In order to realize foregoing invention object, the invention provides following technical scheme: a kind of on plane room figure the method for Fast Drawing door and window, comprise the following steps:
(1) determine door and window position: in the straight sides of plane room figure or curvilinear sides, determine the position that will draw door and window, all, arrange that door and window position draws a line segment and straight sides or curvilinear sides intersects, with this line segment, represent the position of door and window in straight sides or curvilinear sides;
(2) determining step: judge that one by one drawn line segment and straight sides or curvilinear sides intersect situation;
(3) calculation procedure: take line segment as diagonal line, calculate four point coordinate that will draw rectangle, wherein one side of this rectangle is parallel with straight sides, or parallel with the tangent line of curvilinear sides intersection with this line segment;
(4) plot step: according to four apex coordinates of the rectangle calculating, take current line segment as diagonal line, connect four some structure rectangles, complete the drafting of simple and easy door and window.
Further, in determining step, judge the step that this line segment and straight line are crossing:
Step (211): this line segment two-end-point is made as A, B, institute's intersecting straight lines side two-end-point is made as C, D, obtains ABCD tetra-point coordinate, A (
Figure 871356DEST_PATH_IMAGE001
, ), B ( ,
Figure 584731DEST_PATH_IMAGE004
), C (
Figure 715498DEST_PATH_IMAGE005
,
Figure 854356DEST_PATH_IMAGE006
), D (
Figure 109888DEST_PATH_IMAGE007
,
Figure 625183DEST_PATH_IMAGE008
), at AC point-to-point transmission structure vector
Figure 610456DEST_PATH_IMAGE009
, AD point-to-point transmission structure vector , AB point-to-point transmission structure vector
Figure 663043DEST_PATH_IMAGE011
, by A point, set out, point to BCD point; Obtain CD line segment slope k, AB line segment slope
Figure 716449DEST_PATH_IMAGE012
, establish ,
Figure 473108DEST_PATH_IMAGE014
if,
Figure 31128DEST_PATH_IMAGE015
or k
Figure 622646DEST_PATH_IMAGE016
=-1, return to step and determine door and window position, setting-out section again; If variable
Figure 520195DEST_PATH_IMAGE017
;
Step (212): redefine vector
Figure 171756DEST_PATH_IMAGE018
,
Figure 951494DEST_PATH_IMAGE019
,
Figure 284386DEST_PATH_IMAGE020
,
Figure 98758DEST_PATH_IMAGE021
vector is CA,
Figure 921221DEST_PATH_IMAGE019
vector is CB,
Figure 188254DEST_PATH_IMAGE020
vector is CD, establishes variable ;
If
Figure 993716DEST_PATH_IMAGE023
value be all less than or equal to 0, intersect with straight sides.
Further, in determining step, judge the step of this line segment and curve intersection:
Step (221): calculate each parameter of curve, the home position that the curve of take is circular arc, and radius is r.
Step (222): establishing this line segment two-end-point is A, B, institute's intersection curve side two-end-point is made as C, D, obtains ABCD tetra-point coordinate, A (
Figure 177627DEST_PATH_IMAGE001
,
Figure 180218DEST_PATH_IMAGE002
), B (
Figure 703604DEST_PATH_IMAGE003
, ), C (
Figure 47177DEST_PATH_IMAGE005
, ), D (
Figure 903455DEST_PATH_IMAGE007
,
Figure 504201DEST_PATH_IMAGE008
); If the tangent slope at line segment AB and intersections of complex curve place is
Figure 967543DEST_PATH_IMAGE025
if, k
Figure 311937DEST_PATH_IMAGE026
=-1,
Figure 482018DEST_PATH_IMAGE027
or , return to step and determine door and window position, setting-out section again; The center of circle to A point line segment is
Figure 204303DEST_PATH_IMAGE029
, the center of circle to B point line segment is , connecting the center of circle is two radiuses to C, D two-end-point, and central angle is theta, and C, 2 of D intersect at an E as tangent line excessively, and the center of circle is made as to E point line segment , draw respectively
Figure 818059DEST_PATH_IMAGE029
,
Figure 255994DEST_PATH_IMAGE030
length, and
Figure 879873DEST_PATH_IMAGE029
,
Figure 86863DEST_PATH_IMAGE030
,
Figure 200313DEST_PATH_IMAGE031
slope
Figure 125544DEST_PATH_IMAGE032
, , k, and
Figure 614611DEST_PATH_IMAGE029
with
Figure 633382DEST_PATH_IMAGE031
,
Figure 983592DEST_PATH_IMAGE030
with
Figure 11591DEST_PATH_IMAGE031
angle
Figure 193174DEST_PATH_IMAGE034
,
Figure 648426DEST_PATH_IMAGE035
;
Figure 718888DEST_PATH_IMAGE036
Figure 284998DEST_PATH_IMAGE037
Step (223): if >r,
Figure 150503DEST_PATH_IMAGE030
<r, and
Figure 272043DEST_PATH_IMAGE034
,
Figure 641845DEST_PATH_IMAGE035
all be less than theta/2, with curve intersection;
If
Figure 798019DEST_PATH_IMAGE029
<r,
Figure 470440DEST_PATH_IMAGE030
>r, and
Figure 79276DEST_PATH_IMAGE034
,
Figure 987189DEST_PATH_IMAGE035
all be less than theta/2, with curve intersection;
If
Figure 997871DEST_PATH_IMAGE029
=r,
Figure 402045DEST_PATH_IMAGE030
=r, line segment and curve intersection are in 2 points.
Further, in calculation procedure, while intersecting with straight line, calculate rectangle four apex coordinate steps:
Take line segment AB as diagonal line, utilize ABCD tetra-point coordinate calculate other two apex coordinates of drawn rectangle (
Figure 435860DEST_PATH_IMAGE038
,
Figure 147464DEST_PATH_IMAGE039
) and (
Figure 12652DEST_PATH_IMAGE040
,
Figure 151509DEST_PATH_IMAGE041
);
Figure 187915DEST_PATH_IMAGE043
Figure 907610DEST_PATH_IMAGE044
Figure 155051DEST_PATH_IMAGE045
Further, in calculation procedure, when some, calculate rectangle four apex coordinate steps with curve intersection:
Obtain
Figure 225776DEST_PATH_IMAGE029
with
Figure 279182DEST_PATH_IMAGE030
mean value
Figure 555180DEST_PATH_IMAGE046
, obtain respectively
Figure 35840DEST_PATH_IMAGE029
,
Figure 593861DEST_PATH_IMAGE030
upper apart from distance of center circle from being
Figure 123062DEST_PATH_IMAGE046
point, be designated as respectively M(
Figure 817349DEST_PATH_IMAGE047
,
Figure 734489DEST_PATH_IMAGE048
) and N( ,
Figure 847119DEST_PATH_IMAGE050
).Obtain with (
Figure 661491DEST_PATH_IMAGE051
,
Figure 483953DEST_PATH_IMAGE048
) and (
Figure 688670DEST_PATH_IMAGE052
, ) be the straight slope k of end points, take AB as diagonal line, utilize these ABMN tetra-point coordinate calculate other two apex coordinates of drawn rectangle (
Figure 556449DEST_PATH_IMAGE038
,
Figure 986031DEST_PATH_IMAGE039
) and ( ,
Figure 477372DEST_PATH_IMAGE041
);
Figure 609910DEST_PATH_IMAGE044
Figure 822717DEST_PATH_IMAGE045
Further, in calculation procedure, calculate rectangle four apex coordinate steps in 2 time with curve intersection:
Cross the center of circle and make the perpendicular bisector of line segment AB, hand over curve in a P(
Figure 466188DEST_PATH_IMAGE053
,
Figure 801354DEST_PATH_IMAGE054
), cross the tangent line that P point is made circle, point of contact is for drawing the mid point on other two summits of rectangle, and the slope of AB line segment place straight line is
Figure 530276DEST_PATH_IMAGE055
, establishing other 2 of rectangle is M(
Figure 546773DEST_PATH_IMAGE047
,
Figure 44751DEST_PATH_IMAGE048
) and N(
Figure 816398DEST_PATH_IMAGE052
,
Figure 203254DEST_PATH_IMAGE050
), calculate two point coordinate formula and be:
Figure 85760DEST_PATH_IMAGE056
Figure 438244DEST_PATH_IMAGE057
Figure 318475DEST_PATH_IMAGE058
Figure 756409DEST_PATH_IMAGE059
Compared with prior art, the present invention has the following advantages: with respect to existing picture technology, can determine door and window position and draw the rectangle that represents door and window by only drawing a line segment, a lot of unnecessary repeating steps have been saved, save time, raise the efficiency, be very easily a kind of on plane room figure the scheme of Fast Drawing door and window, and can realize on straight line and curve and all along straight line or direction of curve, automatically generate door and window figure, experimental results show that, this scheme can be to realize, and has obtained good effect.
Accompanying drawing explanation
The one-piece construction block diagram of Fig. 1 simple and easy door and window of Fast Drawing on plane room figure;
Fig. 2 judges first step mathematics geometric figure when whether line segment intersects with straight line;
Fig. 3 judges second step mathematics geometric figure when whether line segment intersects with straight line;
Fig. 4 for judge line segment whether with the crossing flow chart of steps of straight line;
Fig. 5 is mathematics geometric figure when judging line segment whether with curve intersection;
Fig. 6 is the flow chart of steps judging whether with curve intersection;
Fig. 7 is that line segment and straight line calculate rectangle four point coordinate step course diagrams while intersecting;
Fig. 8 calculates rectangle four point coordinate flow chart of steps while being line segment and curve intersection;
Fig. 9 is that line segment and curve intersection calculate the flow chart of steps of four point coordinate in the time of 2;
Figure 10 to Figure 14 is the process demonstration graph of the simple and easy door and window of Fast Drawing on plane room figure.
Embodiment
Below in conjunction with accompanying drawing, describe the present invention, the description of this part is only exemplary and explanatory, should not have any restriction to protection scope of the present invention.
Fig. 1 is the process flow diagram of an embodiment of the invention, comprises the following steps:
Step (1): determine the position that will draw door and window on the straight line of plane room figure or curve, go out a line segment and straight line or curve intersection in door and window position by mouse drag, represent the position of door and window on straight line or curve with this line segment.
Step (21): judge whether this line segment intersects with straight line.
Step (22): judge this line segment whether with curve intersection.
Step (3): calculate four point coordinate that will draw rectangle.
Step (4): according to four apex coordinates of the rectangle calculating, take current line segment as diagonal line, connect four some structure rectangles with the lineTo () function in canvas, complete the drafting of simple and easy door and window.
Fig. 4 describes the detailed process of step in Fig. 1 (21) in detail:
Step (211): current line segment two-end-point is made as A, B, institute's intersecting straight lines two-end-point is made as C, D, obtains ABCD tetra-point coordinate, A (
Figure 177027DEST_PATH_IMAGE001
,
Figure 649596DEST_PATH_IMAGE002
), B (
Figure 700729DEST_PATH_IMAGE003
,
Figure 625959DEST_PATH_IMAGE004
), C (
Figure 850267DEST_PATH_IMAGE005
,
Figure 911764DEST_PATH_IMAGE006
), D (
Figure 133798DEST_PATH_IMAGE007
,
Figure 546325DEST_PATH_IMAGE008
), obtain CD line segment slope k, AB line segment slope
Figure 574324DEST_PATH_IMAGE012
, establish
Figure 192125DEST_PATH_IMAGE013
, if, , illustrating that drawn line segment length exceeds former line segment length, abnormal conditions prompting repaints.If k
Figure 847731DEST_PATH_IMAGE016
=-1, illustrate that drawn line segment is vertical with former line segment, abnormal conditions prompting repaints.Otherwise, at AC point-to-point transmission structure vector
Figure 87083DEST_PATH_IMAGE060
, AD point-to-point transmission structure vector
Figure 447657DEST_PATH_IMAGE061
, AB point-to-point transmission structure vector , by A point, set out, point to BCD point.Obtain CD line segment slope k, establish variable
Figure 142260DEST_PATH_IMAGE017
, as shown in Figure 2.
Step (212): redefine vector
Figure 32856DEST_PATH_IMAGE018
,
Figure 829911DEST_PATH_IMAGE019
,
Figure 438747DEST_PATH_IMAGE020
, vector is CA,
Figure 560603DEST_PATH_IMAGE019
vector is CB,
Figure 528559DEST_PATH_IMAGE020
vector is CD, establishes variable
Figure 84347DEST_PATH_IMAGE022
, as shown in Figure 3.If
Figure 795951DEST_PATH_IMAGE023
Figure 661139DEST_PATH_IMAGE062
value be all less than or equal to 0, intersect execution step (31) with straight line.Otherwise, execution step (22).
Fig. 6 describes the detailed process of step in Fig. 1 (22) in detail:
Step (221): obtain each parameter of curve, the home position that the curve of take is circular arc, and radius is r.
Step (222): establishing current line segment two-end-point is A, B, AB line segment slope
Figure 799996DEST_PATH_IMAGE063
if
Figure 321107DEST_PATH_IMAGE027
or have a condition to set up, abnormal conditions prompting repaints.If line segment AB and intersections of complex curve are E, the curve tangent slope that E is ordered is excessively
Figure 556097DEST_PATH_IMAGE025
if, k
Figure 803538DEST_PATH_IMAGE026
=-1, illustrate that this tangent line of drawn line segment and curve is vertical, abnormal conditions prompting repaints.Otherwise, establish the center of circle and to A point line segment be , the center of circle to B point line segment is , connecting the center of circle is two radiuses to C, D two-end-point, and central angle is theta, and C, 2 of D intersect at an E as tangent line excessively, and the center of circle is made as to E point line segment
Figure 767449DEST_PATH_IMAGE031
, as shown in Figure 5, obtain respectively
Figure 185792DEST_PATH_IMAGE029
, length, and
Figure 335331DEST_PATH_IMAGE029
,
Figure 465836DEST_PATH_IMAGE030
,
Figure 117397DEST_PATH_IMAGE031
slope ,
Figure 557923DEST_PATH_IMAGE033
, k, and with
Figure 132440DEST_PATH_IMAGE031
,
Figure 399474DEST_PATH_IMAGE030
with
Figure 536057DEST_PATH_IMAGE031
angle
Figure 939357DEST_PATH_IMAGE034
,
Figure 198300DEST_PATH_IMAGE035
.
Figure 952629DEST_PATH_IMAGE036
Figure 627324DEST_PATH_IMAGE037
Step (223): if
Figure 150709DEST_PATH_IMAGE029
>r, <r, and ,
Figure 533521DEST_PATH_IMAGE035
all be less than theta/2, with curve intersection, execution step (32).
If <r,
Figure 512158DEST_PATH_IMAGE030
>r, and
Figure 178763DEST_PATH_IMAGE034
,
Figure 257577DEST_PATH_IMAGE035
all be less than theta/2, with curve intersection, execution step (32).
If
Figure 755555DEST_PATH_IMAGE029
=r,
Figure 199305DEST_PATH_IMAGE030
=r, line segment and curve intersection, in 2 points, perform step (33).
Fig. 7 describes the detailed process of step (31) in detail:
Take line segment AB as diagonal line, utilize ABCD tetra-point coordinate calculate other two apex coordinates of drawn rectangle ( ,
Figure 298028DEST_PATH_IMAGE039
) and ( ,
Figure 530744DEST_PATH_IMAGE041
).
Figure 968678DEST_PATH_IMAGE042
Figure 389295DEST_PATH_IMAGE043
Figure 861865DEST_PATH_IMAGE044
Figure 145954DEST_PATH_IMAGE045
Fig. 8 describes the detailed process of step (32) in detail:
Obtain
Figure 71184DEST_PATH_IMAGE029
with
Figure 295492DEST_PATH_IMAGE030
mean value
Figure 560251DEST_PATH_IMAGE046
, obtain respectively
Figure 844602DEST_PATH_IMAGE029
,
Figure 257129DEST_PATH_IMAGE030
upper apart from distance of center circle from being
Figure 19549DEST_PATH_IMAGE046
point, be designated as respectively M(
Figure 138814DEST_PATH_IMAGE047
,
Figure 594067DEST_PATH_IMAGE048
) and N(
Figure 493889DEST_PATH_IMAGE049
,
Figure 997683DEST_PATH_IMAGE050
).Obtain with (
Figure 33772DEST_PATH_IMAGE051
,
Figure 659926DEST_PATH_IMAGE048
) and (
Figure 483263DEST_PATH_IMAGE052
,
Figure 587485DEST_PATH_IMAGE050
) be the straight slope k of end points, take AB as diagonal line, utilize these ABMN tetra-point coordinate calculate other two apex coordinates of drawn rectangle (
Figure 743660DEST_PATH_IMAGE038
,
Figure 540715DEST_PATH_IMAGE039
) and (
Figure 87234DEST_PATH_IMAGE040
,
Figure 260726DEST_PATH_IMAGE041
).
Figure 271407DEST_PATH_IMAGE042
Figure 177046DEST_PATH_IMAGE043
Figure 719203DEST_PATH_IMAGE045
Fig. 9 describes the detailed process of step (33) in detail:
Cross the center of circle and make the perpendicular bisector of line segment AB, hand over curve in a P(
Figure 849970DEST_PATH_IMAGE053
, ), cross the tangent line that P point is made circle, point of contact is for drawing the mid point on other two summits of rectangle, and the slope of AB line segment place straight line is , establishing other 2 of rectangle is M(
Figure 759655DEST_PATH_IMAGE047
,
Figure 181146DEST_PATH_IMAGE048
) and N(
Figure 490905DEST_PATH_IMAGE052
,
Figure 561629DEST_PATH_IMAGE050
), calculate two point coordinate formula and be:
Figure 552719DEST_PATH_IMAGE056
Figure 392499DEST_PATH_IMAGE057
Figure 873159DEST_PATH_IMAGE058
Figure 165600DEST_PATH_IMAGE059
Figure 10 to Figure 14 is the process demonstration graph of the simple and easy door and window of Fast Drawing on plane room figure, and it specifically represents that implication is:
Figure 10 is simple and easy two dimensional surface room figure.
Figure 11 is that setting-out section is determined door and window position on plane room figure cathetus.
Figure 12 is design sketch after Fast Drawing door and window on straight line.
Figure 13 in plane room figure on curve setting-out section determine door and window position.
Figure 14 is design sketch after Fast Drawing door and window on curve.
By the description of above embodiment, one of ordinary skill in the art can clearly understand implementation procedure of the present invention, and can experimental results show that repeatability of the present invention according to above-mentioned steps, the present invention be a kind of on straight line or curve the scheme of Fast Drawing door and window, propose and existing method for drafting different solution all.
Above-described embodiment of the present invention, does not form the restriction to invention protection domain.Any modification of doing within the spirit and principles in the present invention, be equal to and replace and improvement etc., within all should being included in protection scope of the present invention.

Claims (6)

1. a method for Fast Drawing door and window on plane room figure, comprises the following steps:
(1) determine door and window position: in the straight sides of plane room figure or curvilinear sides, determine the position that will draw door and window, all, arrange that door and window position draws a line segment and straight sides or curvilinear sides intersects, with this line segment, represent the position of door and window in straight sides or curvilinear sides;
(2) determining step: judge that one by one drawn line segment and straight sides or curvilinear sides intersect situation;
(3) calculation procedure: take line segment as diagonal line, calculate four point coordinate that will draw rectangle, wherein one side of this rectangle is parallel with straight sides, or parallel with the tangent line of curvilinear sides intersection with this line segment;
(4) plot step: according to four apex coordinates of the rectangle calculating, take current line segment as diagonal line, connect four some structure rectangles, complete the drafting of simple and easy door and window.
2. the method for claim 1, is characterized in that: in determining step, judge the step that this line segment and straight line are crossing:
Step (211): this line segment two-end-point is made as A, B, institute's intersecting straight lines side two-end-point is made as C, D, obtains ABCD tetra-point coordinate, A (
Figure 2013105174861100001DEST_PATH_IMAGE001
,
Figure 2013105174861100001DEST_PATH_IMAGE002
), B (
Figure 2013105174861100001DEST_PATH_IMAGE003
,
Figure 2013105174861100001DEST_PATH_IMAGE004
), C (
Figure 2013105174861100001DEST_PATH_IMAGE005
,
Figure 2013105174861100001DEST_PATH_IMAGE006
), D (
Figure 2013105174861100001DEST_PATH_IMAGE007
,
Figure 2013105174861100001DEST_PATH_IMAGE008
), at AC point-to-point transmission structure vector
Figure 2013105174861100001DEST_PATH_IMAGE009
, AD point-to-point transmission structure vector
Figure 2013105174861100001DEST_PATH_IMAGE010
, AB point-to-point transmission structure vector
Figure 2013105174861100001DEST_PATH_IMAGE011
, by A point, set out, point to BCD point; Obtain CD line segment slope k, AB line segment slope
Figure 2013105174861100001DEST_PATH_IMAGE012
, establish
Figure 2013105174861100001DEST_PATH_IMAGE013
,
Figure 2013105174861100001DEST_PATH_IMAGE014
if, or k
Figure 2013105174861100001DEST_PATH_IMAGE016
=-1, return to step and determine door and window position, setting-out section again; If variable
Figure 2013105174861100001DEST_PATH_IMAGE017
;
Step (212): redefine vector
Figure 240201DEST_PATH_IMAGE009
,
Figure 635411DEST_PATH_IMAGE010
, ,
Figure 2013105174861100001DEST_PATH_IMAGE019
vector is CA,
Figure 118957DEST_PATH_IMAGE010
vector is CB,
Figure 206999DEST_PATH_IMAGE018
vector is CD, establishes variable
Figure 2013105174861100001DEST_PATH_IMAGE020
;
If
Figure 2013105174861100001DEST_PATH_IMAGE021
value be all less than or equal to 0, intersect with straight sides.
3. the method for claim 1, is characterized in that: in determining step, judge the step of this line segment and curve intersection:
Step (221): calculate each parameter of curve, the home position that the curve of take is circular arc, and radius is r;
Step (222): establishing this line segment two-end-point is A, B, institute's intersection curve side two-end-point is made as C, D, obtains ABCD tetra-point coordinate, A ( ,
Figure 282719DEST_PATH_IMAGE002
), B (
Figure 951598DEST_PATH_IMAGE003
,
Figure 210541DEST_PATH_IMAGE004
), C ( ,
Figure 639565DEST_PATH_IMAGE006
), D ( ,
Figure 327216DEST_PATH_IMAGE008
); If the tangent slope at line segment AB and intersections of complex curve place is if, k
Figure DEST_PATH_IMAGE024
=-1,
Figure 2013105174861100001DEST_PATH_IMAGE025
or
Figure DEST_PATH_IMAGE026
, return to step and determine door and window position, setting-out section again; The center of circle to A point line segment is
Figure 2013105174861100001DEST_PATH_IMAGE027
, the center of circle to B point line segment is
Figure DEST_PATH_IMAGE028
, connecting the center of circle is two radiuses to C, D two-end-point, and central angle is theta, and C, 2 of D intersect at an E as tangent line excessively, and the center of circle is made as to E point line segment
Figure 2013105174861100001DEST_PATH_IMAGE029
, draw respectively
Figure 444207DEST_PATH_IMAGE027
,
Figure 922593DEST_PATH_IMAGE028
length, and
Figure 300485DEST_PATH_IMAGE027
, ,
Figure 364573DEST_PATH_IMAGE029
slope , , k, and
Figure 646650DEST_PATH_IMAGE027
with , with
Figure 801666DEST_PATH_IMAGE029
angle ,
Figure 2013105174861100001DEST_PATH_IMAGE033
;
Figure DEST_PATH_IMAGE034
Figure 2013105174861100001DEST_PATH_IMAGE035
Step (223): if
Figure 621854DEST_PATH_IMAGE027
>r,
Figure 912021DEST_PATH_IMAGE028
<r, and
Figure 588990DEST_PATH_IMAGE032
,
Figure 26925DEST_PATH_IMAGE033
all be less than theta/2, with curve intersection;
If <r,
Figure 857795DEST_PATH_IMAGE028
>r, and
Figure 971244DEST_PATH_IMAGE032
,
Figure 896475DEST_PATH_IMAGE033
all be less than theta/2, with curve intersection;
If
Figure 58466DEST_PATH_IMAGE027
=r,
Figure DEST_PATH_IMAGE036
=r, line segment and curve intersection are in 2 points.
4. method as claimed in claim 2, is characterized in that: in calculation procedure, calculate rectangle four apex coordinate steps while intersecting with straight line:
Take line segment AB as diagonal line, utilize ABCD tetra-point coordinate calculate other two apex coordinates of drawn rectangle (
Figure 2013105174861100001DEST_PATH_IMAGE037
,
Figure DEST_PATH_IMAGE038
) and (
Figure DEST_PATH_IMAGE039
,
Figure DEST_PATH_IMAGE040
);
Figure DEST_PATH_IMAGE041
Figure DEST_PATH_IMAGE042
Figure DEST_PATH_IMAGE043
Figure DEST_PATH_IMAGE044
5. method as claimed in claim 3, is characterized in that: in calculation procedure, calculate rectangle four apex coordinate steps with curve intersection when a bit:
Obtain
Figure 198591DEST_PATH_IMAGE027
with
Figure 482942DEST_PATH_IMAGE036
mean value
Figure DEST_PATH_IMAGE045
, obtain respectively
Figure 564643DEST_PATH_IMAGE027
,
Figure 592642DEST_PATH_IMAGE036
upper apart from distance of center circle from being point, be designated as respectively M(
Figure DEST_PATH_IMAGE047
,
Figure DEST_PATH_IMAGE048
) and N(
Figure DEST_PATH_IMAGE049
,
Figure DEST_PATH_IMAGE050
); Obtain with (
Figure DEST_PATH_IMAGE051
,
Figure 649591DEST_PATH_IMAGE048
) and (
Figure DEST_PATH_IMAGE052
,
Figure 42526DEST_PATH_IMAGE050
) be the straight slope k of end points, take AB as diagonal line, utilize these ABMN tetra-point coordinate calculate other two apex coordinates of drawn rectangle ( ,
Figure 446143DEST_PATH_IMAGE038
) and (
Figure 482232DEST_PATH_IMAGE039
,
Figure 108385DEST_PATH_IMAGE040
);
Figure DEST_PATH_IMAGE053
Figure DEST_PATH_IMAGE054
Figure 537410DEST_PATH_IMAGE044
6. method as claimed in claim 3, is characterized in that: in calculation procedure, calculate rectangle four apex coordinate steps with curve intersection in 2 time:
Cross the center of circle and make the perpendicular bisector of line segment AB, hand over curve in a P( ,
Figure DEST_PATH_IMAGE056
), cross the tangent line that P point is made circle, point of contact is for drawing the mid point on other two summits of rectangle, and the slope of AB line segment place straight line is , establishing other 2 of rectangle is M(
Figure 568951DEST_PATH_IMAGE047
, ) and N(
Figure DEST_PATH_IMAGE058
,
Figure 933032DEST_PATH_IMAGE050
), calculate two point coordinate formula and be:
Figure DEST_PATH_IMAGE059
Figure DEST_PATH_IMAGE060
Figure DEST_PATH_IMAGE061
CN201310517486.1A 2013-10-29 2013-10-29 Plane room graph is drawn the method for door and window fast Expired - Fee Related CN103544720B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310517486.1A CN103544720B (en) 2013-10-29 2013-10-29 Plane room graph is drawn the method for door and window fast

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310517486.1A CN103544720B (en) 2013-10-29 2013-10-29 Plane room graph is drawn the method for door and window fast

Publications (2)

Publication Number Publication Date
CN103544720A true CN103544720A (en) 2014-01-29
CN103544720B CN103544720B (en) 2016-06-01

Family

ID=49968138

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310517486.1A Expired - Fee Related CN103544720B (en) 2013-10-29 2013-10-29 Plane room graph is drawn the method for door and window fast

Country Status (1)

Country Link
CN (1) CN103544720B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109271704A (en) * 2018-09-12 2019-01-25 深圳市彬讯科技有限公司 CAD house type forms recognition methods and CAD house type forms identification device
CN111639150A (en) * 2020-06-02 2020-09-08 中国人民解放军陆军装甲兵学院 Method and system for displaying details of electronic map enlarged area

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20060080350A (en) * 2005-01-05 2006-07-10 엘지전자 주식회사 Method of drawing shape based on mobile device
CN101408988A (en) * 2008-11-07 2009-04-15 武汉虹信通信技术有限责任公司 Method for drafting expandable line
CN101719057A (en) * 2009-11-27 2010-06-02 广东威创视讯科技股份有限公司 Method and device for drawing geometric figures

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20060080350A (en) * 2005-01-05 2006-07-10 엘지전자 주식회사 Method of drawing shape based on mobile device
CN101408988A (en) * 2008-11-07 2009-04-15 武汉虹信通信技术有限责任公司 Method for drafting expandable line
CN101719057A (en) * 2009-11-27 2010-06-02 广东威创视讯科技股份有限公司 Method and device for drawing geometric figures

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
石林祥: "建筑门窗CAD系统关键技术的研究", 《山西煤炭管理干部学院学报》, 31 December 2011 (2011-12-31), pages 35 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109271704A (en) * 2018-09-12 2019-01-25 深圳市彬讯科技有限公司 CAD house type forms recognition methods and CAD house type forms identification device
CN109271704B (en) * 2018-09-12 2022-12-30 深圳市彬讯科技有限公司 CAD house type window body identification method and CAD house type window body identification device
CN111639150A (en) * 2020-06-02 2020-09-08 中国人民解放军陆军装甲兵学院 Method and system for displaying details of electronic map enlarged area
CN111639150B (en) * 2020-06-02 2023-09-19 中国人民解放军陆军装甲兵学院 Electronic map enlarged region detail display method and system

Also Published As

Publication number Publication date
CN103544720B (en) 2016-06-01

Similar Documents

Publication Publication Date Title
CN103544728B (en) A kind of based on normal vector in live-action map by spy face filter method
CN104898947B (en) A kind of method that GDI electronics map vector scaling and translation are realized based on mouse position
CN107544506B (en) Robot following method, robot, and storage medium
CN107085865B (en) Quadrilateral segmentation method applied to finite element analysis
CN101877736A (en) Automatic adjusting system and method for user interface of mobile terminal
CN106845037B (en) A kind of general method for solving of inverse kinematics of five degree of freedom serial manipulator
CN103236077B (en) The three-dimensional model line method for drafting that a kind of feature strengthens
CN112365572B (en) Rendering method based on surface subdivision and related products thereof
CN104574505A (en) Automatic three-dimensional pipeline communication modeling method
CN103544720A (en) Method for rapidly drawing doors and windows on plane room graph
CN103885571A (en) Information processing method and electronic equipment
WO2018103227A1 (en) Method and device for drawing symmetrical figure
CN102663805A (en) Projection-based view frustum cutting method
CN103489221B (en) Quadrilateral mesh conformal Parameterization method
CN103310409B (en) A kind of Tile-based renders the fast triangle block method of framework GPU
WO2023217032A1 (en) Robot collision detection method, storage medium and electronic device
CN106896966A (en) Contact position and the method and apparatus of shape information storage in infrared touch panel
CN106095158A (en) The system that the computational methods of light target displacement vector, device and control cursor move
CN106874919A (en) A kind of method and apparatus for determining ship hull plate angle point
CN113836674A (en) Pipeline segment three-dimensional space interference detection and shortest distance point acquisition algorithm
CN104731492B (en) A kind of magic pen and its display control method
CN106965183A (en) A kind of robot control system and its method of work that mechanism is perceived based on the depth of field
Yang et al. On the normal vector estimation for point cloud data from smooth surfaces.
JP2022095121A5 (en)
CN107633543A (en) Consider the stripe shape corresponding method of local topology

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20160601

Termination date: 20171029