[Fix] (MG_Backend/DirectGLES): avoid PBO updates to sampled offscreen textures

- Track sampled storage by native context and draw batch.
- Use the existing client upload for in-place edits to sampled storage.
This commit is contained in:
Eurya0x13 committed 2026-11-26 14:12:28 +08:00
1 parent 10deb9cea4
commit 639ae0f636
6 files changed
+124 -8

No files matched your search

@@ -639,6 +639,7 @@ namespace MobileGL::MG_Backend::DirectGLES {
} else if (g_EGLFuncs.eglSwapBuffers != nullptr) {
mglSwapped = g_EGLFuncs.eglSwapBuffers(g_Display, drawSurface);
}
if (mglSwapped == EGL_TRUE) TextureImpl::EndDrawTextureBatch();
NoteDrawSurfaceMoved(); // a window surface takes a new size at its swap
if (drawSurface != EGL_NO_SURFACE) {
const std::lock_guard<std::mutex> lock(g_nativeRegistryMutex);