필터 지우기
필터 지우기

Update a 3D graph without resetting viewpoint?

조회 수: 3 (최근 30일)
Ken
Ken 2024년 4월 1일
댓글: Voss 2024년 4월 4일
I generate a 3D graph. My user, using the mouse, rotates it and changes the viewpoint. Then the user modifies a parameter and I regenerate the graph. The graph snaps back to its original, default 3D viewpoint. I don't want this! It would be much more informative to the user if the graph changed in place, with no change of viewpoint. Is this possible?

답변 (1개)

Voss
Voss 2024년 4월 1일
Yes. You can store the axes view and later restore it to the stored value after updating the plot. See view.
Alternatively, update the plot using low-level functionality (e.g., set(h,'XData',x,'YData',y,'ZData',z)) rather than high-level functions (e.g., plot3(x,y,z)), because low-level functions don't affect the axes, including the axes view.
  댓글 수: 1
Voss
Voss 2024년 4월 4일
@Ken: Did this work for you? If so, please Accept the answer.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

태그

제품


릴리스

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by