--- stellarium-0.8.2/src/stel_core.cpp~ 2006-11-13 23:06:16.000000000 +0100 +++ stellarium-0.8.2/src/stel_core.cpp 2006-11-13 23:06:16.000000000 +0100 @@ -70,8 +70,6 @@ dataRoot = DATA_ROOT; recordActionCallback = recordCallback; - projection = Projector::create(Projector::PERSPECTIVE_PROJECTOR, Vec4i(0,0,800,600), 60); - glFrontFace(projection->needGlFrontFaceCW()?GL_CW:GL_CCW); tone_converter = new ToneReproductor(); atmosphere = new Atmosphere(); @@ -135,6 +133,10 @@ // Load core data and initialize with default values void StelCore::init(const InitParser& conf) { + // do NOT do this in the constructor as there is no valid GLcontext there! + projection = Projector::create(Projector::PERSPECTIVE_PROJECTOR, Vec4i(0,0,800,600), 60); + glFrontFace(projection->needGlFrontFaceCW()?GL_CW:GL_CCW); + baseFontFile = getDataDir() + conf.get_str("gui", "base_font_name", "DejaVuSans.ttf"); // Video Section