manipulate 3d object

i create scene in maya. include animation. its a piston animation. in panda3d how can i make a function where user can manipulate the object in my maya scene. for example user can change the length of the object. i want to create something like user enter data to change the length of the object (scale the object) base on the input data.

if u guys have an example i appreciate its so much.

wouldn’t scaling the object just cause the whole object to become bigger/smaller? As for changing the length of the object I think you would have to mess with the mesh of the object.

thanks,
is there any example?

I’m sorry I don’t have any examples because I have never done this before. I would suggest searching the forums or waiting for someone who has done this. Also, I am not sure you can do this in panda.

sorry I can’t be of more help

i appreciate your help… thanks…

Depending on complexity, you might scale that object in one one direction. Ofcourse for that, it needs to be axis aligned.

I do something similar with my Panda project, except all my models are completely symmetrical. To let the user “resize” the on-screen models, I simply scale them in one or more directions.

That said, I don’t think that method would work for any asymmetric object (like a piston). Still, if you scaled the piston uniformly, the above method would work, I think.

Personally, if the scene was just as simple as a piston, I would have two separate models, and move them independently based on user input. I wouldn’t do an animation at all.

forget about the piston. how about the maya scene only a cube.
how can i make it?
the user enter data to scale or rotate the cube.

i appreciate if someone can show me an example.

:frowning:

I would suggest the Panda Manual’s article on common state changes, as well as the actual programming interface for the NodePath class. For details on what the NodePath class represents, read the relevant Panda Manual article.

tq bluskies… i will try to study all that…