Help me how to convert RGB image to YUV

5 ビュー (過去 30 日間)
James
James 2012 年 10 月 29 日
I heard that there is a built in function in matlab that came with the image processing toolbox that convert RGB image to YUV can you help me to do that ?

採用された回答

Walter Roberson
Walter Roberson 2012 年 10 月 29 日
Also see the MATLAB File Exchange
  3 件のコメント
Walter Roberson
Walter Roberson 2012 年 10 月 30 日
Just solve the simultaneous equations. You will get
R = -0.1179838438e-4 * U + Y + 1.139834576 * V
G = -.5805942338 * V -.3946460533 * U + 1.000003946 * Y
B = .9999796789 * Y + 2.032111938 * U -0.1511298066e-4 * V
James
James 2012 年 10 月 30 日
ok thanks alot

サインインしてコメントする。

その他の回答 (1 件)

Image Analyst
Image Analyst 2012 年 10 月 29 日
No. There is one to LUV, not YUV. You can get the relationship between L and Y at easyRGB. You can find the formulas to go from sRGB to YUV at Wikipedia, but why do you want to use that anyway? Why not use YCbCr, or even better, HSI or LAB? What are you trying to do? Can you upload your image somewhere and tell us? How do you know book formulas are going to work for you and you don't need to use calibrated intensity units? Are you sure your RGB is sRGB? (The answer is no, you do not. For example the x-rite Color Checker Chart comes with a list of nominal RGB values for the standard color chips but you will never be able to get those with your camera unless you're extremely lucky with your sensor spectral sensitivities and your exposure.)
  1 件のコメント
James
James 2012 年 10 月 30 日
i am testing one algorithm that enhance the contrast. actually the algorithm is tested on sRGB format but i dont have any idea how to convert RGB to sRGB and what the different between the two format
I reach a point where i decided to change RGB to YUV or YcBcr so that i play only on the Y matrix
It works for me but i still want to learn about image formats
I am into digital image processing and i want to be an expert

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeConvert Image Type についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by