I've been using SDL for a couple of weeks now (almost finished with a pacman clone). I'm wanting to get into OpenGL a little bit (d/led and isntalled the Mesa3D library). I went to sdl's site and found a small example of using sdl to create an opengl surface to draw on.
These are the files that it includes:
Code:
#include <SDL/SDL.h>
#include <GL/gl.h>
#include <GL/glu.h>
#include <stdio.h>
#include <stdlib.h>
This is what's confusing me:
g++ -o test test.cpp -L/usr/X11R6/lib
-lglut `sdl-config --cflags --libs`
If I don't link glut I get errors. This doesn't make any sense to me because I thought SDL and glut were totally unrelated. Can someone shed some light on this for me?