Camera up vector changes when rotating interactively

Consider the following example:
clear
close all
figure
ax1=axes;
hold on
grid on
setAxes3DPanAndZoomStyle(zoom,ax1,'camera')
view([-1 -1 -1])
camup([0 -1 0])
camup('manual')
grid on
xlabel('x')
ylabel('y')
zlabel('z')
surf(ax1,[1 1;2 2],[1 2;1 2],[1 1;1 1])
set(gcf,'Color','white')
Now as soon as I start rotating the plot interactively (using the Rotate 3D button on the axes), camup mode resets to 'auto' and the camup vector resets to [0 0 1] (resulting in a sudden discontinuous change of coordinate system orientation). The only related post I could find on the issue is from 2007: https://groups.google.com/g/comp.soft-sys.matlab/c/Jhdg1DUZ91c
It seems back then there was no way to solve the problem. Has that been changed yet?

 採用された回答

broken_arrow
broken_arrow 2021 年 11 月 8 日
編集済み: broken_arrow 2021 年 11 月 8 日

0 投票

It seems that as of today there is still no way. Copy of above comment:
The only way would be via the cameratoolbar, which I don't want to use.

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangePhysics についてさらに検索

製品

リリース

R2020b

タグ

質問済み:

2021 年 11 月 8 日

編集済み:

2021 年 11 月 8 日

Community Treasure Hunt

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

Start Hunting!

Translated by