glFlush

glFlush

NAME 函数名
glFlush -- force execution of GL commands in finite time 强制GL命令在游戏那的时间内执行
C SPECIFICATION  C格式
void glFlush(void void)

DESCRIPTION 描述
Different GL implementations buffer commands in several different locations, including network buffers and the graphics accelerator itself.

不同的GL实现在不同的地方分配缓冲,包括网络缓冲和图形加速器自身。

glFlush empties all of these buffers, causing all issued commands to be executed as quickly as they are accepted by the actual rendering engine.

 glFlush清空所有这些缓存,让所有已发送的命令尽快的由实际的绘制引擎执行。

 Though this execution may not be completed in any particular time period, it does complete in finite time.

虽然这执行不会再一个特定的时间段里完成,但它确实是在有限的时间内完成

Because any GL program might be executed over a network, or on an accelerator that buffers commands, all programs should call glFlush whenever they count on having all of their previously issued commands completed.

因为任何GL程序可能通过网络或者缓冲命令的加速器执行,所以所有的程序应该在每当统计的先前已发送的命令完成的时候去调用glFlush。

For example, call glFlush before waiting for user input that depends on the generated image.

例如,在等待用户输入产生的图像前调用glFlush.。(这个英语原句没有语法错误,但是逻辑的呢?)

NOTES

注意

glFlush can return at any time.

glFlush可以在任何时候返回。

It does not wait until the execution of all previously issued GL commands is complete.

它确实不用等到所有先前发送的GL命令都完成。

ERRORS

错误

GL_INVALID_OPERATION is generated if glFlush is called between a call to glBegin and the corresponding call to glEnd.

如果glFlush在glBegin的调用和与glBegin相应的glEnd调用之间被调用,那么就会产生GL_INVALID_OPERATION。

SEE ALSO
glFinish

参见glFinish

你可能感兴趣的:(sh)