+void gSDLDC::setResolution(int xres, int yres)
+{
+ pushEvent(EV_SET_VIDEO_MODE, (void *)xres, (void *)yres);
+}
+
+/*
+ * SDL thread below...
+ */
+
+void gSDLDC::evSetVideoMode(unsigned long xres, unsigned long yres)
+{
+ m_screen = SDL_SetVideoMode(xres, yres, 32, SDL_HWSURFACE);
+ if (!m_screen) {
+ eFatal("Could not create SDL surface: %s", SDL_GetError());
+ return;
+ }
+
+ m_surface.x = m_screen->w;
+ m_surface.y = m_screen->h;
+ m_surface.bpp = m_screen->format->BitsPerPixel;
+ m_surface.bypp = m_screen->format->BytesPerPixel;
+ m_surface.stride = m_screen->pitch;
+ m_surface.data = m_screen->pixels;
+
+ SDL_EnableUNICODE(1);
+}
+
+void gSDLDC::evFlip()
+{
+ SDL_Flip(m_screen);
+}
+
+void gSDLDC::thread()
+{
+ hasStarted();