pub struct GlShader {
pub program: u32,
pub geometries: Vec<OpenglAttribute>,
pub instances: Vec<OpenglAttribute>,
pub textures: Vec<OpenglUniform>,
pub xr_depth_texture: OpenglUniform,
pub uniforms: GlShaderUniforms,
}Fields§
§program: u32§geometries: Vec<OpenglAttribute>§instances: Vec<OpenglAttribute>§textures: Vec<OpenglUniform>§xr_depth_texture: OpenglUniform§uniforms: GlShaderUniformsImplementations§
Source§impl GlShader
impl GlShader
pub fn new( gl: &LibGl, vertex: &str, pixel: &str, mapping: &CxDrawShaderMapping, os_type: &OsType, ) -> Self
pub fn set_uniform_array(gl: &LibGl, loc: &OpenglUniform, array: &[f32])
pub fn opengl_get_uniform(gl: &LibGl, program: u32, name: &str) -> OpenglUniform
pub fn opengl_get_uniform_block_binding( gl: &LibGl, program: u32, name: &str, ) -> OpenglUniformBlockBinding
pub fn opengl_get_info_log( gl: &LibGl, compile: bool, shader: usize, source: &str, ) -> String
pub fn opengl_has_shader_error( gl: &LibGl, compile: bool, shader: usize, source: &str, ) -> Option<String>
pub fn opengl_get_attributes( gl: &LibGl, program: u32, prefix: &str, slots: usize, ) -> Vec<OpenglAttribute>
pub fn opengl_get_texture_slots( gl: &LibGl, program: u32, texture_slots: &Vec<DrawShaderTextureInput>, ) -> Vec<OpenglUniform>
pub fn free_resources(self, gl: &LibGl)
Auto Trait Implementations§
impl Freeze for GlShader
impl RefUnwindSafe for GlShader
impl Send for GlShader
impl Sync for GlShader
impl Unpin for GlShader
impl UnsafeUnpin for GlShader
impl UnwindSafe for GlShader
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