Canvas news: Difference between revisions

Jump to navigation Jump to search
1,466 bytes added ,  5 September 2021
m
Line 6: Line 6:


== 2021 ==
== 2021 ==
=== Moving Canvas Rendering to a separate OpenGL Context ===
{{Main article|Howto:New Canvas Execution Model}}
[[File:Pbuffer-based-canvas-startup.png|thumb|fgfs initialization with pbuffer based addCamera() modification in renderer.cxx to create canvas cameras in a dedicated GL context]]
[[File:Pbuffer-based-canvas-cams.png|thumb|pbuffer based canvas cams used for offscreen rendering, but also to move canvas rendering out of the main loop (in conjunction with aggressive OSG threading via )
This shows disabled context sharing and use a separate osg::Image to copy the texture from one GL context to another (the CPU being the bottleneck, unless we can use a shader or PBO to do this)]]
[[File:Fgfs-20210904184748.png|thumb|This screen shot shows the FG1000 running in a patched fgfs version where Canvas Cameras are attached to an OpenGL context running in another thread. Synchronization with the main thread is not accomplished using a shared context, but instead using an osg::Image (which considerably slows down things, as can be seen in the stats above)]]
Early experiments  moving Canvas rendering out of the main loop by using aggressive OSG threading in conjunction with a separate GL context for Canvas cams, and subsequently, with also moving Nasal (and Property Tree I/O) out of the main loop by using a dedicated thread per Canvas [Texture], probably with its own FGNasalSys instance and related subsystem machinery (mainly, events/timers).
=== Dedicated prerender cams ===
=== Dedicated prerender cams ===
{{See also|Post_FlightGear_2020.2_LTS_changes#Canvas}}
{{See also|Post_FlightGear_2020.2_LTS_changes#Canvas}}

Navigation menu