luminance component of an image
6 次查看(过去 30 天)
显示 更早的评论
Hi, I have a frame of a vedio sequence I which is a 288*532 double. How can I extract only the luminance component? Thanks.
0 个评论
采纳的回答
Mark Sherstan
2018-11-30
Run the following:
I = imread('test.png');
J = rgb2gray(I);
rgb2gray uses the same formual which is used to calculate luminance (to 3 decimal places the formula is):
0.299 * R + 0.587 * G + 0.114 * B
4 个评论
更多回答(3 个)
az
2018-11-30
1 个评论
Image Analyst
2018-11-30
编辑:Image Analyst
2018-11-30
Just attach the one frame, not the entire video. One frame will certainly be small enough to attach!
And explain why using rgb2gray() on the RGB image did not work.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Read, Write, and Modify Image 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!