weber_ofir
08-27-2000, 12:49 PM
I am using glReadPixels to read each component of the color (R G B) separatly. Now i want to manipulate each one of the component and then, combine them again and use glDrawPixels to update the color buffer. Is anyone know how to combine the component again?
thank you.
You can try to write separated R G B by
using glColorMask.
For instance:
glColorMask(GL_TRUE,GL_FALSE,GL_FALSE,GL_FALSE);
glDrawPixels(...
glColorMask(GL_FALSE,GL_TRUE,GL_FALSE,GL_FALSE);
glDrawPixels(...
glColorMask(GL_FALSE,GL_FALSE,GL_TRUE,GL_FALSE);
glDrawPixels(...
glColorMask(GL_TRUE,GL_TRUE,GL_TRUE,GL_TRUE);
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.