Getting the hardware resolution from the renderer init #3589
Unanswered
oziphantom
asked this question in
Q&A
Replies: 2 comments 1 reply
-
|
Perhaps not the exact answer you're looking for, but I usually get this
from the window to which bgfx is painting. In my case, that'd be SDL3. But
you'd get similar info from glfw, or alike.
|
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Hmm. The issue for me is there are no windows, and you have to fire up the whole graphical system to get the target size. Guess "copy and paste code" into main with #if defs to handle different targets it is. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Inside
bgfx::initthe renderer will query the host and ask what resolution the output is to be. However I can't see anyway to get this information out of the renderer.The passed in
bgfx::Initis a const&, so I can't update the resolution fields of it to return to the caller.The Init function can't access the
Statsobject as the get isconst*and the renderer doesn't have any functions to get at it otherwise that I can see.I can't see a way to grab the renderer post init, just work out which type it is, and then get the values from it to then use to create the view with.
What is the intended way to get this information?
Beta Was this translation helpful? Give feedback.
All reactions