Table of Contents

Start Page » Game Development with the Drag[en]gine » Canvas System » Canvas View

Canvas View

Canvas are organized in a tree structure. A canvas view contains 0 or more child canvas rendering them in a determined order. Since canvas are transparent in general they can be easily stacked. The order numbe assigned to child canvas determines the render order. Canvas with lower numbers are rendered underneath canvas with higher numbers. If two or more canvas have the same order number the render order is undefined. Child canvas are located relative to the upper left corner of the canvas view. The child position and size are measured in pixels.

Child canvas placement

Child canvas placement.

Root Canvas

Canvas views are the only canvas possible to be used as root canvas. A root canvas is the top level canvas and the starting point of 2D rendering. Root canvas are used in render windows (created automatically), canvas canvas view and dynamic skin canvas renderable. Especially in dynamic skin renderables canvas views allow to define 3D component textures using the canvas system.