三维图像的特殊效果

三维图像的特殊效果

透视

[X0,Y0,Z0]=sphere(30);
X=2*X0;Y=2*Y0;Z=2*Z0;
surf(X0,Y0,Z0);
shading interp
hold on,mesh(X,Y,Z),colormap(hot),hold off
hidden off
axis equal,axis off 

图像

Perspective.jpg

镂空

利用“非数”NaN,对图形进行镂空处理。

P=peaks(30);P(18:20,9:15)=NaN;
surfc(P);colormap(summer)
light('position',[50,-10,5]),lighting flat
material([0.9,0.9,0.6,15,0.4])

图像

Cutout.jpg

猜你喜欢

转载自www.cnblogs.com/rongyupan/p/12662515.html