feat: add renderer backend config option#595
Open
romanstingler wants to merge 1 commit intoMalpenZibo:mainfrom
Open
feat: add renderer backend config option#595romanstingler wants to merge 1 commit intoMalpenZibo:mainfrom
romanstingler wants to merge 1 commit intoMalpenZibo:mainfrom
Conversation
Adds support for selecting Vulkan/OpenGL/Auto renderer backend via config.toml. Uses wgpu environment variables set before any initialization. Automatic behavior: - Auto mode (default): automatically uses OpenGL when proprietary NVIDIA driver is detected, Vulkan for all other hardware (AMD/Intel/nouveau) - User can always explicitly select vulkan or opengl to override Valid options: - 'auto' (default) - 'vulkan' - force Vulkan backend - 'opengl' - force OpenGL backend
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.
Adds support for selecting Vulkan/OpenGL/Auto renderer backend via
config.toml. Uses wgpu environment variables set before any initialization.Automatic behavior:
Valid options:
auto(default)vulkan- force Vulkan backendopengl- force OpenGL backendrelated to discussion #450 (comment)
Testing:
add this to your config's top level
renderer_backend = "auto"run
RUST_LOG=wgpu=debug cargo run -- -c config.toml > /tmp/log(or whatever config you use)Vulkan
and in OpenGL you will see
@clotodex @MalpenZibo
It is the simplest I could come up with.