Skip to content

Commit 58d2010

Browse files
committed
Remove unused VAO cache
1 parent f8d681e commit 58d2010

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

inox2d-opengl/src/lib.rs

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ struct GlCache {
4040
pub viewport: Option<UVec2>,
4141
pub blend_mode: Option<BlendMode>,
4242
pub program: Option<glow::Program>,
43-
pub vao: Option<glow::VertexArray>,
4443
pub albedo: Option<TextureId>,
4544
}
4645

@@ -97,14 +96,6 @@ impl GlCache {
9796
}
9897
}
9998

100-
pub fn update_vao(&mut self, vao: glow::VertexArray) -> bool {
101-
if let Some(prev_vao) = self.vao.replace(vao) {
102-
prev_vao != vao
103-
} else {
104-
true
105-
}
106-
}
107-
10899
pub fn update_albedo(&mut self, albedo: TextureId) -> bool {
109100
if let Some(prev_texture) = self.albedo.replace(albedo) {
110101
prev_texture != albedo
@@ -577,8 +568,6 @@ impl InoxRenderer for OpenglRenderer {
577568
todo!()
578569
} else {
579570
unsafe {
580-
gl.bind_vertex_array(Some(self.vao));
581-
582571
gl.active_texture(glow::TEXTURE0);
583572
gl.bind_texture(glow::TEXTURE_2D, Some(self.cf_albedo));
584573
gl.active_texture(glow::TEXTURE1);

0 commit comments

Comments
 (0)