Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebGLTextures: Used sized internal format for depth stencil #16769

Merged
merged 1 commit into from
Jun 18, 2019

Conversation

aardgoose
Copy link
Contributor

@aardgoose aardgoose commented Jun 12, 2019

Fixed #16756

gl.renderbufferStorageMultisample() requires a sized internal format specifier. Chrome enforces this, firefox extends the behaviour of renderbufferStorage():

To be backward compatible with WebGL 1, also accepts internal format DEPTH_STENCIL, which should be mapped to DEPTH24_STENCIL8 by implementations.

to renderbufferStorageMultisample() which is not required by the spec.

@Mugen87
Copy link
Collaborator

Mugen87 commented Jun 12, 2019

Before merging this we might want to wait for some feedback here: #16756 (comment)

@aardgoose
Copy link
Contributor Author

Ok, from reading the spec Chrome is compliant, Firefox has just extended the laxity of WebGL1 to WebGL2 functions (internally to FF both renderbufferStorage variants take exactly the same path where the translation of DEPTH_STENCIL to DEPTH24_STENCIL8 takes place, before hitting ANGLE etc ).

@Mugen87 Mugen87 changed the title used sized internal format for depth stencil WebGLTextures: Used sized internal format for depth stencil Jun 14, 2019
@mrdoob mrdoob added this to the r106 milestone Jun 18, 2019
@mrdoob mrdoob merged commit d051742 into mrdoob:dev Jun 18, 2019
@mrdoob
Copy link
Owner

mrdoob commented Jun 18, 2019

Thanks!

@aardgoose aardgoose deleted the ms-fix branch June 18, 2019 11:25
@Mugen87
Copy link
Collaborator

Mugen87 commented Jun 19, 2019

@aardgoose Since you introduced a new constant, it's necessary to add it right here:

https://github.com/mrdoob/three.js/blob/dev/rollup.config.js#L3

Otherwise you can a warning when performing the build:

  • Unhandled GL Constant: DEPTH24_STENCIL8

@mrdoob
Copy link
Owner

mrdoob commented Jun 19, 2019

Fixed ab13080

@aardgoose
Copy link
Contributor Author

@Mugen87
Oops! Apologies, I should have spotted that, I was aware of the constant post processing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

gl.DEPTH_STENCIL not accepted by renderbufferStorageMultisample()
3 participants