Ejemplo n.º 1
0
        /// <summary>Tells that we start drawing , draws the scene-graph ,  and them stops the drawing.</summary>
        /// <param name="gameTime">The game time.</param>
        public void Draw(GameTime gameTime)
        {
            Debug.Assert(this.sceneGraph != null, "SceneGraph can never be null ! Fix this.");

            ImageCompositor.BeginDraw();
            this.sceneGraph.Draw(gameTime);
            ImageCompositor.EndDraw();
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="NodeManager"/> class.
        /// </summary>
        /// <param name="imageCompositor">The image compositor.</param>
        /// <param name="inputManager">The input manager.</param>
        public NodeManager(ImageCompositor imageCompositor, InputManager inputManager)
        {
            this.sceneGraph = new NodeGraph(this);

            this.SceneNodes = new NotDrawnNode("SceneNodes");

            this.ForegroundSceneNodes = new Control("ForegroundSceneNodes")
            {
                Config = { Visible = false }
            };

            this.sceneGraph.RootNode.Children.Add(this.SceneNodes);
            this.sceneGraph.RootNode.Children.Add(this.ForegroundSceneNodes);

            ImageCompositor = imageCompositor;
            InputManager    = inputManager;
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="HorizontalTextStripper"/> class.
 /// </summary>
 /// <param name="imageCompositor">The image compositor.</param>
 public HorizontalTextStripper(ImageCompositor imageCompositor)
 {
     this.imageCompositor = imageCompositor;
 }