Change the size of wrapobjects in Matlab

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Seungyeon Kim
Posts: 4
Joined: Mon Jul 20, 2015 12:11 am

Change the size of wrapobjects in Matlab

Post by Seungyeon Kim » Sun Sep 30, 2018 7:54 pm

Hello.

I'm trying to change the radius of Wrapcylinder in the MATLAB interface.

I want to change the Wrapcylinder in the existing model. But, I can't bring the wrapcylinder in the model to MATLAB using Wrapcylinder class.

So it is impossible to use functions including getRadius() and setRadius().

Is there any method that can change the radius of Wrapcylinder using MATLAB?

Thank you.

Tags:

User avatar
jimmy d
Posts: 1375
Joined: Thu Oct 04, 2007 11:51 pm

Re: Change the size of wrapobjects in Matlab

Post by jimmy d » Mon Oct 01, 2018 8:41 am

Have you tried safedowncasting to the concrete type?

Code: Select all

% Safedowncast a wrap object down to the concrete class
YourWrapCylinder = WrapCylinder.safeDownCast(YourWrabObject) 
% Change the radius
YourWrapCylinder.set_radius(0.05)

User avatar
Seungyeon Kim
Posts: 4
Joined: Mon Jul 20, 2015 12:11 am

Re: Change the size of wrapobjects in Matlab

Post by Seungyeon Kim » Thu Oct 04, 2018 7:17 pm

To James Dunne

It works perfectly. Thank you so much!

POST REPLY