Allow SheetBuilder to throw an exception on sheet overflow.

This removes unnecessary checks from TerrainRenderer
and will be used in the voxel renderer.
This commit is contained in:
Paul Chote
2013-05-06 19:46:00 +12:00
parent c13c989fe8
commit 891158ca44
5 changed files with 44 additions and 47 deletions

View File

@@ -96,9 +96,8 @@ namespace OpenRA.Graphics
face.LoadGlyph(index, LoadFlags.Default, LoadTarget.Normal);
face.Glyph.RenderGlyph(RenderMode.Normal);
var s = builder.Allocate(
new Size((int)face.Glyph.Metrics.Width >> 6,
(int)face.Glyph.Metrics.Height >> 6));
var size = new Size((int)face.Glyph.Metrics.Width >> 6, (int)face.Glyph.Metrics.Height >> 6);
var s = builder.Allocate(size, true);
var g = new GlyphInfo
{