Browse Source

Merge pull request #87 from blackberry-gaming/next-setaylor

Next setaylor
Sean Paul Taylor 14 years ago
parent
commit
73b4fd6e9c
3 changed files with 8 additions and 8 deletions
  1. 2 2
      gameplay/src/Image.cpp
  2. 2 2
      gameplay/src/Texture.cpp
  3. 4 4
      gameplay/src/Texture.h

+ 2 - 2
gameplay/src/Image.cpp

@@ -65,11 +65,11 @@ Image* Image::create(const char* path)
     switch (colorType)
     {
     case PNG_COLOR_TYPE_RGBA:
-        image->_format = RGBA;
+        image->_format = Image::RGBA;
         break;
 
     case PNG_COLOR_TYPE_RGB:
-        image->_format = RGB;
+        image->_format = Image::RGB;
         break;
 
     default:

+ 2 - 2
gameplay/src/Texture.cpp

@@ -95,9 +95,9 @@ Texture* Texture::create(Image* image, bool generateMipmaps)
     switch (image->getFormat())
     {
     case Image::RGB:
-        return create(RGB888, image->getWidth(), image->getHeight(), image->getData(), generateMipmaps);
+        return create(Texture::RGB, image->getWidth(), image->getHeight(), image->getData(), generateMipmaps);
     case Image::RGBA:
-        return create(RGBA8888, image->getWidth(), image->getHeight(), image->getData(), generateMipmaps);
+        return create(Texture::RGBA, image->getWidth(), image->getHeight(), image->getData(), generateMipmaps);
     }
     
     return NULL;

+ 4 - 4
gameplay/src/Texture.h

@@ -22,10 +22,10 @@ public:
      */
     enum Format
     {
-        ALPHA = GL_ALPHA,
-        RGB888 = GL_RGB,
-        RGBA8888 = GL_RGBA,
-        DEPTH = GL_DEPTH_COMPONENT
+        RGB     = GL_RGB,
+        RGBA    = GL_RGBA,
+        ALPHA   = GL_ALPHA,
+        DEPTH   = GL_DEPTH_COMPONENT
     };
 
     /**