Метод | Описание | |
---|---|---|
DrawRectangle ( this batch, |
Draws a rectangle with given location, size, color, and border width.
|
|
DrawRectangle ( this batch, int x, int y, int width, int height, Microsoft.Xna.Framework.Color color, int border = 1 ) : void |
Draws a rectangle with given location, size, color, and border width.
|
|
DrawSelectionRect ( this batch, |
Draws a bordered selection rectangle around the given rectangle.
|
|
DrawString ( this batch, string text, |
Draws the specified string using the given font and location. Without the use of a ContentPipeline, it is necessary to use GDI+ to draw the font onto a bitmap and transfer it to a texture. |
|
FillRectangle ( this batch, |
Draws and fills a rectangle with given location, size, and color.
|
|
FillRectangle ( this batch, int x, int y, int width, int height, Microsoft.Xna.Framework.Color color ) : void |
Draws and fills a rectangle with given location, size, and color.
|
|
FillTriangle ( this batch, Vector2 p1, Vector2 p2, Vector2 p3, Microsoft.Xna.Framework.Color color ) : void |
Draws and fills a triangle using the given points and color.
|
|
ToImage ( this texture ) : Image |
Converts a Texture2D to an System.Drawing.Image and returns it.
|
|
ToSystemColor ( this color ) : System.Drawing.Microsoft.Xna.Framework.Color |
Converts and returns a Microsoft.Xna.Framework.Color to a System.Drawing.Color.
|
|
ToSystemRect ( this rect ) : System.Drawing.Microsoft.Xna.Framework.Rectangle |
Converts a Microsoft.Xna.Framework.Rectangle to a System.Drawing.Rectangle and returns it.
|
|
ToTexture ( this image, GraphicsDevice device ) : Microsoft.Xna.Framework.Graphics.Texture2D |
Converts a Image to a Texture2D and returns it.
|
|
ToXnaColor ( this color ) : Microsoft.Xna.Framework.Color |
Converts and returns a System.Drawing.Color to a Microsoft.Xna.Framework.Color.
|
|
ToXnaRect ( this rect ) : |
Converts a System.Drawing.Rectangle to a Microsoft.Xna.Framework.Rectangle and returns it.
|
public static DrawRectangle ( this batch, |
||
batch | this | SpriteBatch to draw the rectangle. |
rect | Rectangle to draw. | |
color | Microsoft.Xna.Framework.Color | Color to draw rectangle. |
border | int | Width of the border in pixels |
Результат | void |
public static DrawRectangle ( this batch, int x, int y, int width, int height, Microsoft.Xna.Framework.Color color, int border = 1 ) : void | ||
batch | this | SpriteBatch to draw the rectangle. |
x | int | Coordinate of the rectangle on the x-axis |
y | int | Coordinate of the rectangle on the y-axis |
width | int | Width of the rectangle in pixels |
height | int | Height of the rectangle in pixels |
color | Microsoft.Xna.Framework.Color | Color of the rectangle border |
border | int | Width of the border in pixels |
Результат | void |
public static DrawSelectionRect ( this batch, |
||
batch | this | SpriteBatch to draw the rectangle. |
rect | Rectangle to draw | |
color | Microsoft.Xna.Framework.Color | Color of the rectangle border |
thickness | int | Thickness, in pixels, of the inner selection rectangle |
Результат | void |
public static DrawString ( this batch, string text, |
||
batch | this | SpriteBatch to draw the string |
text | string | Text to draw |
font | Font to draw text with. | |
color | Microsoft.Xna.Framework.Color | Color of the text. |
rect | Rectangle where text will be drawn. | |
Результат | void |
public static FillRectangle ( this batch, |
||
batch | this | SpriteBatch to draw the rectangle. |
rect | Rectangle to draw | |
color | Microsoft.Xna.Framework.Color | Color of the rectangle border |
Результат | void |
public static FillRectangle ( this batch, int x, int y, int width, int height, Microsoft.Xna.Framework.Color color ) : void | ||
batch | this | SpriteBatch to draw the rectangle. |
x | int | Coordinate of the rectangle on the x-axis |
y | int | Coordinate of the rectangle on the y-axis |
width | int | Width of the rectangle in pixels |
height | int | Height of the rectangle in pixels |
color | Microsoft.Xna.Framework.Color | Color of the rectangle border |
Результат | void |
public static FillTriangle ( this batch, Vector2 p1, Vector2 p2, Vector2 p3, Microsoft.Xna.Framework.Color color ) : void | ||
batch | this | SpriteBatch to draw triangle |
p1 | Vector2 | First point |
p2 | Vector2 | Second point |
p3 | Vector2 | Third point |
color | Microsoft.Xna.Framework.Color | Color to fill triangle |
Результат | void |
public static ToImage ( this texture ) : Image | ||
texture | this | Texture to convert |
Результат | Image |
public static ToSystemColor ( this color ) : System.Drawing.Microsoft.Xna.Framework.Color | ||
color | this | Color to convert. |
Результат | System.Drawing.Microsoft.Xna.Framework.Color |
public static ToSystemRect ( this rect ) : System.Drawing.Microsoft.Xna.Framework.Rectangle | ||
rect | this | Rectangle to convert |
Результат | System.Drawing.Microsoft.Xna.Framework.Rectangle |
public static ToTexture ( this image, GraphicsDevice device ) : Microsoft.Xna.Framework.Graphics.Texture2D | ||
image | this | Image to convert |
device | GraphicsDevice | Texture graphics device |
Результат | Microsoft.Xna.Framework.Graphics.Texture2D |
public static ToXnaColor ( this color ) : Microsoft.Xna.Framework.Color | ||
color | this | Color to convert. |
Результат | Microsoft.Xna.Framework.Color |
public static ToXnaRect ( this rect ) : |
||
rect | this | Rectangle to convert |
Результат |