Differences
This shows you the differences between two versions of the page.
en:software:qview:qview_6:qcl_library:vi10addarcbetweenangles [2017/03/21 16:15] – created qem103 | en:software:qview:qview_6:qcl_library:vi10addarcbetweenangles [2019/08/29 17:01] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== VI10AddArcBetweenAngles ====== | ||
+ | |||
+ | **V = **// | ||
+ | |||
+ | **I = **//Image// | ||
+ | |||
+ | Function that is used to manage the Vector Image feature (object that resides on some Qpaint versions). | ||
+ | |||
+ | The VI10AddArcBetweenAngles function __adds, queued instructions to be processed into the Buffer to perform the drawing, a set of instructions to draw an arc whose route goes from point A to point B in a circle whose X-Y coordinates are passed of the center of the radius__.\\ Point A and point B are not expressed with X-Y coordinates but with circumferential corners.\\ | ||
+ | The X and Y coordinates of the B point (calculated within the function) it also set, at end of statement, as current coordinates. | ||
+ | |||
+ | |Buffer| | ||
+ | |{{: | ||
+ | |||
+ | ===== IMPLEMENTATION ===== | ||
+ | |||
+ | **VI10AddArcBetweenAngles (awBuffer, Centre_Xo, Centre_Yo, Angle_A, Angle_B, Radius)** | ||
+ | |||
+ | Parameters: | ||
+ | |||
+ | ^IN/ | ||
+ | | IN | ARRSYS /\\ ARRGBL | ||
+ | | IN | CONST/\\ GLOBAL | ||
+ | | IN | CONST/\\ GLOBAL | ||
+ | | IN | CONST/\\ GLOBAL | ||
+ | | IN | CONST/\\ GLOBAL | ||
+ | | IN | CONST/\\ GLOBAL | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | //TASK_00// | ||
+ | <code QCL> | ||
+ | MAIN: | ||
+ | |||
+ | VI10InitBuffer (awBuffer) ; | ||
+ | |||
+ | Color = 0 ;Sets black color | ||
+ | |||
+ | VI10AddPen (awBuffer, Color) ; | ||
+ | |||
+ | Coord_X = 0 ;Sets the coordinates for the MOVE | ||
+ | |||
+ | Coord_Y = 70 | ||
+ | |||
+ | VI10AddMove (awBuffer, Coord_X, Coord_Y) ; | ||
+ | |||
+ | Centre_Xo = 0 ;Sets the coordinates of the center circumference | ||
+ | |||
+ | Centre_Yo = 50 | ||
+ | |||
+ | Angle_A = 200 ; | ||
+ | |||
+ | Angle_B = 900 ; | ||
+ | |||
+ | Radius = 20 ; | ||
+ | |||
+ | VI10AddArcBetweenAngles (awBuffer, Centre_Xo, Centre_Yo, Angle_A, Angle_B, Radius) | ||
+ | |||
+ | ;Adds Construction arch with corners | ||
+ | |||
+ | .... | ||
+ | |||
+ | WAIT 1 | ||
+ | JUMP MAIN | ||
+ | |||
+ | END | ||
+ | </ | ||
+ | |||
+ | === Note === | ||
+ | |||
+ | *Considered the pictures below: | ||
+ | |||
+ | {{: | ||
+ | |||
+ | the function trace an arc from point A to point B (expressed as angles) of the unit identified by the X-Y coordinates of the center and the radius is passed to the function. | ||