Figure window only plays in the background

조회 수: 10 (최근 30일)
Ryan Turner
Ryan Turner 2019년 7월 17일
댓글: Harmanjeet Singh Bilkhu 2020년 5월 7일
I'm running a program that is supposed to open an animated figure. However, the figure does not open, it plays in the background. You can only see it by hovering over the figure in the task bar or waiting until the animation is done, then maximizing.
The code is attached. The particular program I was trying to run was poleplace_cartpend.m, there are other programs that also animate a figure. The programs are for a class on control, the figure is animated in the program drawcartpend_bw.m. The figure is meant to be an inverted pendulum being stabilized. There are other figures of the pendulum just swinging. Regardless of which program I run, the figure only animates in the background. Below is an image to clarify what I'm talking about.
I can see the figure by hovering over it in the task bar, but when I click on it to open it, it does not pop up. Once the animation is finished, it can be maximized.
  댓글 수: 3
Ryan Turner
Ryan Turner 2019년 7월 19일
That is because it is a separate program I wrote. It is not part of the issue I am having here.
MatlabEnthusiast
MatlabEnthusiast 2019년 12월 25일
this is a bit offtopic, but do you happen to have the bootcamp_code.zip where PI is discussed? it will be of great help to me. thank you.

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

답변 (2개)

Ahsan Naeem
Ahsan Naeem 2020년 3월 9일
Open drawcartpend_bw.m file and comment out (remove) following line:
set(gcf,'Position',[10 900 800 400])

Harsha Priya Daggubati
Harsha Priya Daggubati 2019년 7월 25일
Hi,
I reproduced the scenario which you have mentioned in MATLAB 2018a and found out that it isn’t the same for me. I suggest executing the following commands at your MATLAB Command Line and run your program later to check whether this works. Hope this helps!
rehash toolboxcache
restoredefaultpath
rehash toolbox

카테고리

Help CenterFile Exchange에서 Animation에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by