-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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 Firefox warnings #6297
Fix Firefox warnings #6297
Conversation
@bagnell, thanks for the pull request! Maintainers, we have a signed CLA from @bagnell, so you can review this at any time.
I am a bot who helps you make Cesium awesome! Contributions to my configuration are welcome. 🌍 🌎 🌏 |
Yeah maybe in Are there other textures besides water mask that are defaulting to flipy? And maybe we have more control to fix them. |
I'm not sure. |
One example: With We should try to find the other areas like this. |
Source/Core/PixelFormat.js
Outdated
@@ -150,6 +150,7 @@ define([ | |||
// Many GPUs store RGB as RGBA internally | |||
// https://devtalk.nvidia.com/default/topic/699479/general-graphics-programming/rgb-auto-converted-to-rgba/post/4142379/#4142379 |
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.
Since we return 3 now, should this comment be removed?
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.
I'm surprised having it as 4 didn't cause any problems since we use this to create arrays. I guess we don't use RGB textures at all. I kept this there for now because I plan on moving it to a separate function (for when we measure GPU memory usage)
Source/Core/PixelFormat.js
Outdated
var textureWidth = width * numberOfComponents; | ||
for (var i = 0; i < height; ++i) { | ||
for (var j = 0; j < textureWidth; ++j) { | ||
flipped[(height - i - 1) * height + j] = bufferView[i * height + j]; |
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.
Why not factor (height - i - 1) * height
and i * height
out of the inter loop?
Added above:
|
@lilleyse Can you look at The texture creation doesn't fail for the batch table, but when creating the BRDF LUT. How does this pass in master? |
This is ready with the exception of that one failing test. |
The code looks good, but I still think we need to scrub through the code to avoid flipY as much as we can. For example hover over picking will repeatedly call the flip code and incur a bunch of overhead. |
I started to look into this... |
@lilleyse This is ready. Also if you run this test standalone in master it fails: |
I looked around to see if any other areas could set
|
@lilleyse Updated. |
Fixes #4815. |
@lilleyse Updated. Only the second color texture needed to be zeroed out. Seems like a Firefox bug. |
Ok - looks good! |
Same as #5939 but also fixes the flipped water mask.
TODO