igorsegalla
Topic Author
Posts: 9
Joined: 07 Jan 2020, 00:02

Re: Using an existent device (OpenGL)

08 Jan 2020, 19:18

glPushAttrib( GL_ALL_ATTRIB_BITS ) doesnt works?

Tags:
 
User avatar
jsantos
Site Admin
Posts: 2920
Joined: 20 Jan 2012, 17:18
Contact:

Re: Using an existent device (OpenGL)

08 Jan 2020, 19:23

I don't know, we are not using it. If you want to use it instead of restoring manually each state, then you need to figure it out why it is not working, that is a specific GL question. But, we don't recommend using those kind of functions for saving or restoring the state because they are slow or at least they are not fast or supported in all our platforms.
 
igorsegalla
Topic Author
Posts: 9
Joined: 07 Jan 2020, 00:02

Re: Using an existent device (OpenGL)

08 Jan 2020, 19:25

I see, ll try figured out why this is happening, thanks for your time. When I debug game with NoesisGUI render at RenderDoc, looks missing the "Colour Pass #1 (1 Targets + Depth), dno why.
 
igorsegalla
Topic Author
Posts: 9
Joined: 07 Jan 2020, 00:02

Re: Using an existent device (OpenGL)

08 Jan 2020, 23:46

Solved!! Thanks for your time.
I had to store render state and restore it.
 
igorsegalla
Topic Author
Posts: 9
Joined: 07 Jan 2020, 00:02

Re: Using an existent device (OpenGL)

09 Jan 2020, 00:02

There's any problem to call UpdateRenderTree and RenderOffscreen before view->Render()?
This way I just need to save render state once time.

Image
 
User avatar
jsantos
Site Admin
Posts: 2920
Joined: 20 Jan 2012, 17:18
Contact:

Re: Using an existent device (OpenGL)

09 Jan 2020, 10:54

RenderOffscreen may change the active framebuffer and viewport, you should restore it after calling that function. This is the main reason it is recommended to call that function before binding your main framebuffer. Binding and unbinding the same render target several times in the same frame is not very efficient.

Who is online

Users browsing this forum: No registered users and 3 guests