Avoid calling glutInit() on Mac platforms since this causes an error saying that glut is being initialized twice
git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@334 fdac6126-5c0c-442c-9429-916003d36597
This commit is contained in:
@@ -70,7 +70,9 @@ int main(int argc, char **argv)
|
|||||||
QApplication::setColorSpec( QApplication::CustomColor );
|
QApplication::setColorSpec( QApplication::CustomColor );
|
||||||
QApplication app(argc,argv);
|
QApplication app(argc,argv);
|
||||||
|
|
||||||
|
#if !defined(__APPLE__)
|
||||||
glutInit(&argc,argv);
|
glutInit(&argc,argv);
|
||||||
|
#endif
|
||||||
|
|
||||||
if ( !QGLFormat::hasOpenGL() ) {
|
if ( !QGLFormat::hasOpenGL() ) {
|
||||||
QString msg = "System has no OpenGL support!";
|
QString msg = "System has no OpenGL support!";
|
||||||
|
|||||||
@@ -68,8 +68,9 @@ int main(int argc, char **argv)
|
|||||||
// OpenGL check
|
// OpenGL check
|
||||||
QApplication::setColorSpec( QApplication::CustomColor );
|
QApplication::setColorSpec( QApplication::CustomColor );
|
||||||
QApplication app(argc,argv);
|
QApplication app(argc,argv);
|
||||||
|
#if !defined(__APPLE__)
|
||||||
glutInit(&argc,argv);
|
glutInit(&argc,argv);
|
||||||
|
#endif
|
||||||
|
|
||||||
if ( !QGLFormat::hasOpenGL() ) {
|
if ( !QGLFormat::hasOpenGL() ) {
|
||||||
QString msg = "System has no OpenGL support!";
|
QString msg = "System has no OpenGL support!";
|
||||||
|
|||||||
@@ -62,7 +62,9 @@ int main(int argc, char **argv)
|
|||||||
QApplication::setColorSpec( QApplication::CustomColor );
|
QApplication::setColorSpec( QApplication::CustomColor );
|
||||||
QApplication app(argc,argv);
|
QApplication app(argc,argv);
|
||||||
|
|
||||||
|
#if !defined(__APPLE__)
|
||||||
glutInit(&argc,argv);
|
glutInit(&argc,argv);
|
||||||
|
#endif
|
||||||
|
|
||||||
if ( !QGLFormat::hasOpenGL() ) {
|
if ( !QGLFormat::hasOpenGL() ) {
|
||||||
QString msg = "System has no OpenGL support!";
|
QString msg = "System has no OpenGL support!";
|
||||||
|
|||||||
@@ -62,7 +62,9 @@ int main(int argc, char **argv)
|
|||||||
QApplication::setColorSpec( QApplication::CustomColor );
|
QApplication::setColorSpec( QApplication::CustomColor );
|
||||||
QApplication app(argc,argv);
|
QApplication app(argc,argv);
|
||||||
|
|
||||||
|
#if !defined(__APPLE__)
|
||||||
glutInit(&argc,argv);
|
glutInit(&argc,argv);
|
||||||
|
#endif
|
||||||
|
|
||||||
if ( !QGLFormat::hasOpenGL() ) {
|
if ( !QGLFormat::hasOpenGL() ) {
|
||||||
std::cerr << "This system has no OpenGL support.\n";
|
std::cerr << "This system has no OpenGL support.\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user