Closed Bug 1599016 Opened 10 months ago Closed 10 months ago

[Wayland] Don't use GL_TEXTURE_EXTERNAL_OES textures with dmabuf backend

Categories

(Core :: Graphics, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla72
Tracking Status
firefox72 --- fixed

People

(Reporter: stransky, Assigned: stransky)

References

(Blocks 1 open bug, Regressed 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

According to https://gitlab.freedesktop.org/mesa/mesa/issues/2119 we should remove GL_TEXTURE_EXTERNAL_OES and use just plain GL_TEXTURE_2D.

Attached patch wip (obsolete) — Splinter Review

There's a WIP patch for it but I still have Webrender with external texture, I wonder if I need also update some rust code for it.

Assignee: nobody → stransky

Sotaro, do you know how WebRender get texture target for shaders? I'm unable to persuade it to use TEXTURE_2D as it still uses TEXTURE_EXTERNAL. May it be due to EGLImage used here?
Thanks.

Flags: needinfo?(sotaro.ikeda.g)

(In reply to Martin Stránský [:stransky] from comment #2)

Sotaro, do you know how WebRender get texture target for shaders? I'm unable to persuade it to use TEXTURE_2D as it still uses TEXTURE_EXTERNAL. May it be due to EGLImage used here?

WaylandDMABUFTextureHostOGL::PushResourceUpdates() set texture target type of WebRender as wr::TextureTarget::External. Changing it seems to affect to final OpenGL texture target type.
https://searchfox.org/mozilla-central/rev/0678172d5b5c681061b904c776b668489e3355b0/gfx/layers/opengl/WaylandDMABUFTextureHostOGL.cpp#111

The gl target type is selected at get_gl_target()
https://searchfox.org/mozilla-central/rev/0678172d5b5c681061b904c776b668489e3355b0/gfx/wr/webrender/src/device/gl.rs#179

Flags: needinfo?(sotaro.ikeda.g)
Attachment #9111222 - Attachment is obsolete: true
Pushed by btara@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/6d0efb589757
[Wayland] Don't use GL_TEXTURE_EXTERNAL_OES textures with DMA BUF backend, r=sotaro
Status: NEW → RESOLVED
Closed: 10 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla72
Regressions: 1608553
You need to log in before you can comment on or make changes to this bug.