Jump to content

  • Log In with Google      Sign In   
  • Create Account


PBO and glBufferSubData


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 MARS_999   Members   -  Reputation: 1264

Like
0Likes
Like

Posted 02 October 2012 - 04:04 PM

//this works....
unsigned char* p = (unsigned char*)glMapBuffer(GL_PIXEL_PACK_BUFFER, GL_READ_ONLY);
	    if(p)
	    {
   memcpy(pixels, p, size);
		    glUnmapBuffer(GL_PIXEL_PACK_BUFFER);
	    }
//this call doesn't
glBufferSubData(GL_PIXEL_PACK_BUFFER, 0, size, pixels);
//doesn't work? why?

Do I need to call glFlush() or glFinish() to use glBufferSubData()? I get a grey texture if I us that vs. the glMapBuffer()....

Thanks!

Sponsor:

#2 MARS_999   Members   -  Reputation: 1264

Like
0Likes
Like

Posted 02 October 2012 - 04:24 PM

ARGH!!!

Forget it!!!

I fat fingered it.....

glGetBufferSubData() was the problem... sigh!!!!




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS