Moved #define's for OpenGL1.2 image formats into the include/osg/Image header

to allow compilation of the rgb plugin under Windows with its 1.1 OGL headers.

Added float.h to Math's compile path for VS7 compilation.
This commit is contained in:
Robert Osfield 2002-08-26 13:04:43 +00:00
parent 0b5c20af8d
commit 59a5e800fe
3 changed files with 23 additions and 17 deletions

View File

@ -13,6 +13,24 @@
#include <string>
#include <vector>
#ifndef GL_VERSION_1_2
/* 1.2 definitions...*/
#define GL_BGR 0x80E0
#define GL_BGRA 0x80E1
#define GL_UNSIGNED_BYTE_3_3_2 0x8032
#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362
#define GL_UNSIGNED_SHORT_5_6_5 0x8363
#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364
#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365
#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366
#define GL_UNSIGNED_INT_8_8_8_8 0x8035
#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367
#define GL_UNSIGNED_INT_10_10_10_2 0x8036
#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368
#endif
namespace osg {
/** Image class for encapsulating the storage texture image data.*/

View File

@ -7,6 +7,11 @@
#include <math.h>
#if defined(_MSC_VER) && (_MSC_VER >= 1300)
#include <float.h>
#endif
#if (defined(WIN32) && !(defined(_MSC_VER) && (_MSC_VER >= 1300)) ) || \
defined (macintosh)|| \
defined (sun) || \

View File

@ -65,23 +65,6 @@ void Image::setFileName(const std::string& fileName)
_fileName = fileName;
}
#ifndef GL_VERSION_1_2
/* 1.2 definitions...*/
#define GL_BGR 0x80E0
#define GL_BGRA 0x80E1
#define GL_UNSIGNED_BYTE_3_3_2 0x8032
#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362
#define GL_UNSIGNED_SHORT_5_6_5 0x8363
#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364
#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365
#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366
#define GL_UNSIGNED_INT_8_8_8_8 0x8035
#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367
#define GL_UNSIGNED_INT_10_10_10_2 0x8036
#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368
#endif
const bool Image::isPackedType(GLenum type)
{