Canvas popout windows: Difference between revisions

From FlightGear wiki
Jump to navigation Jump to search
m (→‎Background: https://sourceforge.net/p/flightgear/mailman/message/36709634/)
Line 1: Line 1:
{{Stub}}
{{Stub}}


== Motivation ==
Would it be possible to make the Canvas Windows leave the FlightGear borderspace? Like in P3D, I can right click a window and click “Undock Window”, which then gives it its own system title bar and then I can put it on other monitors.
If added, this could make 2D panels via Canvas a lot of useful! I can have the sim on one screen, and a radio stack on another, for example, to easily switch radios. Or a lighting panel.<ref>https://sourceforge.net/p/flightgear/mailman/message/36709634/</ref>
== Background ==
== Background ==
Currently, the GUI can only be placed inside one view/window (see Docs/README.multiscreen) but it would be nice to be able to move windows between views.<ref>https://sourceforge.net/p/flightgear/mailman/message/29609330/</ref>
Currently, the GUI can only be placed inside one view/window (see Docs/README.multiscreen) but it would be nice to be able to move windows between views.<ref>https://sourceforge.net/p/flightgear/mailman/message/29609330/</ref>

Revision as of 11:17, 13 June 2020

This article is a stub. You can help the wiki by expanding it.

Motivation

Would it be possible to make the Canvas Windows leave the FlightGear borderspace? Like in P3D, I can right click a window and click “Undock Window”, which then gives it its own system title bar and then I can put it on other monitors.

If added, this could make 2D panels via Canvas a lot of useful! I can have the sim on one screen, and a radio stack on another, for example, to easily switch radios. Or a lighting panel.[1]

Background

Currently, the GUI can only be placed inside one view/window (see Docs/README.multiscreen) but it would be nice to be able to move windows between views.[2]

Problem

It's possible to do, but it's definitely not trivial. There are two showstoppers:[3]

  • Canvas uses nested cameras, not viewer-level slave cameras. You can only assign another GraphicsContext (another window) to slave cameras as nested cameras inherit their GraphicsContext from the main viewer camera. I think Tim Moore mentioned somewhere that he had a patch to move Canvas to slave cameras, but I'm not too sure.
  • CameraGroup hasn't been thought out from the beginning to support dynamic creation of windows. At startup the property tree in /sim/rendering/camera-group is read and the specified windows/cameras are created. I guess supporting this would require some architectural changes to CameraGroup.

References

References