{
//! Reset unpack alignment settings to safe values
- void Reset()
+ static void Reset()
{
glPixelStorei (GL_UNPACK_ALIGNMENT, 1);
#if !defined(GL_ES_VERSION_2_0)
#endif
}
+ OpenGl_UnpackAlignmentSentry() {}
+
~OpenGl_UnpackAlignmentSentry()
{
Reset();
myTextFormat = theFormat.Format();
mySizedFormat = theFormat.Internal();
+ // setup the alignment
+ OpenGl_UnpackAlignmentSentry::Reset();
+
glTexImage2D (GL_PROXY_TEXTURE_RECTANGLE, 0, mySizedFormat,
aSizeX, aSizeY, 0,
myTextFormat, GL_FLOAT, NULL);
mySizedFormat = theTextFormat;
+ // setup the alignment
+ OpenGl_UnpackAlignmentSentry::Reset();
+
#if !defined (GL_ES_VERSION_2_0)
theCtx->core15fwd->glTexImage3D (GL_PROXY_TEXTURE_3D, 0, mySizedFormat,
aSizeX, aSizeY, aSizeZ, 0,