clray

changeset 56:e3b4457dc4d2

added glFinish after swap-buffers to make the program absolutely correct in regards to mediating usage of the shared GL/CL texture image
author John Tsiombikas <nuclear@member.fsf.org>
date Mon, 06 Sep 2010 05:40:47 +0100
parents 54a96b738afe
children 14c8ebe8f122
files src/clray.cc
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line diff
     1.1 --- a/src/clray.cc	Sun Sep 05 16:43:55 2010 +0100
     1.2 +++ b/src/clray.cc	Mon Sep 06 05:40:47 2010 +0100
     1.3 @@ -212,6 +212,11 @@
     1.4  	}
     1.5  
     1.6  	glutSwapBuffers();
     1.7 +
     1.8 +	/* We need to make sure OpenGL has finished with the texture
     1.9 +	 * before allowing the OpenCL kernel to run again.
    1.10 +	 */
    1.11 +	glFinish();
    1.12  }
    1.13  
    1.14  void reshape(int x, int y)