pub fn new<P: IsA<Texture>>(
        ctx: &Context,
        parent_texture: &P,
        sub_x: i32,
        sub_y: i32,
        sub_width: i32,
        sub_height: i32,
    ) -> SubTexture {
        unsafe {
            from_glib_full(ffi::cogl_sub_texture_new(
                ctx.to_glib_none().0,
                parent_texture.as_ref().to_glib_none().0,
                sub_x,
                sub_y,
                sub_width,
                sub_height,
            ))
        }
    }
/// Creates a high-level `SubTexture` representing a sub-region of
/// any other `Texture`. The sub-region must strictly lye within the
/// bounds of the `parent_texture`. The returned texture implements the
/// `MetaTexture` interface because it's not a low level texture
/// that hardware can understand natively.
///
/// `<note>`Remember: Unless you are using high level drawing APIs such
/// as `cogl_rectangle` or other APIs documented to understand the
/// `MetaTexture` interface then you need to use the
/// `MetaTexture` interface to resolve a `SubTexture` into a
/// low-level texture before drawing.`</note>`
/// ## `ctx`
/// A `Context` pointer
/// ## `parent_texture`
/// The full texture containing a sub-region you want
///  to make a `SubTexture` from.
/// ## `sub_x`
/// The top-left x coordinate of the parent region to make
///  a texture from.
/// ## `sub_y`
/// The top-left y coordinate of the parent region to make
///  a texture from.
/// ## `sub_width`
/// The width of the parent region to make a texture from.
/// ## `sub_height`
/// The height of the parent region to make a texture
///  from.
///
/// # Returns
///
/// A newly allocated `SubTexture`
///  representing a sub-region of `parent_texture`.
Creates a high-level `SubTexture` representing a sub-region of
any other `Texture`. The sub-region must strictly lye within the
bounds of the `parent_texture`. The returned texture implements the
`MetaTexture` interface because it's not a low level texture
that hardware can understand natively.


Creates a high - level ` SubTexture ` representing a sub - region of any other ` Texture ` . The sub - region must strictly lye within the bounds of the ` parent_texture ` . The returned texture implements the ` MetaTexture ` interface because it ' s not a low level texture that hardware can understand natively .
pub fn new<P: IsA<Texture>>(
        ctx: &Context,
        parent_texture: &P,
        sub_x: i32,
        sub_y: i32,
        sub_width: i32,
        sub_height: i32,
    ) -> SubTexture {
        unsafe {
            from_glib_full(ffi::cogl_sub_texture_new(
                ctx.to_glib_none().0,
                parent_texture.as_ref().to_glib_none().0,
                sub_x,
                sub_y,
                sub_width,
                sub_height,
            ))
        }
    }
pub fn new < P : IsA < Texture > > ( ctx : & Context , parent_texture : & P , sub_x : i32 , sub_y : i32 , sub_width : i32 , sub_height : i32 , ) -> SubTexture { unsafe { from_glib_full ( ffi :: cogl_sub_texture_new ( ctx . to_glib_none ( ) . 0 , parent_texture . as_ref ( ) . to_glib_none ( ) . 0 , sub_x , sub_y , sub_width , sub_height , ) ) } }
Creates a high-level `SubTexture` representing a sub-region of
any other `Texture`.
Creates a high - level ` SubTexture ` representing a sub - region of any other ` Texture ` .
ctx
&Context
parent_texture
&P
sub_x
i32
sub_y
i32
sub_width
i32
sub_height
i32
A newly allocated `SubTexture`
representing a sub-region of `parent_texture`.
A newly allocated ` SubTexture ` representing a sub - region of ` parent_texture ` .
ctx
&Context
parent_texture
&P
sub_x
i32
sub_y
i32
sub_width
i32
sub_height
i32
`ctx`
A `Context` pointer
A ` Context ` pointer
`parent_texture`
The full texture containing a sub-region you want
to make a `SubTexture` from.
The full texture containing a sub - region you want to make a ` SubTexture ` from .
`sub_x`
The top-left x coordinate of the parent region to make
a texture from.
The top - left x coordinate of the parent region to make a texture from .
`sub_y`
The top-left y coordinate of the parent region to make
a texture from.
The top - left y coordinate of the parent region to make a texture from .
`sub_width`
The width of the parent region to make a texture from.
The width of the parent region to make a texture from .
`sub_height`
The height of the parent region to make a texture
from.
The height of the parent region to make a texture from .