Exploded assembly animation

Show off your FreeCAD projects here!
User avatar
JMG
Posts: 278
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Exploded assembly animation

Postby JMG » Wed Mar 16, 2016 1:00 pm

P.S. If you would provide an option to do a (by using a built in support for POV-Ray) render at each step that would be cool!
I have spent some hours with that but I do not find it motivating enough to continue.

But, hey, this is Open Source and I would be very happy to see (and merge) someone else code providing for this or any other functionality. :)
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
triplus
Posts: 9278
Joined: Mon Dec 12, 2011 4:45 pm

Re: Exploded assembly animation

Postby triplus » Wed Mar 16, 2016 1:15 pm

JMG wrote:
P.S. If you would provide an option to do a (by using a built in support for POV-Ray) render at each step that would be cool!
I have spent some hours with that but I do not find it motivating enough to continue.

But, hey, this is Open Source and I would be very happy to see (and merge) someone else code providing for this or any other functionality. :)
Fair enough.

P.S. I get this if i set your WB as start-up module:

Code: Select all

'NoneType' object has no attribute 'addObject'
User avatar
JMG
Posts: 278
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Exploded assembly animation

Postby JMG » Wed Mar 16, 2016 1:32 pm

triplus wrote: P.S. I get this if i set your WB as start-up module:

Code: Select all

'NoneType' object has no attribute 'addObject'
Fixed ;)
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
triplus
Posts: 9278
Joined: Mon Dec 12, 2011 4:45 pm

Re: Exploded assembly animation

Postby triplus » Wed Mar 16, 2016 4:31 pm

JMG wrote:
triplus wrote: P.S. I get this if i set your WB as start-up module:

Code: Select all

'NoneType' object has no attribute 'addObject'
Fixed ;)
Can confirm the error is gone!
therman
Posts: 2
Joined: Fri Aug 26, 2016 8:12 am

Re: Exploded assembly animation

Postby therman » Fri Aug 26, 2016 8:16 am

Hi!

This is a great tool. I'm currently trying to create a video and I'd like to run only a part of the animation. How can I do this from script? I tried using

Code: Select all

ExplodedAssembly.runAnimation(start=0, end=2)
Unfortunately this didn't work, because the animation doesn't stop and plays to the last part. What is the correct function call for this?
User avatar
JMG
Posts: 278
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Exploded assembly animation

Postby JMG » Sat Aug 27, 2016 5:36 pm

Hi. :)

The command needs a small modification:

Code: Select all

ExplodedAssembly.runAnimation( start=8, end=10, mode='toPoint' )
Start and end are the positions of the animation groups counting from the last element in the exploded assembly folder. If you have 10 animation groups and only want to run the first two, the configuration is start=8, end = 10.

Try the above command in the example file provided.

Javier.
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
therman
Posts: 2
Joined: Fri Aug 26, 2016 8:12 am

Re: Exploded assembly animation

Postby therman » Mon Aug 29, 2016 9:11 am

Thanks, in the meantime I figured that out However I'm not sure why it is counted from the end, rather than from the beginning. Anyways, I wrote a function that asks for the start index, end index and the number of animations, and calls your function with the correct parameters.

And to show my appreciation to you, I'd like to show you the video I was able to create with your workbench:
https://youtu.be/zMzEMR8Gdp8

I'm part of the team that develops the possible second Hungarian satellite, SMOG-1 and I created this demo video to show the build up of the device.
The animation was purely run by python script, including the Exploded Assembly functions.

Thanks!
User avatar
microelly2
Posts: 4628
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Exploded assembly animation

Postby microelly2 » Mon Aug 29, 2016 9:43 am

nice to see this.
User avatar
JMG
Posts: 278
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Exploded assembly animation

Postby JMG » Tue Aug 30, 2016 4:54 pm

therman wrote: And to show my appreciation to you, I'd like to show you the video I was able to create with your workbench:
https://youtu.be/zMzEMR8Gdp8

I'm part of the team that develops the possible second Hungarian satellite, SMOG-1 and I created this demo video to show the build up of the device.
The animation was purely run by python script, including the Exploded Assembly functions.

Thanks!
That's big project! I am really happy to know that my workbench has been of some use for it :)

Big thanks for sharing.
You also gave me a idea for a future implementation: vanishing.

Regards.
Javier.
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
triplus
Posts: 9278
Joined: Mon Dec 12, 2011 4:45 pm

Re: Exploded assembly animation

Postby triplus » Wed Aug 31, 2016 11:27 am

therman wrote:And to show my appreciation to you, I'd like to show you the video I was able to create with your workbench:
https://youtu.be/zMzEMR8Gdp8
Looking good.