about conversion of color spaces

조회 수: 2 (최근 30일)
Priyanka
Priyanka 2012년 1월 25일
How to convert RGB color space into YUV color space?

채택된 답변

Chandra Kurniawan
Chandra Kurniawan 2012년 1월 25일
rgb2ycbcr
MATLAB YCbCr color space is often referred to as YUV.
  댓글 수: 3
Chandra Kurniawan
Chandra Kurniawan 2012년 1월 25일
Hi,
I see the problem
from this link : http://en.wikipedia.org/wiki/YUV
we can also implement the formula by :
RGB = imread('football.jpg');
R = RGB(:,:,1);
G = RGB(:,:,2);
B = RGB(:,:,3);
Y = 0.299 * R + 0.587 * G + 0.114 * B;
U = -0.14713 * R - 0.28886 * G + 0.436 * B;
V = 0.615 * R - 0.51499 * G - 0.10001 * B;
YUV = cat(3,Y,U,V);
imshow(YUV);
Priyanka
Priyanka 2012년 1월 27일
Thanks alot.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Convert Image Type에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by