C# Класс Paint.GraphicsDisplay

GraphicsDisplay class - defines the rectangles for the different images used in the app
Наследование: IGraphicsDisplay
Показать файл Открыть проект

Открытые методы

Метод Описание
BeginRender ( ) : void

Begins the drawing process.

BeginRenderNonPremultiplied ( ) : void

Begins the drawing process - using NonPremultiplied as the color merging option

BeginRenderOpaque ( ) : void

Begins the drawing process - using opaque as the color merging option

DrawGraphic ( ImageType imageType, Rectangle paintRegion, Color color ) : void

Renders a specific image

EndRender ( ) : void

End the current rendering process

GraphicsDisplay ( Microsoft.Xna.Framework.Graphics.Texture2D graphicsTexture, SpriteBatch spriteBatch, bool highResolution ) : System

Initializes a new instance of the Paint.GraphicsDisplay class.

SourceRectangleFromImageType ( ImageType imageType ) : Rectangle

Calculates the area of the texturemap that we need to use for rendering a specific image

Описание методов

BeginRender() публичный Метод

Begins the drawing process.
public BeginRender ( ) : void
Результат void

BeginRenderNonPremultiplied() публичный Метод

Begins the drawing process - using NonPremultiplied as the color merging option
public BeginRenderNonPremultiplied ( ) : void
Результат void

BeginRenderOpaque() публичный Метод

Begins the drawing process - using opaque as the color merging option
public BeginRenderOpaque ( ) : void
Результат void

DrawGraphic() публичный Метод

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
Результат void

EndRender() публичный Метод

End the current rendering process
public EndRender ( ) : void
Результат void

GraphicsDisplay() публичный Метод

Initializes a new instance of the Paint.GraphicsDisplay class.
public GraphicsDisplay ( Microsoft.Xna.Framework.Graphics.Texture2D graphicsTexture, SpriteBatch spriteBatch, bool highResolution ) : System
graphicsTexture Microsoft.Xna.Framework.Graphics.Texture2D The sprite map - all images we need to render
spriteBatch Microsoft.Xna.Framework.Graphics.SpriteBatch Low level rendering class
highResolution bool Is the iPad running in High resolution.
Результат System

SourceRectangleFromImageType() публичный Метод

Calculates the area of the texturemap that we need to use for rendering a specific image
public SourceRectangleFromImageType ( ImageType imageType ) : Rectangle
imageType ImageType Type of image we want to render
Результат Microsoft.Xna.Framework.Rectangle