A new version of Cineversity has been launched. This legacy site and its tutorials will remain accessible for a limited transition period

Visit the New Cineversity
   
 
Smoothing out a moving ribbon connector?
Posted: 13 February 2016 01:20 AM   [ Ignore ]  
Total Posts:  138
Joined  2012-04-04

Hi:

I’m attempting to duplicate a ribbon cable within an inkjet printer that connects a moving printhead to a fixed point.  The printhead sweeps back and forth and the ribbon connects it to the electronics.

I’ve worked out a version that uses an IK spline effector to drive a chain of joints.  It mostly works, but it’s not as fluid as I’d like.  The shape can jump a lot from frame to frame, and that’s apparent when the head moves slowly into its starting position.

Is there a better way to do this?  Do I need more joints?  It didn’t seem like I could use pure IK to drive the chain since it bends over on itself.

I’ve attached my setup as it exists now.

Thanks.

Shawn Marshall
Marshall Arts Motion Graphics

File Attachments
Ribbon Demo Simplified.c4d.zip  (File Size: 90KB - Downloads: 161)
Profile
 
 
Posted: 13 February 2016 02:09 AM   [ Ignore ]   [ # 1 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Hi Shawn,

So far I can see, the whole set up is based on keeping the length stable. Is that the reason? Perhaps, try this, drag the “New Spline Animated” above the Joints, so the information is available when it is needed. If I get you correctly, then the jumps/frame are just an priority problem.

Since using the “New Spline Animated” directly in the SWEEP, would set up a very small hierarchy and no problems. The logic suggests - stable length was the reason here.

Please test this hierarchy, and all that counts is the rendering for me (Render Preview), there it needs to work, scrubbing the timeline is secondarily for me as proof.


Since you use the Joints only as IK construction, you could AFAIK as well Null Objects, as the position of them are in question, which would eliminate a lot of objects. See attachment.

All the best

File Attachments
CV2_r17_drs_16_ANri_11.c4d.zip  (File Size: 34KB - Downloads: 155)
 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 13 February 2016 02:27 AM   [ Ignore ]   [ # 2 ]  
Total Posts:  138
Joined  2012-04-04

Thanks again for the quick reply.

By using the spline to drive a string of joints I believe I’m able to keep the length consistent.  Even if the spline overshoots the end the actual ribbon will remain the correct fixed length.

Moving the animated spline to the top doesn’t really make it move more smoothly to me.  If you look at frame 16 to 17 you can see a pretty noticeable jump in the animation.  Maybe I need to drive that spline by a Tracer and a few nulls rather than use PLA, which can be very difficult to animate smoothly.  I might have to subdivide the joints some more; when the printhead is all the way to the left my curved ribbon loses its smoothness due to the joints being too long at that extreme position.

Can you suggest any other approaches?  Would a dynamic solution, like for a rope, work better?  Can an IK chain have multiple goals, one to attach it to the printhead and another to pull it into this curved shape?  I don’t do much IK.

Best.

Shawn

Profile
 
 
Posted: 13 February 2016 03:35 AM   [ Ignore ]   [ # 3 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Please take the file below “…_21.c4d”, do a test render for the frames 0-25. Use Standard and Physical, either way. Both (different colors) render similar)

Then check the red spheres which I have integrated in “…31.c4d”. It shows the movements per frame for the original “Spline New Anim”. One might argue it is not that point of the object followed by the spheres, but it is the frame by frame difference horizontal.

Either way, the Spline has a very different movement from one to the other frame, and it shows. I use in “…31.c4d” the “Spline New Anim” and have even added a rail to avoid any “euler flips” on the SWEEP.

It shows drastically in the Motion Blur [Physical].

It starts all with the “Spline New Anim” and given the fact that it doesn’t help to use spline after it, as it segments the curve, it might show more.

In the scenes I have replaced the Joints with Null objects, to get a lot of processing out of the scene.

=========

Another approach could be to place the Nulls on a Spline. Align to Spline. Try this, take a single Null, add an “Align to Spline” to it and place the Spline you like into the Tag. Then copy it, copy both, again and so on until you have the right number. Select all the tags and enter in the position field
100/(tot-1)*num
This should place all the Nulls in order on the Spline. On the print head place two Nulls (child) one where it connects and one a little bit away from it, to have a stable connection. All these nulls on the spline and the head are needed in the Tracer, in the right order.
Just an idea, test it if it works for you. Spline animation and head should be in “sync”. But the ribbon, will stay connected.

All the best

File Attachments
CV2_r17_drs_16_ANri_31.c4d.zip  (File Size: 143KB - Downloads: 176)
CV2_r17_drs_16_ANri_21.c4d.zip  (File Size: 128KB - Downloads: 162)
 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 13 February 2016 04:42 PM   [ Ignore ]   [ # 4 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

You asked about Alternatives.

This would be the way I would do it.

Just a simple slider, for back and fore.

Since you mentioned that it moves slow as well as fast from time to time, the result of a fast movement would be a little wiggle (-100% to +100%) based on the wiggle slider.
(But that is after all is animated, so you don’t waste time.)
When it moves slow, then nearly no wiggle is needed.

A preview (one minute) is here:
https://www.amazon.com/clouddrive/share/EZtrvaVnB2zaFNm24kPE0n0nXWBdIiN5xJ0jVJrB5bl?ref_=cd_ph_share_link_copy
Note, that I go over the 100% to stress this set up. The wiggle will be a cycle between plus and minus, and very fast.

This would be my current favorite, if I have another idea, I will post.

Have a nice weekend

File Attachments
CV2_r17_drs_16_ANri_41.c4d.zip  (File Size: 24KB - Downloads: 147)
 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 14 February 2016 12:15 AM   [ Ignore ]   [ # 5 ]  
Total Posts:  138
Joined  2012-04-04

Thanks for this alternate solution.  It works okay for slight changes of shape, but when the printhead sweeps from right to left the spline gets all messed up between the two extremes; the nulls want to move in a straight line between the two extremes.  I need them to flow along to maintain the shape of the curve.  That’s why I think the joint solution was my best bet to keep that shape from getting too distorted.

I might just go with what I had with a few tweaks.

Best.

Shawn

File Attachments
Ribbon Rework Test.c4d.zip  (File Size: 594KB - Downloads: 153)
Profile
 
 
Posted: 14 February 2016 12:56 AM   [ Ignore ]   [ # 6 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Shawn,

I see. No problem, it works here fine and was supposed to be a sketch, you don’t want to invest more time, OK.

I hope I have shown you the reason for the “jump” around frame 16 in detail in your initial spline animation. I guess you can easily fix it now, as it started from the Spline already.

Hopefully all goes well now, it should be easy, since the problem source is clear.

My next step would have been to check the Animation Clip option, or just the Time Track. In each case with a longer Spline animation as base, and then go from that precision to the repetition. As the ribbon, at least in the printers I have seen, behaves differently if moved fast or slow, I would develop two and mix them in the Motion System [Animation Clip].
Since you have made a decision, I will close that case, and leave with;

My best wishes for your project.

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile