test/testdyngles.c
changeset 3139 7f684f249ec9
parent 3099 82e60908fab1
child 3410 f4bc25567731
equal deleted inserted replaced
3125:d71d8ceda8b3 3139:7f684f249ec9
   116     int video_w, video_h;
   116     int video_w, video_h;
   117 
   117 
   118     /* you may want to change these according to the platform */
   118     /* you may want to change these according to the platform */
   119     video_w = 320;
   119     video_w = 320;
   120     video_h = 480;
   120     video_h = 480;
   121     #ifdef __QNXNTO__
   121 #ifdef __QNXNTO__
   122        video_h = 640;
   122     video_h = 640;
   123        video_w = 480;
   123     video_w = 480;
   124     #endif /* __QNXNTO__ */
   124 #endif /* __QNXNTO__ */
   125 
   125 
   126     if (argv[1]) {
   126     if (argv[1]) {
   127         gl_library = argv[1];
   127         gl_library = argv[1];
   128     }
   128     }
   129 
   129 
   151         pixels[3 * i] = rand() % 250 - 125;
   151         pixels[3 * i] = rand() % 250 - 125;
   152         pixels[3 * i + 1] = rand() % 250 - 125;
   152         pixels[3 * i + 1] = rand() % 250 - 125;
   153         pixels[3 * i + 2] = rand() % 250 - 125;
   153         pixels[3 * i + 2] = rand() % 250 - 125;
   154     }
   154     }
   155 
   155 
   156     #ifdef __QNXNTO__
   156 #ifdef __QNXNTO__
   157        f.glViewport(0, 0, video_h, video_w);
   157     f.glViewport(0, 0, video_h, video_w);
   158     #else
   158 #else
   159        f.glViewport(0, 0, video_w, video_h);
   159     f.glViewport(0, 0, video_w, video_h);
   160     #endif /* __QNXNTO__ */
   160 #endif /* __QNXNTO__ */
   161 
   161 
   162     f.glMatrixMode(GL_PROJECTION);
   162     f.glMatrixMode(GL_PROJECTION);
   163     f.glLoadIdentity();
   163     f.glLoadIdentity();
   164     f.glOrthof(-100, 100, -100, 100, -500, 500);
   164     f.glOrthof(-100, 100, -100, 100, -500, 500);
   165 
   165