Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
Terraria.Graphics.TileBatch Class Reference

Classes

struct  SpriteData
 

Public Member Functions

 TileBatch (GraphicsDevice graphicsDevice)
 
void Dispose ()
 
void Begin (RasterizerState rasterizer, Matrix transformation)
 
void Begin ()
 
void Draw (Texture2D texture, Vector2 position, VertexColors colors)
 
void Draw (Texture2D texture, Vector2 position, Rectangle? sourceRectangle, VertexColors colors, Vector2 origin, float scale, SpriteEffects effects)
 
void Draw (Texture2D texture, Vector4 destination, VertexColors colors)
 
void Draw (Texture2D texture, Vector2 position, VertexColors colors, Vector2 scale)
 
void Draw (Texture2D texture, Vector4 destination, Rectangle? sourceRectangle, VertexColors colors)
 
void Draw (Texture2D texture, Vector4 destination, Rectangle? sourceRectangle, VertexColors colors, Vector2 origin, SpriteEffects effects, float rotation)
 
void Draw (Texture2D texture, Rectangle destinationRectangle, Rectangle? sourceRectangle, VertexColors colors)
 
void End ()
 

Private Member Functions

void Allocate ()
 
void FlushRenderState ()
 
unsafe void InternalDraw (Texture2D texture, ref Vector4 destination, bool scaleDestination, ref Rectangle? sourceRectangle, ref VertexColors colors, ref Vector2 origin, SpriteEffects effects, float rotation)
 
void Flush ()
 
unsafe void RenderBatch (Texture2D texture, SpriteData[] sprites, int offset, int count)
 

Static Private Member Functions

static short[] CreateIndexData ()
 

Private Attributes

GraphicsDevice _graphicsDevice
 
SpriteData[] _spriteDataQueue = new SpriteData[2048]
 
Texture2D[] _spriteTextures
 
int _queuedSpriteCount
 
SpriteBatch _spriteBatch
 
DynamicVertexBuffer _vertexBuffer
 
DynamicIndexBuffer _indexBuffer
 
short[] _fallbackIndexData
 
VertexPositionColorTexture[] _vertices = new VertexPositionColorTexture[8192]
 
int _vertexBufferPosition
 

Static Private Attributes

static readonly float[] CORNER_OFFSET_X = new float[4] { 0f, 1f, 1f, 0f }
 
static readonly float[] CORNER_OFFSET_Y = new float[4] { 0f, 0f, 1f, 1f }
 
static Vector2 _vector2Zero
 
static ? Rectangle _nullRectangle
 

Detailed Description

Definition at line 7 of file TileBatch.cs.


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