diff options
-rw-r--r-- | graphics/video/coktel_decoder.cpp | 7 | ||||
-rw-r--r-- | graphics/video/coktel_decoder.h | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/graphics/video/coktel_decoder.cpp b/graphics/video/coktel_decoder.cpp index 629e01c2b5..8e8c6f9e93 100644 --- a/graphics/video/coktel_decoder.cpp +++ b/graphics/video/coktel_decoder.cpp @@ -71,6 +71,13 @@ void CoktelDecoder::setSurfaceMemory() { _ownSurface = true; } +const Surface *CoktelDecoder::getSurface() const { + if (!isVideoLoaded()) + return 0; + + return &_surface; +} + bool CoktelDecoder::hasSurface() { return _surface.pixels != 0; } diff --git a/graphics/video/coktel_decoder.h b/graphics/video/coktel_decoder.h index 8bba71ebcd..646e55b0bc 100644 --- a/graphics/video/coktel_decoder.h +++ b/graphics/video/coktel_decoder.h @@ -68,6 +68,8 @@ public: /** Reset the video memory. */ void setSurfaceMemory(); + const Surface *getSurface() const; + /** Draw the video starting at this position within the video memory. */ virtual void setXY(uint16 x, uint16 y); /** Draw the video at the default position. */ |