Add: Allow sprite encoders (blitters) to specify an alignment for sprite width and height.

This commit is contained in:
Michael Lutz
2021-01-16 16:43:29 +01:00
parent 02e8741457
commit e7e5316340
2 changed files with 20 additions and 4 deletions

View File

@@ -82,5 +82,14 @@ public:
* Convert a sprite from the loader to our own format.
*/
virtual Sprite *Encode(const SpriteLoader::Sprite *sprite, AllocatorProc *allocator) = 0;
/**
* Get the value which the height and width on a sprite have to be aligned by.
* @return The needed alignment or 0 if any alignment is accepted.
*/
virtual uint GetSpriteAlignment()
{
return 0;
}
};
#endif /* SPRITELOADER_HPP */