因为老的GL中的glutMainLoop函数无法动态刷新显示3D数据,所以试着用了freeglut里面的glutMainLoopEvent()函数,主程序的GL部分是
while(!exit_loop){
load3dDataToGL(&glXYZ); // Load the 3D Point Cloud
loadTextureToGL(&glTexture); // Load the texture data
glutReshapeFunc (reshape); // Reshape the image if windows change
glutDisplayFunc(renderScene); // Display 3D images   
glutMouseFunc(mouse); // Mouse click reaction
glutMotionFunc(motion); // Mouse move reaction
glutPostRedisplay(); // Update the image
glutMainLoopEvent();
}可以成功打开并动态显示3D数据,但是如果最大化窗口,会出现内存不能为read错误。我电脑配置是1+1G的内存,小黑X200的集成显卡不知道是配置问题还是程序问题,还望高手指点!