0 opengl
我在这里做错了吗?
我在整个屏幕上绘制一个四边形 glRectf( -1, -1, 1, 1 )
我的程序的FPS大约下降了5000.
这是我的OpenGL初始化:
glMatrixMode( GL_PROJECTION );
glLoadIdentity();
glViewport( 0, 0, width, height );
glOrtho( 1, -1, 1, -1, 1, -1 );
glMatrixMode( GL_MODELVIEW );
glDisable( GL_DEPTH_TEST );
Run Code Online (Sandbox Code Playgroud)
1920x1080是很多像素.对于Travis G建议的代码片段,7-11 fps似乎相当快:
for (int i = 0; i < 1000; ++i)
glRectf(-1, -1, 1, 1);
Run Code Online (Sandbox Code Playgroud)
我们来算一算:
1920*1080*1000*11像素/ 1秒= 22.8 Gpix/s
维基百科有ATI卡的标题数据表:http://en.wikipedia.org/wiki/Comparison_of_AMD_graphics_processing_units和nVidia卡:http://en.wikipedia.org/wiki/Comparison_of_Nvidia_graphics_processing_units
我猜你有一台Radeon HD 5850只是因为它们很受欢迎并且数字合适(5850显然有23 Gpix/s填充率)