Struct reverie_engine_opengl::vao::Vao
source · pub struct Vao<'a> { /* private fields */ }
Expand description
OpenGLのVertex Array ObjectとVertex Buffer Objectに対応する構造体
Implementations§
source§impl<'a> Vao<'a>
impl<'a> Vao<'a>
sourcepub fn new(
gl: Gl,
size: GLsizeiptr,
data: *const c_void,
usage: GLenum,
num_attributes: usize,
attribute_types: &'static [GLenum],
attribute_sizes: &'static [GLint],
stride: GLsizei,
vertex_num: i32,
config: &'a VaoConfig
) -> Vao<'a>
pub fn new( gl: Gl, size: GLsizeiptr, data: *const c_void, usage: GLenum, num_attributes: usize, attribute_types: &'static [GLenum], attribute_sizes: &'static [GLint], stride: GLsizei, vertex_num: i32, config: &'a VaoConfig ) -> Vao<'a>
代わりに[self::vao_buffer::VaoBuffer
]を使うことを推奨
sourcepub fn draw(&self, uniforms: &UniformVariables<'_>, draw_mode: GLenum)
pub fn draw(&self, uniforms: &UniformVariables<'_>, draw_mode: GLenum)
Use [crate::Renderer
] instead
sourcepub fn draw_triangles(&self, uniforms: &UniformVariables<'_>)
pub fn draw_triangles(&self, uniforms: &UniformVariables<'_>)
ポリゴンを描画する
Use [crate::Renderer
] instead
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Vao<'a>
impl<'a> RefUnwindSafe for Vao<'a>
impl<'a> !Send for Vao<'a>
impl<'a> !Sync for Vao<'a>
impl<'a> Unpin for Vao<'a>
impl<'a> UnwindSafe for Vao<'a>
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
source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read moresource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.