Add plumbing for mod-defined sprite loaders.

This commit is contained in:
Paul Chote
2014-10-05 15:01:45 +13:00
parent ad0da91ecc
commit 9cf8328979
8 changed files with 54 additions and 19 deletions

View File

@@ -14,20 +14,6 @@ using OpenRA.FileFormats;
namespace OpenRA.Graphics
{
public interface ISpriteFrame
{
Size Size { get; }
Size FrameSize { get; }
float2 Offset { get; }
byte[] Data { get; }
bool DisableExportPadding { get; }
}
public interface ISpriteSource
{
IReadOnlyList<ISpriteFrame> Frames { get; }
}
// TODO: Most of this should be moved into the format parsers themselves.
public enum SpriteType { Unknown, ShpTD, ShpTS, ShpD2, TmpTD, TmpRA, TmpTS, R8 }
public static class SpriteSource