From e8f9332af940685e735bfdd9ae1f945a06a5a00e Mon Sep 17 00:00:00 2001 From: truelight Date: Thu, 21 Jun 2007 13:31:41 +0000 Subject: (svn r10244) -Fix: make sure to let 32bpp-anim report the increased buffer-size it needs --- src/blitter/32bpp_anim.cpp | 5 +++++ src/blitter/32bpp_anim.hpp | 1 + 2 files changed, 6 insertions(+) (limited to 'src/blitter') diff --git a/src/blitter/32bpp_anim.cpp b/src/blitter/32bpp_anim.cpp index 1ccd2b7a9..578f0d35b 100644 --- a/src/blitter/32bpp_anim.cpp +++ b/src/blitter/32bpp_anim.cpp @@ -244,6 +244,11 @@ void Blitter_32bppAnim::ScrollBuffer(void *video, int &left, int &top, int &widt Blitter_32bppBase::ScrollBuffer(video, left, top, width, height, scroll_x, scroll_y); } +int Blitter_32bppAnim::BufferSize(int width, int height) +{ + return width * height * (sizeof(uint32) + sizeof(uint8)); +} + void Blitter_32bppAnim::PaletteAnimate(uint start, uint count) { uint8 *anim = this->anim_buf; diff --git a/src/blitter/32bpp_anim.hpp b/src/blitter/32bpp_anim.hpp index 426434d9b..c40db1828 100644 --- a/src/blitter/32bpp_anim.hpp +++ b/src/blitter/32bpp_anim.hpp @@ -29,6 +29,7 @@ public: /* virtual */ void CopyFromBuffer(void *video, const void *src, int width, int height); /* virtual */ void CopyToBuffer(const void *video, void *dst, int width, int height); /* virtual */ void ScrollBuffer(void *video, int &left, int &top, int &width, int &height, int scroll_x, int scroll_y); + /* virtual */ int BufferSize(int width, int height); /* virtual */ void PaletteAnimate(uint start, uint count); /* virtual */ Blitter::PaletteAnimation UsePaletteAnimation(); }; -- cgit v1.2.3-54-g00ecf