Skip to content

Commit

Permalink
Check for WEBGLTextureView, not WEBGLTexture
Browse files Browse the repository at this point in the history
  • Loading branch information
felixpalmer committed Mar 8, 2024
1 parent 3bcaab8 commit 0fa3dd0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/webgl/src/adapter/resources/webgl-render-pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -463,12 +463,12 @@ export class WEBGLRenderPipeline extends RenderPipeline {
texture = value;
} else if (
value instanceof WEBGLFramebuffer &&
value.colorAttachments[0] instanceof WEBGLTexture
value.colorAttachments[0] instanceof WEBGLTextureView
) {
log.warn(
'Passing framebuffer in texture binding may be deprecated. Use fbo.colorAttachments[0] instead'
)();
texture = value.colorAttachments[0];
texture = value.colorAttachments[0].texture;
} else {
throw new Error('No texture');
}
Expand Down

0 comments on commit 0fa3dd0

Please sign in to comment.