Leaper Vision Toolkit
中文 / English 2.x
Public 成员函数 | 属性
ILEllipse接口 参考

该接口对应一个椭圆(LEllipse对象) 更多...

类 ILEllipse 继承关系图:
ILObject LEllipse

Public 成员函数

void Draw (BOOL bFill, HDC hdc, double zoomX, double zoomY, double panX, double panY)
 
void FromEllipseRegion (ILEllipseRegion *val)
 
double GetArea ()
 
ILPointGetBottom ()
 
ILRectGetBoundingRect ()
 
ILRectGetBoundingRotRect ()
 
ILPointGetCenter ()
 
ILPointGetLeft ()
 
double GetPerimeter ()
 
ILPointGetRight ()
 
ILPointGetTop ()
 
ILPolygonResample (int num)
 
ILPolygonSamplingByAngle (double startArcAngle, double endArcAngle, double stepAngle)
 
void Set (double x, double y, double w, double h, double a)
 
ILEllipseRegionToEllipseRegion ()
 
ILEllipseTransform (ILTransform *tf)
 
ILEllipseTranslate (double offsetX, double offsetY)
 
- Public 成员函数 继承自 ILObject
ILObjectCopy ()
 
LPVErrorCode Load (LString filename)
 
void Reset ()
 
LPVErrorCode Save (LString filename)
 
BOOL Valid ()
 

属性

double Angle [get, set]
 该椭圆的旋转角度,即主轴方向
 
double Height [get, set]
 该椭圆的高度(短轴长度)
 
double Width [get, set]
 该椭圆的宽度(主轴长度)
 
double X [get, set]
 该椭圆中心点的 x 坐标
 
double Y [get, set]
 该椭圆中心点的 y 坐标
 

详细描述

该接口对应一个椭圆(LEllipse对象)

成员函数说明

◆ Draw()

void Draw ( BOOL  bFill,
HDC  hdc,
double  zoomX,
double  zoomY,
double  panX,
double  panY 
)

绘制椭圆到给定的设备上

参数
[in]bFill是否填充
参见
Use Draw Functions
备注
该函数在 Linux / MacOS 平台暂不可用。

◆ FromEllipseRegion()

void FromEllipseRegion ( ILEllipseRegion val)

根据输入的椭圆区域对象,设置该椭圆的位置、尺寸和角度

◆ GetArea()

double GetArea ( )

获取椭圆的面积

返回值
val返回椭圆的面积

◆ GetBottom()

ILPoint* GetBottom ( )

获取椭圆短轴上的下方端点

◆ GetBoundingRect()

ILRect* GetBoundingRect ( )

计算椭圆的包围矩形

◆ GetBoundingRotRect()

ILRect* GetBoundingRotRect ( )

计算椭圆的包围旋转矩形

◆ GetCenter()

ILPoint* GetCenter ( )

获取椭圆中心所在的点。

◆ GetLeft()

ILPoint* GetLeft ( )

获取椭圆长轴上的左方端点

◆ GetPerimeter()

double GetPerimeter ( )

获取椭圆的周长,基于 Ramanujan 公式

返回值
val返回椭圆的周长

◆ GetRight()

ILPoint* GetRight ( )

获取椭圆长轴上的右方端点

◆ GetTop()

ILPoint* GetTop ( )

获取椭圆短轴上的上方端点

◆ Resample()

ILPolygon* Resample ( int  num)

沿该椭圆形采样,生成一个指定顶点数量的闭合多边形。

参数
[in]num采样顶点数量,最少为 3
返回值
result返回采样得到的结果多边形

◆ SamplingByAngle()

ILPolygon* SamplingByAngle ( double  startArcAngle,
double  endArcAngle,
double  stepAngle 
)

按角度采样椭圆上的点,生成一个多边形。多边形的点通过指定的开始和结束角度,沿顺时针方向生成,每个固定步长角度生成一个点。

参数
[in]startArcAngle采样开始角度
[in]endArcAngle采样结束角度
[in]stepAngle采样角度步长
返回值
result返回生成的结果多边形

◆ Set()

void Set ( double  x,
double  y,
double  w,
double  h,
double  a 
)

设置该椭圆的位置和尺寸

参数
[in]x椭圆中心点的 x 坐标
[in]y椭圆中心点的 x 坐标
[in]w椭圆的宽度(主轴长度)
[in]h椭圆的高度(短轴长度)
[in]a椭圆的角度(主轴方向)

◆ ToEllipseRegion()

ILEllipseRegion* ToEllipseRegion ( )

根据当前椭圆,生成一个椭圆区域对象。

返回值
val返回生成的椭圆区域对象

◆ Transform()

ILEllipse* Transform ( ILTransform tf)

应用指定的变换矩阵到当前椭圆,得到一个新的椭圆

参数
[in]tf变换矩阵
返回值
返回新的椭圆

◆ Translate()

ILEllipse* Translate ( double  offsetX,
double  offsetY 
)

平移当前椭圆,生成一个新的椭圆

参数
[in]offsetXx 方向的平移量
[in]offsetYy 方向的平移量
返回值
result返回新的椭圆