glPixelTransferf

Hi!
Do you ever use glPixelTransferf(GL_channel_SCALE, …)
I tried to but is extremly slow.
Can you tell me how can I multiply my color with a number greater than 1.
I want the result (Rc, Gc, Gc, Ac) where c>1.
Thanks.

do it multipass:

A * 1.5 = (A * 1) + (A * 0.5)
(A can be red green blue or alpha)

pass1: draw with A=1 , no blending
pass2: glEnable(GL_BLEND);
glBlendFunc(GL_ONE,GL_ONE);
draw with A=0.5

another way:

pass1: draw with A=1.5/2, no blending
pass2: glEnable(GL_BLEND);
glBlendFunc(GL_DST_COLOR,GL_DST_COLOR);
draw with A=1

or:

pass1: draw with A=1.5/2, no blending
pass2: glEnable(GL_BLEND);
glBlendFunc(GL_ONE,GL_ONE);
draw with A=1.5/2

there many other ways, when you consider using extensions… but don’t forget, this values are always clamped in the framebuffer to a maximum of 1, so if you want to accumulate light intensities over several passes that are higher than 1.0 you will probably need to use more than one rendering buffer and add then together in some kind of postprocessing pass…