Struct ren::prelude::VertexArray
source · pub struct VertexArray<'gl> { /* private fields */ }
Implementations§
source§impl VertexArray<'static>
impl VertexArray<'static>
sourcepub unsafe fn new_unsafe<'gl, 'a>(
desc: impl AsRef<VertexArrayDesc<'gl, 'a>>
) -> Selfwhere
'gl: 'a,
pub unsafe fn new_unsafe<'gl, 'a>( desc: impl AsRef<VertexArrayDesc<'gl, 'a>> ) -> Selfwhere 'gl: 'a,
Safety
Must only be called on a thread where there is a current
OpenGL context. The returned VertexArray
must only
exist, while the OpenGL context is valid.
source§impl<'gl> VertexArray<'gl>
impl<'gl> VertexArray<'gl>
pub fn new<'a>( _ctx: &mut RenderingContext<'gl>, desc: impl AsRef<VertexArrayDesc<'gl, 'a>> ) -> Selfwhere 'gl: 'a,
pub unsafe fn bind(&self)
pub unsafe fn draw_triangles(&self, first: u32, tri_count: u32)
pub unsafe fn draw_points(&self, first: u32, vertex_count: u32)
Trait Implementations§
source§impl Debug for VertexArray<'_>
impl Debug for VertexArray<'_>
source§impl Drop for VertexArray<'_>
impl Drop for VertexArray<'_>
Auto Trait Implementations§
impl<'gl> RefUnwindSafe for VertexArray<'gl>
impl<'gl> Send for VertexArray<'gl>
impl<'gl> Sync for VertexArray<'gl>
impl<'gl> Unpin for VertexArray<'gl>
impl<'gl> UnwindSafe for VertexArray<'gl>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more