226
edits
m (fix up terminology: Canvas::Element is the interface class to be used by all child elements (which are canvas rendering primitives), which are to be registered via the Canvas::Group element)  | 
				 (Added some notes following the hackathon.)  | 
				||
| Line 2: | Line 2: | ||
|title=CompositeViewer and Canvas  | |title=CompositeViewer and Canvas  | ||
|image = Fg-cv-textures2.jpeg  | |image = Fg-cv-textures2.jpeg  | ||
|sponsor=[[User:Cgdae|Cgdae]]  | |sponsor=[[User:Cgdae|Cgdae]], Fernando,  | ||
|supporters=  | |supporters=  | ||
|status=  | |status=  | ||
We came across some tricky issues, but made lots of progress.  | |||
Here's a demo video demonstrating a Canvas View on the panel of a Harrier-GR3 showing a view from the camera pod under the aircraft: [http://op59.net/cvcanvas-demo.ogv].  | |||
We also managed to get a 777 to show an outside view on one of the cockpit displays.  | |||
Things we learnt or talked about:  | |||
* Some issues we came across when making an object in the aircraft model serve as a placement for a Canvas View:  | |||
** The object surface should uses a material with 'emis 1 1 1', otherwise it seems to only shows up when lit up by sunlight. This can be confusing if one is testing while one's aircraft is facing into the sun.  | |||
** When the surface(s) of the object reference vertices, they need to specify differing texture coordinates (not just '0 0' for each vertice reference, otherwise nothing shows up.  | |||
* The textures that Canvas uses are tied to graphics contexts, so aren't shared between windows. This means that extra view windows don't show in-cockpit displays. It was suggested that sharing textures was actually possible, as long as the graphics contexts are on the same GPU.  | |||
* We can't yet change a Canvas View to show a different view, e.g. swap between tail-camera and gear-camera. The underlying CompositeViewer has full support for destroying and creating new views, and Canvas supports adding/removing elements, so hopefully this will be relatively easy to address.  | |||
* Frame rates might be significantly affected even if a Canvas View is only showing a small part of the scene.  | |||
* Apparently it should be possible to make a Canvas View show different affects, such as infra-red vision.  | |||
|summary=[[CompositeViewer Support]] already allows us to create multiple top-level windows showing different views of the same scenery.  | |summary=[[CompositeViewer Support]] already allows us to create multiple top-level windows showing different views of the same scenery.  | ||
edits