Type Alias surfman::platform::unix::default::surface::SurfaceTexture

source ·
pub type SurfaceTexture = SurfaceTexture<Device<Device, Device>, Device>;
Expand description

Represents an OpenGL texture that wraps a surface.

Reading from the associated OpenGL texture reads from the surface. It is undefined behavior to write to such a texture (e.g. by binding it to a framebuffer and rendering to that framebuffer).

Surface textures are local to a context, but that context does not have to be the same context as that associated with the underlying surface. The texture must be destroyed with the destroy_surface_texture() method, or a panic will occur.

Aliased Type§

enum SurfaceTexture {
    Default(SurfaceTexture<Device, Device>),
    Alternate(SurfaceTexture),
}

Variants§

§

Default(SurfaceTexture<Device, Device>)

The default surface texture type.

§

Alternate(SurfaceTexture)

The alternate surface texture type.