[Scummvm-cvs-logs] SF.net SVN: scummvm:[46609] scummvm/trunk/engines/sci/engine

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Sun Dec 27 02:49:39 CET 2009


Revision: 46609
          http://scummvm.svn.sourceforge.net/scummvm/?rev=46609&view=rev
Author:   thebluegr
Date:     2009-12-27 01:49:39 +0000 (Sun, 27 Dec 2009)

Log Message:
-----------
Now using m_kiewitz's picture code to show pictures in SCI32. Also took some bits off a similar patch from clone2727. The Sierra logo screen and the menu screen in GK1 should now be shown fully!

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kernel32.cpp
    scummvm/trunk/engines/sci/engine/script.cpp
    scummvm/trunk/engines/sci/engine/vm.h

Modified: scummvm/trunk/engines/sci/engine/kernel32.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kernel32.cpp	2009-12-26 23:49:41 UTC (rev 46608)
+++ scummvm/trunk/engines/sci/engine/kernel32.cpp	2009-12-27 01:49:39 UTC (rev 46609)
@@ -675,18 +675,18 @@
 
 reg_t kAddPlane(EngineState *s, int argc, reg_t *argv) {
 	reg_t picObj = argv[0];
-	// This kernel call shows pictures on screen
-	// The picture ID is likely in the "picture" selector (?)
 
 	// TODO
 
+	// The picture selector usually doesn't hold the actual picture at this point. It's filled in
+	// when kUpdatePlane is called
+
 	warning("kAddPlane object %04x:%04x", PRINT_REG(picObj));
 	return NULL_REG;
 }
 
 reg_t kDeletePlane(EngineState *s, int argc, reg_t *argv) {
 	reg_t picObj = argv[0];
-	// The picture ID is likely in the "picture" selector (?)
 
 	// TODO
 
@@ -696,17 +696,18 @@
 
 reg_t kUpdatePlane(EngineState *s, int argc, reg_t *argv) {
 	reg_t picObj = argv[0];
-	// The picture ID is likely in the "picture" selector (?)
+	int16 picNum = GET_SEL32V(s->_segMan, picObj, picture);
 
-	// TODO
+	if (picNum > -1) {
+		s->_gui->drawPicture(picNum, 100, false, false, false, 0);
+		s->_gui->animateShowPic();
+	}
 
-	warning("kUpdatePlane object %04x:%04x", PRINT_REG(picObj));
-	return NULL_REG;
+	return s->r_acc;
 }
 
 reg_t kRepaintPlane(EngineState *s, int argc, reg_t *argv) {
 	reg_t picObj = argv[0];
-	// The picture ID is likely in the "picture" selector (?)
 
 	// TODO
 

Modified: scummvm/trunk/engines/sci/engine/script.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/script.cpp	2009-12-26 23:49:41 UTC (rev 46608)
+++ scummvm/trunk/engines/sci/engine/script.cpp	2009-12-27 01:49:39 UTC (rev 46609)
@@ -240,6 +240,7 @@
 
 #ifdef ENABLE_SCI32
 	FIND_SELECTOR(data);
+	FIND_SELECTOR(picture);
 #endif
 }
 

Modified: scummvm/trunk/engines/sci/engine/vm.h
===================================================================
--- scummvm/trunk/engines/sci/engine/vm.h	2009-12-26 23:49:41 UTC (rev 46608)
+++ scummvm/trunk/engines/sci/engine/vm.h	2009-12-27 01:49:39 UTC (rev 46609)
@@ -198,6 +198,7 @@
 	
 #ifdef ENABLE_SCI32
 	Selector data; // Used by Array()
+	Selector picture; // Used to hold the picture ID for SCI32 pictures
 #endif
 };
 


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