[Scummvm-cvs-logs] SF.net SVN: scummvm:[34840] scummvm/trunk/engines/cine

buddha_ at users.sourceforge.net buddha_ at users.sourceforge.net
Wed Oct 22 22:45:25 CEST 2008


Revision: 34840
          http://scummvm.svn.sourceforge.net/scummvm/?rev=34840&view=rev
Author:   buddha_
Date:     2008-10-22 20:45:25 +0000 (Wed, 22 Oct 2008)

Log Message:
-----------
Remove unnecessary function overloadings for loadBg16 and loadBg256.

Modified Paths:
--------------
    scummvm/trunk/engines/cine/gfx.cpp
    scummvm/trunk/engines/cine/gfx.h

Modified: scummvm/trunk/engines/cine/gfx.cpp
===================================================================
--- scummvm/trunk/engines/cine/gfx.cpp	2008-10-22 20:29:17 UTC (rev 34839)
+++ scummvm/trunk/engines/cine/gfx.cpp	2008-10-22 20:45:25 UTC (rev 34840)
@@ -585,7 +585,8 @@
 /*! \brief Load background into renderer
  * \param bg Raw background data
  */
-void FWRenderer::loadBg16(const byte *bg, const char *name) {
+void FWRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
+	assert(idx == 0);
 	int i;
 
 	if (!_background) {
@@ -609,24 +610,12 @@
 
 /*! \brief Placeholder for Operation Stealth implementation
  */
-void FWRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
-	error("Future Wars renderer doesn't support multiple backgrounds");
-}
-
-/*! \brief Placeholder for Operation Stealth implementation
- */
 void FWRenderer::loadCt16(const byte *ct, const char *name) {
 	error("Future Wars renderer doesn't support multiple backgrounds");
 }
 
 /*! \brief Placeholder for Operation Stealth implementation
  */
-void FWRenderer::loadBg256(const byte *bg, const char *name) {
-	error("Future Wars renderer doesn't support 256 color mode");
-}
-
-/*! \brief Placeholder for Operation Stealth implementation
- */
 void FWRenderer::loadBg256(const byte *bg, const char *name, unsigned int idx) {
 	error("Future Wars renderer doesn't support multiple backgrounds");
 }
@@ -1281,14 +1270,6 @@
 /*! \brief Load 16 color background into renderer
  * \param bg Raw background data
  * \param name Background filename
- */
-void OSRenderer::loadBg16(const byte *bg, const char *name) {
-	loadBg16(bg, name, 0);
-}
-
-/*! \brief Load 16 color background into renderer
- * \param bg Raw background data
- * \param name Background filename
  * \param pos Background index
  */
 void OSRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
@@ -1328,14 +1309,6 @@
 /*! \brief Load 256 color background into renderer
  * \param bg Raw background data
  * \param name Background filename
- */
-void OSRenderer::loadBg256(const byte *bg, const char *name) {
-	loadBg256(bg, name, 0);
-}
-
-/*! \brief Load 256 color background into renderer
- * \param bg Raw background data
- * \param name Background filename
  * \param pos Background index
  */
 void OSRenderer::loadBg256(const byte *bg, const char *name, unsigned int idx) {

Modified: scummvm/trunk/engines/cine/gfx.h
===================================================================
--- scummvm/trunk/engines/cine/gfx.h	2008-10-22 20:29:17 UTC (rev 34839)
+++ scummvm/trunk/engines/cine/gfx.h	2008-10-22 20:45:25 UTC (rev 34840)
@@ -100,11 +100,9 @@
 	virtual void incrustMask(const objectStruct &obj, uint8 color = 0);
 	virtual void incrustSprite(const objectStruct &obj);
 
-	virtual void loadBg16(const byte *bg, const char *name);
-	virtual void loadBg16(const byte *bg, const char *name, unsigned int idx);
+	virtual void loadBg16(const byte *bg, const char *name, unsigned int idx = 0);
 	virtual void loadCt16(const byte *ct, const char *name);
-	virtual void loadBg256(const byte *bg, const char *name);
-	virtual void loadBg256(const byte *bg, const char *name, unsigned int idx);
+	virtual void loadBg256(const byte *bg, const char *name, unsigned int idx = 0);
 	virtual void loadCt256(const byte *ct, const char *name);
 	virtual void selectBg(unsigned int idx);
 	virtual void selectScrollBg(unsigned int idx);
@@ -159,11 +157,9 @@
 	void incrustMask(const objectStruct &obj, uint8 color = 0);
 	void incrustSprite(const objectStruct &obj);
 
-	void loadBg16(const byte *bg, const char *name);
-	void loadBg16(const byte *bg, const char *name, unsigned int idx);
+	void loadBg16(const byte *bg, const char *name, unsigned int idx = 0);
 	void loadCt16(const byte *ct, const char *name);
-	void loadBg256(const byte *bg, const char *name);
-	void loadBg256(const byte *bg, const char *name, unsigned int idx);
+	void loadBg256(const byte *bg, const char *name, unsigned int idx = 0);
 	void loadCt256(const byte *ct, const char *name);
 	void selectBg(unsigned int idx);
 	void selectScrollBg(unsigned int idx);


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