Take the 2-minute tour ×
Graphic Design Stack Exchange is a question and answer site for professional graphic designers and non-designers trying to do their own graphic design. It's 100% free, no registration required.

I am developing a filter in Pixel Bender. It needs me to apply an auto-fix to the image before the filter is applied.

Currently this is my progress in it ->

    dst = sampleNearest(src,outCoord());

    dst.r = ((dst.r - 0.5)*contrast)+ 0.5;
    dst.g = ((dst.g - 0.5)*contrast)+ 0.5;
    dst.b = ((dst.b - 0.5)*contrast)+ 0.5;

    dst.r = dst.r * brightness;
    dst.g = dst.g * brightness;
    dst.b = dst.b * brightness;

Bu the problem here is, in this case I have to manually change the contrast and brightness parameters. How do i apply an auto-fix on this image without having to manually change the parameters.

share|improve this question
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.