protected override void DrawCore(RenderDrawContext context)
        {
            var renderFrame = context.RenderContext.Tags.Get(RenderFrame.Current);

            context.CommandList.Clear(renderFrame.DepthStencil, DepthStencilClearOptions.DepthBuffer);
            RenderSystem.Draw(context, MainRenderView, PhysicsDebugShapeRenderStage);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// This is called when the game should draw itself.
        /// </summary>
        /// <param name="gameTime">Provides a snapshot of timing values.</param>
        protected override void Draw(GameTime gameTime)
        {
            GraphicsDevice.Clear(Color.CornflowerBlue);

            // TODO: Add your drawing code here
            renderSystem.Draw(gameTime, spriteBatch);
            base.Draw(gameTime);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Called when the game determines it is time to draw a frame.
        /// In stereo mode this method will be called twice to render left and right parts of stereo image.
        /// </summary>
        /// <param name="gameTime"></param>
        /// <param name="stereoEye"></param>
        protected virtual void Draw(GameTime gameTime, StereoEye stereoEye)
        {
            //GIS.Draw(gameTime, stereoEye);

            RenderSystem.Draw(gameTime, stereoEye);

            GraphicsDevice.ResetStates();
            GraphicsDevice.RestoreBackbuffer();
        }
Ejemplo n.º 4
0
        /// <summary>
        /// This is called when the game should draw itself.
        /// </summary>
        /// <param name="gameTime">Provides a snapshot of timing values.</param>
        protected override void Draw(GameTime gameTime)
        {
            RenderSystem.Draw();
            GraphicsService.Instance.Begin(SpriteSortMode.Immediate);
            // GraphicsService.Instance.DrawString(GameContent.Instance.defaultFont, gameTime.ElapsedGameTime.Milliseconds.ToString(), new Vector2(50, 50), Color.White);
            GraphicsService.Instance.DrawString(GameContent.Instance.defaultFont, PhysicsSystem.objects.Count.ToString(), new Vector2(50, 250), Color.White);

            // GraphicsService.Instance.DrawString(GameContent.Instance.defaultFont, phys_time.ToString(), new Vector2(50, 350), Color.White);
            // GraphicsService.Instance.DrawString(GameContent.Instance.defaultFont, elapsed_frames.ToString(), new Vector2(50, 450), Color.White);
            GraphicsService.Instance.End();
            base.Draw(gameTime);
        }
Ejemplo n.º 5
0
 public void Draw(SpriteBatch spritebatch, IDictionary <string, Entity> entities)
 {
     RenderSystem.Draw(entities.Values.ToList(), spritebatch);
 }