how to find the brightness of an image?
55 次查看(过去 30 天)
显示 更早的评论
how to find the brightness of a particular part of an image? and how to find the brightness of an entire image?
0 个评论
回答(2 个)
Image Analyst
2012-9-23
How do you define brightness? Is it just the mean? How about
brightness = mean2(yourImage);
or
brightness = mean2(yourImage(row1:row2, col1:col2));
2 个评论
Shaun Roberts
2019-10-11
Hi Image Analyst,
Based on your Video Processing Tutorial - https://uk.mathworks.com/matlabcentral/fileexchange/47726-video-processing-tutorial?s_tid=prof_contriblnk
I am looking to expand the features so I can run an analysis of low level features to see if they can be used for video recommendation.
The first one I have been looking at is Brightness mean would it be possible to work this into your current example?
Image Analyst
2019-10-12
The program does compute the brightness of the gray scale version as well as each of the color channels. You can find this code in there:
% Calculate the mean gray level.
grayImage = rgb2gray(thisFrame);
meanGrayLevels(frame) = mean(grayImage(:));
% Calculate the mean R, G, and B levels.
meanRedLevels(frame) = mean(mean(thisFrame(:, :, 1)));
meanGreenLevels(frame) = mean(mean(thisFrame(:, :, 2)));
meanBlueLevels(frame) = mean(mean(thisFrame(:, :, 3)));
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Image Segmentation and Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!