How to use isosurface in app designer?

7 views (last 30 days)
Amanda
Amanda on 3 Dec 2020
Commented: Ameer Hamza on 3 Dec 2020
I am trying to create an app that shows a figure by jusing isosurface when a button is pushed. As i understand when you are going to plot something you just add app.UIAxes into the beginning, but using this on isosurface doesnt work. i.e. isosurface(app.UIaxes,xx,yy,zz,Power_E,max(Power_E(:))*(ratio)). So how do you use isosurface in app designer?

Answers (1)

Ameer Hamza
Ameer Hamza on 3 Dec 2020
isosurface() surface is quite an old function and does not support these features. According to the documentation, it will just create a new axes object. Use it with patch() as shown in the first example on the documentation page: https://www.mathworks.com/help/matlab/ref/isosurface.html. patch() will allow you to pass app.UIAxes as the first argument.
  2 Comments
Amanda
Amanda on 3 Dec 2020
Thanks that helps. I now get something in the figure, but it is in 2d and not 3d. Is there a way to fix this?
Ameer Hamza
Ameer Hamza on 3 Dec 2020
Run the following line after creating the patch
view(app.UIAxes, 3)

Sign in to comment.

Products


Release

R2019a

Community Treasure Hunt

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

Start Hunting!