C# 클래스 SFML.Graphics.Transform

파일 보기 프로젝트 열기: SFML/SFML.Net 1 사용 예제들

공개 메소드들

메소드 설명
Combine ( Transform transform ) : void

Combine the current transform with another one. The result is a transform that is equivalent to applying this followed by transform. Mathematically, it is equivalent to a matrix multiplication.

GetInverse ( ) : Transform

Return the inverse of the transform. If the inverse cannot be computed, an identity transform is returned.

Rotate ( float angle ) : void

Combine the current transform with a rotation.

Rotate ( float angle, Vector2f center ) : void

Combine the current transform with a rotation. The center of rotation is provided for convenience as a second argument, so that you can build rotations around arbitrary points more easily (and efficiently) than the usual Translate(-center); Rotate(angle); Translate(center).

Rotate ( float angle, float centerX, float centerY ) : void

Combine the current transform with a rotation. The center of rotation is provided for convenience as a second argument, so that you can build rotations around arbitrary points more easily (and efficiently) than the usual Translate(-center); Rotate(angle); Translate(center).

Scale ( Vector2f factors ) : void

Combine the current transform with a scaling.

Scale ( Vector2f factors, Vector2f center ) : void

Combine the current transform with a scaling. The center of scaling is provided for convenience as a second argument, so that you can build scaling around arbitrary points more easily (and efficiently) than the usual Translate(-center); Scale(factors); Translate(center).

Scale ( float scaleX, float scaleY ) : void

Combine the current transform with a scaling.

Scale ( float scaleX, float scaleY, float centerX, float centerY ) : void

Combine the current transform with a scaling. The center of scaling is provided for convenience as a second argument, so that you can build scaling around arbitrary points more easily (and efficiently) than the usual Translate(-center); Scale(factors); Translate(center).

ToString ( ) : string

Provide a string describing the object

Transform ( float a00, float a01, float a02, float a10, float a11, float a12, float a20, float a21, float a22 ) : System.Runtime.InteropServices

Construct a transform from a 3x3 matrix

TransformPoint ( Vector2f point ) : Vector2f

Transform a 2D point.

TransformPoint ( float x, float y ) : Vector2f

Transform a 2D point.

TransformRect ( FloatRect rectangle ) : FloatRect

Transform a rectangle. Since SFML doesn't provide support for oriented rectangles, the result of this function is always an axis-aligned rectangle. Which means that if the transform contains a rotation, the bounding rectangle of the transformed rectangle is returned.

Translate ( Vector2f offset ) : void

Combine the current transform with a translation.

Translate ( float x, float y ) : void

Combine the current transform with a translation.

operator ( ) : Transform

Overload of binary operator * to combine two transforms. This call is equivalent to calling new Transform(left).Combine(right).

operator ( ) : Vector2f

Overload of binary operator * to transform a point. This call is equivalent to calling left.TransformPoint(right).

비공개 메소드들

메소드 설명
sfTransform_combine ( Transform &transform, Transform &other ) : void
sfTransform_getInverse ( Transform &transform ) : Transform
sfTransform_rotate ( Transform &transform, float angle ) : void
sfTransform_rotateWithCenter ( Transform &transform, float angle, float centerX, float centerY ) : void
sfTransform_scale ( Transform &transform, float scaleX, float scaleY ) : void
sfTransform_scaleWithCenter ( Transform &transform, float scaleX, float scaleY, float centerX, float centerY ) : void
sfTransform_transformPoint ( Transform &transform, Vector2f point ) : Vector2f
sfTransform_transformRect ( Transform &transform, FloatRect rectangle ) : FloatRect
sfTransform_translate ( Transform &transform, float x, float y ) : void

메소드 상세

Combine() 공개 메소드

Combine the current transform with another one. The result is a transform that is equivalent to applying this followed by transform. Mathematically, it is equivalent to a matrix multiplication.
public Combine ( Transform transform ) : void
transform Transform Transform to combine to this transform
리턴 void

GetInverse() 공개 메소드

Return the inverse of the transform. If the inverse cannot be computed, an identity transform is returned.
public GetInverse ( ) : Transform
리턴 Transform

Rotate() 공개 메소드

Combine the current transform with a rotation.
public Rotate ( float angle ) : void
angle float Rotation angle, in degrees
리턴 void

Rotate() 공개 메소드

Combine the current transform with a rotation. The center of rotation is provided for convenience as a second argument, so that you can build rotations around arbitrary points more easily (and efficiently) than the usual Translate(-center); Rotate(angle); Translate(center).
public Rotate ( float angle, Vector2f center ) : void
angle float Rotation angle, in degrees
center Vector2f Center of rotation
리턴 void

Rotate() 공개 메소드

Combine the current transform with a rotation. The center of rotation is provided for convenience as a second argument, so that you can build rotations around arbitrary points more easily (and efficiently) than the usual Translate(-center); Rotate(angle); Translate(center).
public Rotate ( float angle, float centerX, float centerY ) : void
angle float Rotation angle, in degrees
centerX float X coordinate of the center of rotation
centerY float Y coordinate of the center of rotation
리턴 void

Scale() 공개 메소드

Combine the current transform with a scaling.
public Scale ( Vector2f factors ) : void
factors Vector2f Scaling factors
리턴 void

Scale() 공개 메소드

Combine the current transform with a scaling. The center of scaling is provided for convenience as a second argument, so that you can build scaling around arbitrary points more easily (and efficiently) than the usual Translate(-center); Scale(factors); Translate(center).
public Scale ( Vector2f factors, Vector2f center ) : void
factors Vector2f Scaling factors
center Vector2f Center of scaling
리턴 void

Scale() 공개 메소드

Combine the current transform with a scaling.
public Scale ( float scaleX, float scaleY ) : void
scaleX float Scaling factor on the X axis
scaleY float Scaling factor on the Y axis
리턴 void

Scale() 공개 메소드

Combine the current transform with a scaling. The center of scaling is provided for convenience as a second argument, so that you can build scaling around arbitrary points more easily (and efficiently) than the usual Translate(-center); Scale(factors); Translate(center).
public Scale ( float scaleX, float scaleY, float centerX, float centerY ) : void
scaleX float Scaling factor on X axis
scaleY float Scaling factor on Y axis
centerX float X coordinate of the center of scaling
centerY float Y coordinate of the center of scaling
리턴 void

ToString() 공개 메소드

Provide a string describing the object
public ToString ( ) : string
리턴 string

Transform() 공개 메소드

Construct a transform from a 3x3 matrix
public Transform ( float a00, float a01, float a02, float a10, float a11, float a12, float a20, float a21, float a22 ) : System.Runtime.InteropServices
a00 float Element (0, 0) of the matrix
a01 float Element (0, 1) of the matrix
a02 float Element (0, 2) of the matrix
a10 float Element (1, 0) of the matrix
a11 float Element (1, 1) of the matrix
a12 float Element (1, 2) of the matrix
a20 float Element (2, 0) of the matrix
a21 float Element (2, 1) of the matrix
a22 float Element (2, 2) of the matrix
리턴 System.Runtime.InteropServices

TransformPoint() 공개 메소드

Transform a 2D point.
public TransformPoint ( Vector2f point ) : Vector2f
point Vector2f Point to transform
리턴 Vector2f

TransformPoint() 공개 메소드

Transform a 2D point.
public TransformPoint ( float x, float y ) : Vector2f
x float X coordinate of the point to transform
y float Y coordinate of the point to transform
리턴 Vector2f

TransformRect() 공개 메소드

Transform a rectangle. Since SFML doesn't provide support for oriented rectangles, the result of this function is always an axis-aligned rectangle. Which means that if the transform contains a rotation, the bounding rectangle of the transformed rectangle is returned.
public TransformRect ( FloatRect rectangle ) : FloatRect
rectangle FloatRect Rectangle to transform
리턴 FloatRect

Translate() 공개 메소드

Combine the current transform with a translation.
public Translate ( Vector2f offset ) : void
offset Vector2f Translation offset to apply
리턴 void

Translate() 공개 메소드

Combine the current transform with a translation.
public Translate ( float x, float y ) : void
x float Offset to apply on X axis
y float Offset to apply on Y axis
리턴 void

operator() 공개 정적인 메소드

Overload of binary operator * to combine two transforms. This call is equivalent to calling new Transform(left).Combine(right).
public static operator ( ) : Transform
리턴 Transform

operator() 공개 정적인 메소드

Overload of binary operator * to transform a point. This call is equivalent to calling left.TransformPoint(right).
public static operator ( ) : Vector2f
리턴 Vector2f