#include <brushref.h>
Public Member Functions | |
BlendPathOffset () | |
BlendPathOffset (MILLIPOINT X, MILLIPOINT Y) | |
void | CalculateAngleAndMagnitude () |
takes the x and y offset members and calculates the angle and magnitude of that vector | |
void | GetAngleAndMagnitude (double *pAngle, MILLIPOINT *pMagnitude) |
to get the angle and magnitude of this vector | |
void | RotateByAngle (double Angle, MILLIPOINT *pXoffset, MILLIPOINT *pYOffset) |
to find out the x and y offset values if this blendpathoffset were to be rotated by the given angle | |
Public Attributes | |
MILLIPOINT | m_XOffset |
MILLIPOINT | m_YOffset |
Protected Attributes | |
double | m_Angle |
MILLIPOINT | m_Magnitude |
Definition at line 119 of file brushref.h.
|
Definition at line 122 of file brushref.h. 00122 {m_XOffset = 0; m_YOffset = 0; m_Angle = 0; m_Magnitude = 0;}
|
|
Definition at line 123 of file brushref.h. 00123 {m_XOffset = X; m_YOffset = Y; 00124 CalculateAngleAndMagnitude();}
|
|
takes the x and y offset members and calculates the angle and magnitude of that vector
Definition at line 141 of file brushref.cpp. 00142 { 00143 MILLIPOINT Xsq = m_XOffset * m_XOffset; 00144 MILLIPOINT Ysq = m_YOffset * m_YOffset; 00145 double Hypotenuse = sqrt((double)Xsq + (double)Ysq); 00146 double Calc = ((double)m_XOffset / Hypotenuse); 00147 double RadAngle = acos(Calc); 00148 // double DegAngle = RadAngle * (180 / PI); 00149 00150 m_Angle = RadAngle; 00151 m_Magnitude = (MILLIPOINT)Hypotenuse; 00152 }
|
|
to get the angle and magnitude of this vector
Definition at line 169 of file brushref.cpp. 00170 { 00171 *pAngle = m_Angle; 00172 *pMagnitude = m_Magnitude; 00173 }
|
|
to find out the x and y offset values if this blendpathoffset were to be rotated by the given angle
Definition at line 191 of file brushref.cpp. 00192 { 00193 double NewAngle = m_Angle + Angle; 00194 00195 *pXOffset = (MILLIPOINT)(m_Magnitude * cos(NewAngle)); 00196 *pYOffset = (MILLIPOINT)(m_Magnitude * sin(NewAngle)); 00197 }
|
|
Definition at line 140 of file brushref.h. |
|
Definition at line 141 of file brushref.h. |
|
Definition at line 135 of file brushref.h. |
|
Definition at line 136 of file brushref.h. |