Rotate.m function fixed

버전 1.1.0.0 (2.53 KB) 작성자: Luc Masset
Surf property "vertexnormals" are updated correctly.
다운로드 수: 454
업데이트 날짜: 2012/2/23

라이선스 보기

Bug evidence:

[x,y,z] = sphere(20);
hs=surf(x,y,z,'facecolor','y');
view(2)
axis equal
hl=light;
lightangle(hl,0,0)
% light is on -Y axis, thus at the
% bottom
rotate(hs,[0 0 1],30)
% rotate sphere to the right from 30°

It looks like the light has moved. This is due to a bug in rotate.m function. The "VertexNormals" property of the surf object is not updated as "xdata", "ydata" and "zdata" properties are.

This is fixed in the submitted version of rotate.m.

Luc Masset

인용 양식

Luc Masset (2024). Rotate.m function fixed (https://www.mathworks.com/matlabcentral/fileexchange/35210-rotate-m-function-fixed), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2009b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Graphics Object Properties에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.1.0.0

interactive commands order changed

1.0.0.0