Пример #1
0
        public override void Draw(GameTime time, SpriteBatch spriteBatch)
        {
            GraphicsDevice graphicsDevice = spriteBatch.GraphicsDevice;

            graphicsDevice.Clear(Color.CornflowerBlue);

            foreach (var o in Objs)
            {
                Color c = o.Flagged ? Color.Red : Color.Black;
                GraphicsUtils.DrawRectangle(o.Span.XMin, o.Span.XMax, o.Span.YMin, o.Span.YMax, c);
            }

            drawTree(QT);


            if (qactive)
            {
                var qfix = query;
                qfix.FixBoundOrder(); //don't mess with query itself, since the interaction code will mess up.
                GraphicsUtils.DrawRectangleTop(qfix.XMin, qfix.XMax, qfix.YMin, qfix.YMax, Color.FromNonPremultiplied(255, 0, 0, 127));
            }
        }