Paint.GraphicsDisplay.DrawGraphic C# (CSharp) Method

DrawGraphic() public method

Renders a specific image
public DrawGraphic ( ImageType imageType, Rectangle paintRegion, Color color ) : void
imageType ImageType Type of image we want to render
paintRegion Microsoft.Xna.Framework.Rectangle destination rectangle to render the graphic
color Color Colour to use for rendering the image
return void
        public void DrawGraphic(ImageType imageType, Rectangle paintRegion, Color color)
        {
            Rectangle sourceRegion = this.SourceRectangleFromImageType(imageType);

            this.spriteBatch.Draw(this.graphicsTexture, paintRegion, sourceRegion, color);
        }