필터 지우기
필터 지우기

How to export geoglobe() plots?

조회 수: 12 (최근 30일)
leka0024
leka0024 2024년 1월 4일
댓글: leka0024 2024년 4월 4일
Example code:
uif = uifigure;
g = geoglobe(uif,"Basemap","landcover");
Have then tried (first line was part of an attempt to make an animation):
currentFrame = getframe(g);
exportapp(uif,[pwd '\test.png']);
and both fail with errors:
Error using matlab.ui.internal.FigureImageCaptureService.exportToPngBase64
Export unsuccessful
Error using exportapp
Export unsuccessful
Then tried:
exportgraphics(uif,[pwd '\test.png']);
and this does create the picture file, but it's just a blank gray box.
The following warning showed:
Warning: UI components will not be included in the output. To include UI components, use the 'exportapp' function.
How can the geoglobe plot be exported to picture or video file?
  댓글 수: 1
leka0024
leka0024 2024년 1월 5일
@Cris LaPierre invoking your name here since you answered another question about geoglobe() a couple weeks ago. Thanks for any help!

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

채택된 답변

Cris LaPierre
Cris LaPierre 2024년 1월 5일
편집: Cris LaPierre 2024년 1월 5일
Based on this post, I would have expected exportgraphics or exportapp to work. However, geoglobe is a little more than just a uifigure (html component for the globe) so it does not currently appear to be supported by the exportgraphics or exportapp functions. I have submitted an internal report.
I did come across this post, but the solution there (saveas to pdf) just produces a blank pdf, so not a viable solution either.
  댓글 수: 6
ZBMedina
ZBMedina 2024년 4월 4일
Any updates on a solution to save the figure with geoglobe and plot 3?
leka0024
leka0024 2024년 4월 4일
By the way @ZBMedina, if you're interested in geoglobe to do plotting of satellites (as I was) and if you have access to the Aerospace Toolbox, then https://www.mathworks.com/help/aerotbx/ug/satellitescenario.html is an absolutely awesome tool that solved everything I was interested in doing.
Although I don't believe I further investigated if it could export graphics since I did not need to make an animation at all as it has a full motion player within the window/tool. My guess is it has the same issue there. Just an aside FYI

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Earth and Planetary Science에 대해 자세히 알아보기

제품


릴리스

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by