add glslang to support webgl frontend reflection#401
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This pull request adds glslang library binary files and headers for Darwin (macOS) and Android platforms, along with minor code refactoring in the renderer module. The key changes involve:
- Adding precompiled glslang static libraries (
.afiles) for Darwin and Android/aarch64 platforms - Adding glslang public header files for SPIRV-Tools and glslang APIs
- Refactoring uniform location logic to remove caching mechanism
- Updating command buffer type checking to use a static method
Reviewed Changes
Copilot reviewed 33 out of 46 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| thirdparty/libs/Darwin/lib/glslang/*.a | Darwin (macOS) precompiled glslang libraries (default resource limits, SPIRV, OS-dependent, machine-independent, and generic code gen) |
| thirdparty/libs/Android/aarch64/lib/glslang/*.a | Android ARM64 precompiled glslang libraries |
| thirdparty/headers/glslang/include/**/*.hpp, *.h | Public API headers for SPIRV-Tools optimizer, linker, and glslang build configuration |
| src/renderer/gles/context_app.cpp | Simplified uniform location lookup by removing cached location path |
| src/renderer/content_renderer.cpp | Updated XR frame control check to use static method |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces significant improvements to the WebGL client by integrating the GLSLang shader compiler, refactoring the program and shader management logic, and simplifying the codebase for better maintainability and performance. The most important changes are grouped below.
GLSLang Integration
cmake/TransmuteCommon.cmake,cmake/TransmuteClient.cmake), and ensured GLSLang is initialized in the WebGL context (src/client/graphics/webgl_context.cpp). This enables client-side shader compilation and validation. [1] [2] [3] [4]WebGL Program and Shader Refactoring
link,compile,attachShader,detachShader) instead of relying solely on command buffer requests, allowing for more robust and synchronous error handling and info log retrieval. [1] [2] [3]Codebase Simplification
API Improvements
WebGLActiveInfofor easier instantiation with name, type, and size.Build System Enhancements
These changes collectively modernize the WebGL client infrastructure, improve shader management reliability, and lay the groundwork for future graphics features.