Arc Function

Microchip Graphics Library

Microchip Graphics Library
Arc Function
C
WORD Arc(
    SHORT xL, 
    SHORT yT, 
    SHORT xR, 
    SHORT yB, 
    SHORT r1, 
    SHORT r2, 
    BYTE octant
);
Overview

Draws the octant arc of the beveled figure with the given centers, radii and octant mask. When octant = 0xFF and the following are true:

  1. xL = xR, yT = yB , r1 = 0 and r2 = z, a filled circle is drawn with a radius of z.
  2. radii have values (where r1 < r2), a full ring with thickness of (r2-r1) is drawn.
  3. xL != xR, yT != yB , r1 = 0 and r2 = 0 (where xR > xL and yB > yT) a rectangle is drawn. xL, yT specifies the left top corner and xR, yB specifies the right bottom corner.
When octant != 0xFF the figure drawn is the subsection of the 8 section figure where each non-zero bit of the octant value specifies the octants that will be drawn.

Description

Input Parameters
Input Parameters 
Description 
SHORT xL 
x location of the upper left center in the x,y coordinate. 
SHORT yT 
y location of the upper left center in the x,y coordinate. 
SHORT xR 
x location of the lower right center in the x,y coordinate. 
SHORT yB 
y location of the lower right center in the x,y coordinate. 
SHORT r1 
The smaller radius of the two concentric cicles that defines the thickness of the object. 
SHORT r2 
The larger of radius the two concentric circles that defines the thickness of the object. 
BYTE octant 
Bitmask of the octant that will be drawn. Moving in a clockwise direction from x = 0, y = +radius
  • bit0 : first octant
  • bit1 : second octant
  • bit2 : third octant
  • bit3 : fourth octant
  • bit4 : fifth octant
  • bit5 : sixth octant
  • bit6 : seventh octant
  • bit7 : eight octant
 
Returns

Returns the rendering status. 1 - If the rendering was completed and 0 - If the rendering is not yet finished.

Preconditions

none

Side Effects

none

Microchip Graphics Library Version 3.06.02 - October 15, 2012
Copyright © 2012 Microchip Technology, Inc.  All rights reserved