-
Notifications
You must be signed in to change notification settings - Fork 216
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
fix(webgl): Apply default viewport sizes #2116
Conversation
`RenderPassProps.parameters.viewport` controls how the rendered graphics is mapped to window pixels / texels (more precisely, the affine transformation of x and y from normalized device coordinates to window coordinates). | ||
|
||
If no value for the `viewport` parameter is provided, the following defaults will be applied. | ||
- If no `framebuffer` is specified, the size of the canvas drawing buffer will be used (`[gl.canvas.drawingBufferWidth, gl.canvas.drawingBufferHeight]`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a WebGPU equivalent?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a WebGPU equivalent?
Very good point, the docs should not be WebGL specific. Will drop.
supported = supported && checkTextureFeature(gl, info.f as DeviceFeature, extensions); | ||
supported = supported && checkTextureFeature(gl, info.f, extensions); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hard to tell in the diff, is this related?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Huh, no, must be some some lint/prettier autofix. But if the casts are not needed, then better drop them...
LGTM assuming these values are post-application of device pixel ratio. |
Background
Change List
Before

After
