Changeset 1192 for trunk


Ignore:
Timestamp:
Oct 27, 2008 4:23:04 PM (16 years ago)
Author:
gah
Message:

attempt to fix libGLcore segfault by reordering glut initialization routines

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/nanovis.cpp

    r1188 r1192  
    22262226    stats.start = tv;
    22272227
     2228    /* Initialize GLUT here so it can parse and remove GLUT-specific
     2229     * command-line options before we parse the command-line below. */
     2230    glutInit(&argc, argv);
     2231    glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGBA);
     2232    glutInitWindowSize(NanoVis::win_width, NanoVis::win_height);
     2233    glutInitWindowPosition(10, 10);
     2234    glutDisplayFunc(NanoVis::display);
     2235    glutIdleFunc(idle);
     2236    glutReshapeFunc(NanoVis::resize_offscreen_buffer);
     2237#ifndef XINETD
     2238    glutMouseFunc(NanoVis::mouse);
     2239    glutMotionFunc(NanoVis::motion);
     2240    glutKeyboardFunc(NanoVis::keyboard);
     2241#endif
     2242
     2243    render_window = glutCreateWindow(argv[0]);
     2244
     2245
    22282246    while (1) {
    22292247        static struct option long_options[] = {
     
    23292347#endif
    23302348
    2331     glutInit(&argc, argv);
    2332     glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGBA);
    2333 
    2334     glutInitWindowSize(NanoVis::win_width, NanoVis::win_height);
    2335 
    2336     glutInitWindowPosition(10, 10);
    2337     render_window = glutCreateWindow(argv[0]);
    2338     glutDisplayFunc(NanoVis::display);
    2339 
    2340 #ifndef XINETD
    2341     glutMouseFunc(NanoVis::mouse);
    2342     glutMotionFunc(NanoVis::motion);
    2343     glutKeyboardFunc(NanoVis::keyboard);
    2344 #endif
    2345 
    2346     glutIdleFunc(idle);
    2347     glutReshapeFunc(NanoVis::resize_offscreen_buffer);
    2348 
    23492349    NanoVis::init(path);
    23502350    if (newPath != NULL) {
Note: See TracChangeset for help on using the changeset viewer.