C# 클래스 Sparrow.Textures.SubTexture

A SubTexture represents a section of another texture. This is achieved solely by manipulation of texture coordinates, making the class very efficient. Note that it is OK to create subtextures of subtextures.
상속: Texture
파일 보기 프로젝트 열기: fmotagarcia/sparrow-sharp 1 사용 예제들

공개 메소드들

메소드 설명
AdjustPositions ( VertexData vertexData, uint startIndex, uint count ) : void
AdjustTexCoords ( VertexData vertexData, uint startIndex, uint count ) : void
AdjustVertexData ( VertexData vertexData, uint startIndex, uint count ) : void
SubTexture ( Texture texture, Rectangle region = null, Rectangle frame = null, bool rotated = false ) : System

Initializes a subtexture with a region (in points) of another texture, using a frame rectangle to place the texture within an image. If 'rotated' is 'true', the subtexture will show the base region rotated by 90 degrees (CCW). If frame is null, it will use the whole texture.

보호된 메소드들

메소드 설명
Init ( Texture texture, Rectangle region = null, Rectangle frame = null, bool rotated = false ) : void
SubTexture ( ) : System

비공개 메소드들

메소드 설명
TransformVector2 ( Matrix matrix, System.Vector2 vector ) : System.Vector2

메소드 상세

AdjustPositions() 공개 메소드

public AdjustPositions ( VertexData vertexData, uint startIndex, uint count ) : void
vertexData Sparrow.Utils.VertexData
startIndex uint
count uint
리턴 void

AdjustTexCoords() 공개 메소드

public AdjustTexCoords ( VertexData vertexData, uint startIndex, uint count ) : void
vertexData Sparrow.Utils.VertexData
startIndex uint
count uint
리턴 void

AdjustVertexData() 공개 메소드

public AdjustVertexData ( VertexData vertexData, uint startIndex, uint count ) : void
vertexData Sparrow.Utils.VertexData
startIndex uint
count uint
리턴 void

Init() 보호된 메소드

protected Init ( Texture texture, Rectangle region = null, Rectangle frame = null, bool rotated = false ) : void
texture Texture
region Sparrow.Geom.Rectangle
frame Sparrow.Geom.Rectangle
rotated bool
리턴 void

SubTexture() 보호된 메소드

protected SubTexture ( ) : System
리턴 System

SubTexture() 공개 메소드

Initializes a subtexture with a region (in points) of another texture, using a frame rectangle to place the texture within an image. If 'rotated' is 'true', the subtexture will show the base region rotated by 90 degrees (CCW). If frame is null, it will use the whole texture.
public SubTexture ( Texture texture, Rectangle region = null, Rectangle frame = null, bool rotated = false ) : System
texture Texture
region Sparrow.Geom.Rectangle
frame Sparrow.Geom.Rectangle
rotated bool
리턴 System