Struct glin::texture::Builder [−][src]
pub struct Builder<'a>(_);
Implementations
impl<'a> Builder<'a>
[src]
impl<'a> Builder<'a>
[src]pub fn from_format(&self, format: Format) -> Result<Texture>
[src]
Creates a new texture using the specified format
pub fn from_data_format<T: 'static>(
&self,
data_format: LoadDataFormat,
data: &[T]
) -> Result<Texture>
[src]
&self,
data_format: LoadDataFormat,
data: &[T]
) -> Result<Texture>
Creates a new texture using the specified format
pub fn from_image<I: Image>(&self, img: &I, target: GLenum) -> Result<Texture> where
<I as Image>::DataType: Clone + 'static,
[src]
<I as Image>::DataType: Clone + 'static,
Creates a new texture from an Image and GL target
pub fn from_image_allocate_max_levels<I: Image>(
&self,
img: &I,
target: GLenum
) -> Result<Texture> where
<I as Image>::DataType: Clone + 'static,
[src]
&self,
img: &I,
target: GLenum
) -> Result<Texture> where
<I as Image>::DataType: Clone + 'static,
Creates a new texture from an Image and GL target
pub unsafe fn from_allocated(
&self,
settings: WrapperSettings
) -> Result<Texture>
[src]
&self,
settings: WrapperSettings
) -> Result<Texture>
Creates a new texture from an already allocated GL resource
The texture can own the GL resource by setting owned to true in the passed
WrappedSettigns
which will release the GL resource when dropping the texture