public class HMatrix extends HObject
| 构造器和说明 |
|---|
HMatrix()
使用默认参数 (1,0,0,1,0,0) 创建新的 HMatrix 对象。
|
HMatrix(double a,
double b,
double c,
double d,
double tx,
double ty)
使用指定参数创建新的 HMatrix 对象。
|
| 限定符和类型 | 方法和说明 |
|---|---|
HMatrix |
clone()
返回一个新的 HMatrix 对象,它是此矩阵的克隆,带有与所含对象完全相同的副本。
|
void |
concat(HMatrix m)
将某个矩阵与当前矩阵连接,从而将这两个矩阵的几何效果有效地结合在一起。
|
void |
createBox(double scaleX,
double scaleY,
double rotation,
double tx,
double ty)
包括用于缩放、旋转和转换的参数。
|
HPoint |
deltaTransformPoint(HPoint point)
如果给定预转换坐标空间中的点,则此方法返回发生转换后该点的坐标。
|
void |
identity()
调用 identity() 方法后,生成的矩阵具有以下属性:a=1、b=0、c=0、d=1、tx=0 和 ty=0。
|
void |
invert()
执行原始矩阵的逆转换。
|
void |
rotate(double angle)
对 HMatrix 对象应用旋转转换。
|
void |
scale(double sx,
double sy)
对矩阵应用缩放转换。
|
java.lang.String |
toString() |
HPoint |
transformPoint(HPoint point)
返回将 HMatrix 对象表示的几何转换应用于指定点所产生的结果。
|
void |
translate(double dx,
double dy)
沿 x 和 y 轴平移矩阵,由 dx 和 dy 参数指定。
|
HRectangle |
transleteRect(HRectangle rect)
返回将 HMatrix 对象表示的几何转换应用于指定矩形所产生的结果。
|
public double a
public double b
public double c
public double d
public double tx
public double ty
public HMatrix(double a,
double b,
double c,
double d,
double tx,
double ty)
a - b - c - d - tx - ty - public HMatrix()
public HMatrix clone()
clone 在类中 java.lang.Objectpublic void concat(HMatrix m)
m - public HPoint transformPoint(HPoint point)
point - public HPoint deltaTransformPoint(HPoint point)
point - public void createBox(double scaleX,
double scaleY,
double rotation,
double tx,
double ty)
scaleX - scaleY - rotation - 弧度tx - ty - public void identity()
public void rotate(double angle)
angle - 以弧度为单位的旋转角度。public void scale(double sx,
double sy)
sx - sy - public void translate(double dx,
double dy)
dx - dy - public void invert()
public HRectangle transleteRect(HRectangle rect)
rect -