C# 클래스 NewTOAPIA.GL.GLTextureUnit

The GPU may have multiple texture units. By definition there is at least one, and in many cases there will be multiple. When a texture is 'bound', it is bound to a specific texture unit. TextureUnit0, is the default texture unit. In order to access a texture from within GLSL code, the texture is referenced based on the TextureUnit that it is bound to. So, for example, a texture that is bound to TextureUnit3 would be accessed in a sampler2D using the ordinal value '3'. The property 'OrdinalForShaders' gives this value.
상속: IBindable
파일 보기 프로젝트 열기: Wiladams/NewTOAPIA 1 사용 예제들

공개 메소드들

메소드 설명
AssignTexture ( GLTexture2D aTexture ) : void
Bind ( ) : void
GetMaxTextureUnits ( GraphicsInterface gi ) : int
GetTextureUnit ( GraphicsInterface gi, TextureUnitID unitID ) : GLTextureUnit
Unbind ( ) : void

비공개 메소드들

메소드 설명
GLTextureUnit ( GraphicsInterface gi, TextureUnitID unitID ) : System

메소드 상세

AssignTexture() 공개 메소드

public AssignTexture ( GLTexture2D aTexture ) : void
aTexture GLTexture2D
리턴 void

Bind() 공개 메소드

public Bind ( ) : void
리턴 void

GetMaxTextureUnits() 공개 정적인 메소드

public static GetMaxTextureUnits ( GraphicsInterface gi ) : int
gi GraphicsInterface
리턴 int

GetTextureUnit() 공개 정적인 메소드

public static GetTextureUnit ( GraphicsInterface gi, TextureUnitID unitID ) : GLTextureUnit
gi GraphicsInterface
unitID TextureUnitID
리턴 GLTextureUnit

Unbind() 공개 메소드

public Unbind ( ) : void
리턴 void