mesa: enable GL_EXT_draw_instanced for gles2
[mesa.git] / src / mesa / main / texcompress_fxt1.c
index c5646fbd7a35e26a21498ee4f58f9fe0724fc421..7eedd6e17326306a1748f74a10b24c5dd21bb0d1 100644 (file)
  */
 
 
+#include "errors.h"
 #include "glheader.h"
-#include "imports.h"
+
 #include "image.h"
 #include "macros.h"
 #include "mipmap.h"
 #include "texcompress.h"
 #include "texcompress_fxt1.h"
 #include "texstore.h"
+#include "mtypes.h"
 
 
 static void
@@ -130,8 +132,11 @@ _mesa_texstore_rgba_fxt1(TEXSTORE_PARAMS)
       tempImageSlices[0] = (GLubyte *) tempImage;
       _mesa_texstore(ctx, dims,
                      baseInternalFormat,
-                     _mesa_little_endian() ? MESA_FORMAT_R8G8B8A8_UNORM
-                                           : MESA_FORMAT_A8B8G8R8_UNORM,
+#if UTIL_ARCH_LITTLE_ENDIAN
+                     MESA_FORMAT_R8G8B8A8_UNORM,
+#else
+                     MESA_FORMAT_A8B8G8R8_UNORM,
+#endif
                      rgbaRowStride, tempImageSlices,
                      srcWidth, srcHeight, srcDepth,
                      srcFormat, srcType, srcAddr,
@@ -662,7 +667,7 @@ fxt1_quantize_ALPHA1 (GLuint *cc,
            }
            sumL += sum;
        }
-       
+
        nn_comp--;
    }
 
@@ -737,7 +742,7 @@ fxt1_quantize_ALPHA1 (GLuint *cc,
          lolo <<= 2;
          lolo |= texel;
       }
-      
+
       cc[0] = lolo;
    }
 
@@ -1112,7 +1117,7 @@ fxt1_quantize_MIXED0 (GLuint *cc,
          }
          lolo = ~lolo;
       }
-      
+
       cc[0] = lolo;
    }