diff --git a/src/sp65/bitmap.h b/src/sp65/bitmap.h index bf5e60559..e94ec71fd 100644 --- a/src/sp65/bitmap.h +++ b/src/sp65/bitmap.h @@ -75,6 +75,9 @@ struct Bitmap { unsigned Width; unsigned Height; + /* Bits per pixels */ + unsigned BPP; + /* Palette for indexed bitmap types, otherwise NULL */ Palette* Pal; @@ -179,6 +182,17 @@ INLINE unsigned GetBitmapColors (const Bitmap* B) # define GetBitmapColors(B) ((B)->Pal? (B)->Pal->Count : (1U << 24)) #endif +#if defined(HAVE_INLINE) +INLINE unsigned GetBitmapBPP (const Bitmap* B) +/* Get the bits per pixel of the converted sprite + */ +{ + return B->BPP; +} +#else +# define GetBitmapBPP(B) ((B)->BPP +#endif + /* End of bitmap.h */