-/* $Id: multipal.c,v 1.3 2002/10/18 13:23:19 brianp Exp $ */
/*
* Test multitexture and paletted textures.
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <stddef.h> /* for ptrdiff_t, referenced by GL.h when GL_GLEXT_LEGACY defined */
#ifdef _WIN32
#include <windows.h>
#endif
#define GL_GLEXT_LEGACY
+#include <GL/glew.h>
#include <GL/glut.h>
#include "../util/readtex.c" /* I know, this is a hack. */
static void load_tex(const char *fname, int channel)
{
GLubyte *image;
- GLenum format, type;
+ GLenum format;
GLint w, h;
GLubyte *grayImage;
int i;
glutInitWindowPosition( 0, 0 );
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE );
glutCreateWindow(argv[0] );
+ glewInit();
Init( argc, argv );