Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
GLXSWAPBUFFERS()					      GLXSWAPBUFFERS()

NAME
       glXSwapBuffers -	exchange front and back	buffers

C SPECIFICATION
       void glXSwapBuffers( Display *dpy,
			    GLXDrawable	drawable )

       delim $$

PARAMETERS
       dpy	 Specifies the connection to the X server.

       drawable	 Specifies the drawable	whose buffers are to be	swapped.

DESCRIPTION
       glXSwapBuffers  promotes	the contents of	the back buffer	of drawable to
       become the contents of the front	buffer of drawable.  The  contents  of
       the  back  buffer  then	become	undefined.  The	update typically takes
       place during the	vertical retrace of the	monitor, rather	 than  immedi-
       ately after glXSwapBuffers is called.

       glXSwapBuffers  performs	an implicit glFlush before it returns.	Subse-
       quent OpenGL commands may be issued immediately after calling  glXSwap-
       Buffers,	but are	not executed until the buffer exchange is completed.

       If  drawable  was not created with respect to a double-buffered visual,
       glXSwapBuffers has no effect, and no error is generated.

NOTES
       The contents of the back	buffer become undefined	 after	a  swap.  Note
       that this applies to pbuffers as	well as	windows.

       All  GLX	 rendering  contexts  share the	same notion of which are front
       buffers and which are back buffers.  One	consequence is that when  mul-
       tiple  clients are rendering to the same	double-buffered	window,	all of
       them should finish rendering before one of them issues the  command  to
       swap  buffers.	The clients are	responsible for	implementing this syn-
       chronization.  Typically	this is	accomplished by	executing glFinish and
       then using a semaphore in shared	memory to rendezvous before swapping.

ERRORS
       GLXBadDrawable is generated if drawable is not a	valid GLX drawable.

       GLXBadCurrentWindow  is	generated if dpy and drawable are respectively
       the display and drawable	associated with	the  current  context  of  the
       calling	thread,	 and  drawable	identifies  a window that is no	longer
       valid.

SEE ALSO
       glFlush,	 glXBindSwapBarrierSGIX,  glXJoinSwapGroupSGIX,	 glXSwapInter-
       valSGI

							      GLXSWAPBUFFERS()

NAME | C SPECIFICATION | PARAMETERS | DESCRIPTION | NOTES | ERRORS | SEE ALSO

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=glXSwapBuffers&sektion=3&manpath=FreeBSD+13.0-RELEASE+and+Ports>

home | help