Vertices Engine  v1.9.2.92
A Cross Platform game engine developed by Virtex Edge Design.
Loading...
Searching...
No Matches
VerticesEngine.Graphics.vxSpriteBatch Class Reference

The sprite batch used by the Vertices Engine to measure and count Batch Calls. This is mostly for profiling and organization as well as allows for extention methods to be created. More...

Inheritance diagram for VerticesEngine.Graphics.vxSpriteBatch:

Public Member Functions

 vxSpriteBatch (GraphicsDevice graphicsDevice)
 Sprite batch.
 
void Begin (string batchCall, SpriteSortMode sortMode=SpriteSortMode.Deferred, BlendState blendState=null, SamplerState samplerState=null, DepthStencilState depthStencilState=null, RasterizerState rasterizerState=null, Effect effect=null, Matrix? transformMatrix=default(Matrix?))
 Begins a new sprite and text batch with the specified render state.
 
new void End ()
 
void DrawString (SpriteFont font, string text, Vector2 position, Color color, float scale, vxHorizontalJustification horizontalJustification=vxHorizontalJustification.Left, vxVerticalJustification verticalJustification=vxVerticalJustification.Top, float rotation=0)
 
void DrawString (SpriteFont font, string text, Vector2 position, Color color, float scale, Vector2 origin)
 

Public Attributes

List< string > BatchCallNames = new List<string>(1024)
 

Properties

int BatchCallCount [get]
 The batch call count.
 

Detailed Description

The sprite batch used by the Vertices Engine to measure and count Batch Calls. This is mostly for profiling and organization as well as allows for extention methods to be created.

Constructor & Destructor Documentation

◆ vxSpriteBatch()

VerticesEngine.Graphics.vxSpriteBatch.vxSpriteBatch ( GraphicsDevice graphicsDevice)

Sprite batch.

Parameters
graphicsDevice

Member Function Documentation

◆ Begin()

void VerticesEngine.Graphics.vxSpriteBatch.Begin ( string batchCall,
SpriteSortMode sortMode = SpriteSortMode::Deferred,
BlendState blendState = null,
SamplerState samplerState = null,
DepthStencilState depthStencilState = null,
RasterizerState rasterizerState = null,
Effect effect = null,
Matrix? transformMatrix = default(Matrix?) )

Begins a new sprite and text batch with the specified render state.

Parameters
sortModeThe drawing order for sprite and text drawing. F:Microsoft.Xna.Framework.Graphics.SpriteSortMode.Deferred by default.
blendStateState of the blending. Uses F:Microsoft.Xna.Framework.Graphics.BlendState.AlphaBlend if null.
samplerStateState of the sampler. Uses F:Microsoft.Xna.Framework.Graphics.SamplerState.LinearClamp if null.
depthStencilStateState of the depth-stencil buffer. Uses F:Microsoft.Xna.Framework.Graphics.DepthStencilState.None if null.
rasterizerStateState of the rasterization. Uses F:Microsoft.Xna.Framework.Graphics.RasterizerState.CullCounterClockwise if null.
effectA custom T:Microsoft.Xna.Framework.Graphics.Effect to override the default sprite effect. Uses default sprite effect if null.
transformMatrixAn optional matrix used to transform the sprite geometry. Uses P:Microsoft.Xna.Framework.Matrix.Identity if null.
Exceptions
T:System.InvalidOperationExceptionThrown if M:Microsoft.Xna.Framework.Graphics.SpriteBatch.Begin(Microsoft.Xna.Framework.Graphics.SpriteSortMode,Microsoft.Xna.Framework.Graphics.BlendState,Microsoft.Xna.Framework.Graphics.SamplerState,Microsoft.Xna.Framework.Graphics.DepthStencilState,Microsoft.Xna.Framework.Graphics.RasterizerState,Microsoft.Xna.Framework.Graphics.Effect,System.Nullable<Microsoft.Xna.Framework.Matrix>) is called next time without previous M:Microsoft.Xna.Framework.Graphics.SpriteBatch.End.

This method uses optional parameters.

The M:Microsoft.Xna.Framework.Graphics.SpriteBatch.Begin(Microsoft.Xna.Framework.Graphics.SpriteSortMode,Microsoft.Xna.Framework.Graphics.BlendState,Microsoft.Xna.Framework.Graphics.SamplerState,Microsoft.Xna.Framework.Graphics.DepthStencilState,Microsoft.Xna.Framework.Graphics.RasterizerState,Microsoft.Xna.Framework.Graphics.Effect,System.Nullable<Microsoft.Xna.Framework.Matrix>) Begin should be called before drawing commands, and you cannot call it again before subsequent M:Microsoft.Xna.Framework.Graphics.SpriteBatch.End.


The documentation for this class was generated from the following file: