[Scummvm-cvs-logs] SF.net SVN: scummvm:[55317] scummvm/trunk/graphics/video/coktel_decoder.cpp

drmccoy at users.sourceforge.net drmccoy at users.sourceforge.net
Wed Jan 19 01:16:13 CET 2011


Revision: 55317
          http://scummvm.svn.sourceforge.net/scummvm/?rev=55317&view=rev
Author:   drmccoy
Date:     2011-01-19 00:16:13 +0000 (Wed, 19 Jan 2011)

Log Message:
-----------
VIDEO: Don't assert() when a needed codec isn't compiled in

Modified Paths:
--------------
    scummvm/trunk/graphics/video/coktel_decoder.cpp

Modified: scummvm/trunk/graphics/video/coktel_decoder.cpp
===================================================================
--- scummvm/trunk/graphics/video/coktel_decoder.cpp	2011-01-18 21:32:18 UTC (rev 55316)
+++ scummvm/trunk/graphics/video/coktel_decoder.cpp	2011-01-19 00:16:13 UTC (rev 55317)
@@ -2622,9 +2622,15 @@
 }
 
 PixelFormat VMDDecoder::getPixelFormat() const {
-	if (_externalCodec && _codec)
-		return _codec->getPixelFormat();
+	if (_externalCodec) {
+		if (_codec)
+			return _codec->getPixelFormat();
 
+		// If we don't have the needed codec, just assume it's in the
+		// current screen format
+		return g_system->getScreenFormat();
+	}
+
 	if (_blitMode > 0)
 		return g_system->getScreenFormat();
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list