Skip to content

DrawCallColor Class

Draws a colored rectangle to the active SharedSpriteBatch.

C#
public class DrawCallColor : IDrawCall

Inheritance object

Implements IDrawCall

DrawCallColor(Color, Texture2D, Rectangle, Rectangle)

Section titled “DrawCallColor(Color, Texture2D, Rectangle, Rectangle)”

Creates a new instance of this draw call.

C#
public DrawCallColor(Color color, Texture2D texture, Rectangle targetRect, Rectangle fontSolidRect)

color Microsoft.Xna.Framework.Color
The folor of the rectangle.

texture Microsoft.Xna.Framework.Graphics.Texture2D
The texture containing a solid white rectangle referenced by fontSolidRect.

targetRect Microsoft.Xna.Framework.Rectangle
The drawing location of the rectangle.

fontSolidRect Microsoft.Xna.Framework.Rectangle
The rectangle of the solid white glyph in the texture.

The texture, most likely a SadConsole font texture, containing the solid white rectangle referenced by FontSolidRect.

C#
public Texture2D Texture

The solid white glyph rectangle from Texture used for shading.

C#
public Rectangle FontSolidRect

The color of the target rectangle.

C#
public Color Color

Where on the SharedSpriteBatch the glyph should be drawn.

C#
public Rectangle TargetRect

Draws an object.

C#
public void Draw()