成像…

Featurd default
Featurd default

clear all;
fid=fopen(‘data.txt’);
data=fscanf(fid,’%g’,[4,inf]);
data=data’;
xd=1:1:65;
xd=xd’;
YR=data(:,1);
YG=data(:,2);
YB=data(:,3);
Ygy=data(:,4);

subplot(1,2,1);
plot(xd,YR,’r.-‘,xd,YG,’g.-‘,xd,YB,’b.-‘,xd,Ygy,’k.-‘);
xlabel(‘level’);
ylabel(‘luminance’);
title(‘gamma curves’);
axis([0 65 0 180]);

subplot(1,2,2);
plot(xd/65,YR/max(YR),’r.-‘,xd/65,YG/max(YG),’g.-‘,xd/65,YB/max(YB),’b.-‘,xd/65,Ygy/max(Ygy),’k.-‘);

xlabel(‘normalized level’);
ylabel(‘normalized luminance’);
title(‘normalized gamma curves’);
%axis([0 255 0 180]);
%gtext(‘red colors’);
%gtext(‘green colors’);
%gtext(‘blue colors’);
%gtext(‘gray colors’);

No tags for this post.
About Jay FanJiang 1027 Articles
System Analyst, Programmer, Web Developer, Witter, Dog Owner, Fashion Icon, http://www.youtube.com/user/j1720728