Unable to render SDL logic under Dear ImGui. #8275
Closed
vict0rfr
started this conversation in
Build/Link/Run/Fonts issues ONLY!
Replies: 1 comment
-
Update: Found out the problem was that I was using a GL Context and a SDL_Renderer. Dear ImGui would be in my GL Context and my fluid sim SDL Logic would be in the SDL_Renderer. This means that I can't render two "contexts" at the same time. Instead I opted to switch to the SDL_Renderer backend, so that I could have all my logic/Dear ImGui in one renderer. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Similar issue to #4264, but I don't have a flickering problem, and I am not getting what I need under Dear ImGui. I can only have either one.
I am implementing this a bit differently. And the first area I would try looking at is the way I'm dereferencing pointers. I have not other way to initialize
io
afterCreateContext()
but still make it available toImguiBackend::drawImgui
. I have tried moving thethis->_logic.draw()
call everywhere in the method and it won't change a thing. DoesSDL_GL_SwapWindow
only present OpenGL stuff? Hence why I'm not seeing any SDL logic?I have separated my code into multiple classes and I'm calling the draw methods in my main game loop. It works, see picture but obviously my SDL code won't run under it. It's a simple fluid simulation that doesn't create SDL_Textures, it's only drawing lines and adding color (for the moment (: )
Result:
Beta Was this translation helpful? Give feedback.
All reactions