I don’t have a good fluidity in the animation of my crankshaft . What’s my likely problem?
Thanks for yours returns
Simplified crankshaft for 3 cylinders at 120°
OS: Windows 11 build 22631
Word size of FreeCAD: 64-bit
Version: 0.22.0dev.35485 (Git)
Build type: Release
Branch: main
Hash: a662fbb2ff267fb8dd56fcc3d1ec55a5968b7f5a
Python 3.10.13, Qt 5.15.8, Coin 4.0.2, Vtk 9.2.6, OCC 7.6.3
Locale: French/France (fr_FR)
Installed mods:
* Assembly4 0.50.6
You have applied the rotation constraint variable to the body link’s assembly LCS. When you attach another body to this link with the same LCS then it will also rotate but RELATIVE to the one to which it is attached. So, each successive body rotates faster with respect to the global origin.
You can treat this as a sub-assembly and apply a rotation constraint to the parent LCS like that shown in the attached file. Or, make a linear array and rotate the array. Or, change the link element count to 3, locate each element appropriately using its placement, and then rotate the original link attachment offset. Or, rotate only the first body link using its assembly attachment offset property. Your choice, many ways to do this.
Hi
I will try to apply this. This is not obvious. As you point out, there are several possibilities with different results.
I continue to test on my simple pieces and I will find the right way to proceed.
Thanks
After testing your file, the fluidity on my machine does not correspond to that of your video. She is always very slow.
But by removing the attached variable a_rotation in Tourillon001 LCS1 I gained fluidity. So depending on the fluidity of the animation it will be necessary to review the positioning of the LCS. I think with experience we no longer ask this kind of question.
Do you have any ideas on how I can improve my fluidity?
Sincerely
Are you talking about the animator itself or the Save function which creates the .GIF file? The animator is indeed slow depending upon the step size. The GIF Save function speeds up the animation depending upon the frames per second (FPS) setting.
These are settings I used for the video:
Screenshot 2024-01-11 080708.jpg
For the animation program which creates the .GIF file impossible to use for me. I always encounter this problem. https://devtalk.freecad.org/t/is-eigen2-still-a-prerequisite/752/1 If necessary, I use the stable version of FreeCAD.
If you have a solution, I’m interested
I have the same problem with the development weekly versions lately so I have to fall back to this version or the original V0.21 stable as you.
Works OK here:
OS: Windows 11 build 22621
Word size of FreeCAD: 64-bit
Version: 0.22.0dev.34959 (Git)
Build type: Release
Branch: main
Hash: 640018bfa7878a79e1b3c220ddd488d66464dc70
Python 3.10.13, Qt 5.15.8, Coin 4.0.0, Vtk 9.2.5, OCC 7.6.3
Locale: English/United States (en_US)
Installed mods:
Assembly4 0.50.6
fasteners 0.4.15
freecad.gears 1.1.0
QuickMeasure 2022.10.28
It will also not run for me on Windows V0.21.2.33771 bug fix so I’m guessing that something has happened since the V0.21 release.
Runs OK here:
What the Conda packager will need to know (not me) is the version number of cv2 that works in build 34959 by entering the following in the Python Console:
import cv2
cv2.__version__
and reply with the output and mention adrianinsaval
With Conda (and I guess other packaging software) the version of each package can be pinned so it doesn’t increase until we can find a newer version that works correctly.
import AnimationExportLib
Traceback (most recent call last):
File "<input>", line 1, in <module>
File "/tmp/.mount_FreeCAZJRDdo/usr/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
return original_import(name, *args, **kwargs)
File "/home/adrian/.local/share/FreeCAD/Mod/Assembly4/./AnimationExportLib.py", line 13, in <module>
from PIL.ImageQt import ImageQt
ImportError: cannot import name 'ImageQt' from 'PIL.ImageQt' (/tmp/.mount_FreeCAZJRDdo/usr/lib/python3.10/site-packages/PIL/ImageQt.py)
the problem is that pillow has depecrated qt5 and removed support in pillow 10, so we would need to downgrade pillow to 9.5 but I’m not sure how viable that is. I’ll check this out.
The ‘Save’ function of the Assembly4 animator complains that CV2 is not installed and prevents saving the animation. Works OK in the following weekly and V0.21.1.33377 stable but not in V0.21.2 or later weekly versions:
OS: Windows 11 build 22621
Word size of FreeCAD: 64-bit
Version: 0.22.0dev.34959 (Git)
Build type: Release
Branch: main
Hash: 640018bfa7878a79e1b3c220ddd488d66464dc70
Python 3.10.13, Qt 5.15.8, Coin 4.0.0, Vtk 9.2.5, OCC 7.6.3
Locale: English/United States (en_US)
Installed mods:
Assembly4 0.50.6
fasteners 0.4.15
freecad.gears 1.1.0
QuickMeasure 2022.10.28
Thank you for any assistance. This is a frequently used function.