how can i implement given formula in image processing?
2 views (last 30 days)
Show older comments
i have to aplly this foumula for contrast streching plz give me matlab program of this formula
s=(a-rmin)*(L/(rmax-rmin)); where L=256 rmin=0 rimax=255
0 Comments
Accepted Answer
Nitin
on 16 Feb 2014
There are lots of options for this:
You might need to define smaller blocks in your image and apply it locally depending on your requirements
4 Comments
Image Analyst
on 17 Feb 2014
I don't. I see no reason why scaling an image would require doing it region by region. Nothing has been said by the original poster that would require that. And since mat2gray does exactly the operation they requested, I'm not sure why they're not following my answer.
More Answers (1)
Image Analyst
on 16 Feb 2014
Simply use mat2gray().
Or, if you want to scale to something other than min-to-0 and max-to-255 you can use imadjust.
0 Comments
See Also
Categories
Find more on Image Processing Toolbox in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!