Struct solstice::Context[][src]

pub struct Context { /* fields omitted */ }

Implementations

impl Context[src]

pub fn new(ctx: Context) -> Self[src]

pub fn enable(&mut self, feature: Feature)[src]

pub fn disable(&mut self, feature: Feature)[src]

pub fn new_debug_group(&self, message: &str) -> DebugGroup<'_>[src]

pub fn new_buffer(
    &mut self,
    size: usize,
    buffer_type: BufferType,
    usage: Usage,
    initial_data: Option<&[u8]>
) -> Result<BufferKey, GraphicsError>
[src]

pub fn destroy_buffer(&mut self, buffer: &Buffer)[src]

pub fn bind_buffer(&mut self, buffer_key: BufferKey, buffer_type: BufferType)[src]

pub fn buffer_static_draw(&self, buffer: &Buffer, data: &[u8], offset: usize)[src]

pub fn unmap_buffer(&mut self, map: &mut MappedBuffer)[src]

pub fn new_shader(
    &mut self,
    vertex_source: &str,
    fragment_source: &str
) -> Result<ShaderKey, ShaderError>
[src]

pub fn get_shader_attributes(&self, shader: ShaderKey) -> Vec<Attribute>[src]

pub fn get_shader_uniforms(&self, shader: ShaderKey) -> Vec<Uniform>[src]

pub fn destroy_shader(&mut self, shader: ShaderKey)[src]

pub fn use_shader<S: Shader + ?Sized>(&mut self, shader: Option<&S>)[src]

pub fn new_texture(
    &mut self,
    texture_type: TextureType
) -> Result<TextureKey, GraphicsError>
[src]

pub fn destroy_texture(&mut self, texture_key: TextureKey)[src]

pub fn bind_texture_to_unit(
    &mut self,
    texture_type: TextureType,
    texture_key: TextureKey,
    texture_unit: TextureUnit
)
[src]

pub fn new_framebuffer(&mut self) -> Result<FramebufferKey, GraphicsError>[src]

pub fn destroy_framebuffer(&mut self, framebuffer_key: FramebufferKey)[src]

pub fn bind_framebuffer(
    &mut self,
    target: Target,
    framebuffer_key: Option<FramebufferKey>
)
[src]

pub fn check_framebuffer_status(&self, target: Target) -> Status[src]

pub fn get_active_framebuffer(&self, target: Target) -> Option<FramebufferKey>[src]

pub fn framebuffer_texture(
    &mut self,
    target: Target,
    attachment: Attachment,
    texture_type: TextureType,
    texture_key: TextureKey,
    level: u32
)
[src]

pub fn new_renderbuffer(&mut self) -> Result<RenderbufferKey, GraphicsError>[src]

pub fn bind_renderbuffer(&mut self, renderbuffer: Option<RenderbufferKey>)[src]

pub fn renderbuffer_storage(
    &mut self,
    format: PixelFormat,
    width: i32,
    height: i32
)
[src]

pub fn framebuffer_renderbuffer(
    &mut self,
    attachment: Attachment,
    renderbuffer: Option<RenderbufferKey>
)
[src]

pub fn destroy_renderbuffer(&mut self, renderbuffer_key: RenderbufferKey)[src]

pub fn set_vertex_attributes(
    &mut self,
    desired: u32,
    binding_info: &[Option<BindingInfo<'_>>]
)
[src]

pub fn set_uniform_by_location(
    &self,
    location: &UniformLocation,
    data: &RawUniformValue
)
[src]

pub fn draw_arrays(&self, mode: DrawMode, first: i32, count: i32)[src]

pub fn draw_elements(
    &self,
    mode: DrawMode,
    count: i32,
    element_type: u32,
    offset: i32
)
[src]

pub fn draw_arrays_instanced(
    &self,
    mode: DrawMode,
    first: i32,
    count: i32,
    instance_count: i32
)
[src]

pub fn draw_elements_instanced(
    &self,
    mode: DrawMode,
    count: i32,
    element_type: u32,
    offset: i32,
    instance_count: i32
)
[src]

pub fn set_viewport(&mut self, x: i32, y: i32, width: i32, height: i32)[src]

pub fn viewport(&self) -> Viewport<i32>[src]

pub fn set_scissor(&mut self, region: Option<Viewport<i32>>)[src]

pub fn clear_color(&self, red: f32, green: f32, blue: f32, alpha: f32)[src]

pub fn clear(&self)[src]

pub fn read_pixels(
    &self,
    x: i32,
    y: i32,
    width: i32,
    height: i32,
    format: PixelFormat,
    data: &mut [u8]
)
[src]

pub fn debug_message_callback<F>(&self, callback: F) where
    F: FnMut(DebugSource, DebugType, u32, DebugSeverity, &str), 
[src]

Trait Implementations

impl Drop for Context[src]

impl Renderer for Context[src]

impl TextureUpdate for Context[src]

Auto Trait Implementations

impl RefUnwindSafe for Context

impl Send for Context

impl Sync for Context

impl Unpin for Context

impl UnwindSafe for Context

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.