How do I quantize a three-band color image into a color image using logarithmic function in MATLAB -


the logarithmic function i' =c*ln (i+1) (for each band), original value (0~255), i' quantized value, , c constant scale i' (0~255), , ln natural logarithm.

i tried far:

c1 = double(c1); c = 0; = (c*log(1+c1)); image(i); figure; 

and result black image.

you have set c=0 multiplied c. instead, compute c considering maximum value resulting image , making sure scales 1.

i = log(c1+1); c = 1/max(i(:)); = c*i; image(i); 

Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -