2021年3月9日星期二

How to scale Image Luminance value in to RGB short Rainbow color Ramp?

I want to Scale my Luminance color image matrix to fit my color ramp, I'm using sigmoidal function to scale up the my matrix but it seems there is problem calculation when ever i change my ramp scale min value to update the Image the sigmoidal output not gives correct value because of the fitting values to my latest Ramp scale range here is my sigmoid function for scaling my values to range of the ramp scale.

double Sigmoid(floot lum)  {      double average = (ramp_max + ramp_min)/2;      double out= (lum - average) ;      out= qExp(- out);      out= 1 / (1 + out);            return out;  }  

please help me to solve the problem if Input Image like this enter image description here

If I change Scale 10 to 100 than expected output is likeenter image description here

but actual output i am getting is like enter image description here

https://stackoverflow.com/questions/66547346/how-to-scale-image-luminance-value-in-to-rgb-short-rainbow-color-ramp March 09, 2021 at 08:58PM

没有评论:

发表评论