   Problem with SDL.NET 6.1 and glGenTextures
  Using SDL.NET's OpenGL functions, I try to generate several textures like this:int[] textures = new int[5];    //array space for five unique texturesGl.glGenTextures(5, textures);  //attempt to generate 5 texture namesforeach(int i in textures)    Console.WriteLine(i);  //print out the integersThe problem here is that when I print out the integers, they are all the same number and it becomes impossible to use more than one texture at a time without constant overwriting and the performance loss that causes.  In SDL.NET, the output would be 0 0 0 0 0, whereas in Pygame or SDL, it would be 0 1 2 3 4.  Even using the overloaded version of glGenTextures that takes an IntPtr type instead of int[], the only output given is 0.  What could be causing this?   
  Do you create an opengl context before calling glGenTextures?   ;  I didn't think I'd have to explicitly create an OpenGL context -- doesn't the SetVideoMode constuctor do that automatically when the opengl argument is set to true?.  Besides, as my code is now, everything in GL works (that is: glBegin, glEnd, glVertex, glTexCoord, etc).  The problem here is that I only get one texture name when there should be more.  Similar code in either SDL or Pygame produces the correct effect so I don't know why it does something else with SDL.NET in use.  As far as I can tell from cs-sdl.sourceforge.net, there's no bug report on it.   ;  Do you call SetVideoMode before glGenTextures? Also is your application multithreaded? Do you have a minimal program that demonstrated the problem?;  All calls to OpenGL come after SetVideoMode returns the video surface.  The code itself is mostly taken from the NeHe texture loading code that comes with the SDL.NET SDK (tutorial #6 or 8).  The application currently only uses one thread and I've never even considered multithreading.   ;  Apparently, the GL calls were going before SetVideoMode was called...using static classes means the objects were being created when the first function of the static class was called rather than at some earlier time as I had thought.  The problem was really that I didn't know how static classes work compared to non-static classes (and that it's just being brought up now).  Thanks for helping!   