Revert "Use surfman with glow bindings (#34328)" (#35402)

This reverts commit 503bb10c5b.

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
Samson 2025-02-10 18:20:27 +01:00 committed by GitHub
parent 90130315a7
commit 0fed99590a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 97 additions and 69 deletions

View file

@ -152,7 +152,8 @@ impl XRWebGLLayer {
let sub_images = frame.get_sub_images(self.layer_id()?)?;
let session = self.session();
// TODO: Cache this texture
let color_texture_id = WebGLTextureId::new(sub_images.sub_image.as_ref()?.color_texture?);
let color_texture_id =
WebGLTextureId::maybe_new(sub_images.sub_image.as_ref()?.color_texture)?;
let color_texture = WebGLTexture::new_webxr(context, color_texture_id, session);
let target = self.texture_target();
@ -186,7 +187,7 @@ impl XRWebGLLayer {
.ok()?;
if let Some(id) = sub_images.sub_image.as_ref()?.depth_stencil_texture {
// TODO: Cache this texture
let depth_stencil_texture_id = WebGLTextureId::new(id);
let depth_stencil_texture_id = WebGLTextureId::maybe_new(id)?;
let depth_stencil_texture =
WebGLTexture::new_webxr(context, depth_stencil_texture_id, session);
framebuffer