Trait glitter::context::buffer_context::ArrayBufferContext [] [src]

pub trait ArrayBufferContext: AContext {
    type Binder: BorrowMut<ArrayBufferBinder>;
    type Rest: AContext;
    fn split_array_buffer(self) -> (Self::Binder, Self::Rest);

    fn bind_array_buffer<'a>(self, buffer: &'a mut Buffer) -> (ArrayBufferBinding<'a>, Self::Rest) where Self: Sized { ... }
}

An OpenGL context that has a free GL_ARRAY_BUFFER binding.

Associated Types

type Binder: BorrowMut<ArrayBufferBinder>

The type of binder this context contains.

type Rest: AContext

The OpenGL context that will be returned after binding the array buffer.

Required Methods

fn split_array_buffer(self) -> (Self::Binder, Self::Rest)

Split this context into a binder and the remaining context.

Provided Methods

fn bind_array_buffer<'a>(self, buffer: &'a mut Buffer) -> (ArrayBufferBinding<'a>, Self::Rest) where Self: Sized

Bind a buffer to this context's array buffer, returning a new context and a binding.

See also

glBindBuffer OpenGL docs

Implementors