Texture.this

Creates a blank dsdl2.Texture in the VRAM, which wraps SDL_CreateTexture

  1. this(SDL_Texture* sdlTexture, bool isOwner, void* userRef)
  2. this(Renderer renderer, PixelFormat pixelFormat, TextureAccess access, uint[2] size)
    class Texture
  3. this(Renderer renderer, Surface surface)

Parameters

renderer Renderer

dsdl2.Renderer the texture belongs to

pixelFormat PixelFormat

dsdl2.PixelFormat that the texture pixel data is stored as

access TextureAccess

dsdl2.TextureAccess enumeration which indicates its access rule

size uint[2]

the size of the texture (width and height)

Throws

dsdl2.SDLException if creation failed

Meta