8-1 삼각함수 그리기
tau = 0:pi/20:2*pi;
omega = 0.35*pi;
figure:plot(tau, sin(omega.*tau));
xlabel('time\tau');
ylabel('sin(\omega\tau)'); % 기호 삽입
title('\it{The Graph of} \rm{y=sin(\omega\tau)}'); % 이탤릭체, 글자체 원래대로 복귀, 진하게
text(pi/omega, 0, '\bullet\leftarrow sin(\pi)', 'fontsize', 18) %점찍기, 화살표, 글자크기 조절
tau = 0:pi/20:2*pi;
omega = 0.35*pi;
figure:plot(tau, cos(omega.*tau));
xlabel('time\tau');
ylabel('cos(\omega\tau)'); % 기호 삽입
title('\it{The Graph of} \rm{y=cos(\omega\tau)}'); % 이탤릭체, 글자체 원래대로 복귀, 진하게
8-2 2차원 데이터의 3차원 표면 맵핑(Texture Mapping)
x=imread('lena_gray.bmp');
xt=fliplr(x);
hemisphere=[xt(:, 257:512), x, xt(:, 1:256)];
figure, imshow(hemisphere, gray(256));
figure;
sphere;
h=findobj('Type', 'surface');
xt=x(:, 512:-1:1);
set(h, 'CData', flipud(hemisphere), 'FaceColor', 'testuremap')
colormap(gray(256))
axis equal
view([90 0]);
set(gca, 'CameraViewAngleMode', 'manual');
view([65 30]);
'학교' 카테고리의 다른 글
[2019-1] 컴퓨터그래픽스1 프로젝트 (0) | 2021.08.12 |
---|---|
[2019-1] 자바프로그래밍 과제 (0) | 2021.08.12 |
[2019-1] 디지털영상처리1 7장 과제 (0) | 2021.08.12 |
[2019-1] 디지털영상처리1 6장 과제 (0) | 2021.08.12 |
[2019-1] 멀티미디어통신 과제 (0) | 2021.08.12 |