gles: enable seamless cube map filtering on desktop GL (#10628)

This commit is contained in:
Devrat Kuntal authored and GitHub committed 2026-10-31 09:02:14 +00:00
1 parent 2375b1cd83
commit ecf9863d4c
2 files changed
+6

No files matched your search

+1
View File
@@ -305,6 +305,7 @@ By @sagudev in [#10307](https://github.com/gfx-rs/wgpu/pull/10307).
#### GLES
- Enable `TEXTURE_CUBE_MAP_SEAMLESS` on desktop OpenGL so cube maps sample seamlessly across face edges, matching OpenGL ES 3.0+, WebGL 2, Vulkan, Metal, and Direct3D 12. By @kuntal-devrat in [#10628](https://github.com/gfx-rs/wgpu/pull/10628).
- Fix black EGL surfaces on some platforms by selecting the default framebuffer's color buffer before presentation. By @valadaptive in [#10268](https://github.com/gfx-rs/wgpu/pull/10268).
- Avoid duplicate `EGL_SURFACE_TYPE` attributes when selecting an EGL framebuffer configuration, which caused Mesa to return no matching configurations. By @BlueJayLouche and @scroix in [#10048](https://github.com/gfx-rs/wgpu/pull/10048).
- `@interpolate(linear)` is now rejected by `Device::create_shader_module` on adapters that lack `DownlevelFlags::LINEAR_INTERPOLATION` (GLES/WebGL2), with a shader label and a source span. Previously such a shader validated fine and then failed at pipeline creation with `The selected version doesn't support Features(NOPERSPECTIVE_QUALIFIER)`. By @emilk in [#9972](https://github.com/gfx-rs/wgpu/pull/9972).
+5
View File
@@ -1100,6 +1100,11 @@ impl crate::Adapter for super::Adapter {
unsafe { gl.create_vertex_array() }.map_err(|_| crate::DeviceError::OutOfMemory)?;
unsafe { gl.bind_vertex_array(Some(main_vao)) };
// Desktop GL defaults to non-seamless cube sampling; ES 3.0+ and other backends are seamless by spec.
if !self.shared.es {
unsafe { gl.enable(glow::TEXTURE_CUBE_MAP_SEAMLESS) };
}
let zero_buffer =
unsafe { gl.create_buffer() }.map_err(|_| crate::DeviceError::OutOfMemory)?;
unsafe { gl.bind_buffer(glow::COPY_READ_BUFFER, Some(zero_buffer)) };