DrPhibes Posted November 12, 2019 Share Posted November 12, 2019 OK, this is a long shot. Is there a way to automatically apply key frames to a percentage pose slider. For example; If I manually move a bone from point A to point B in an action, that animation would then automatically move a pose slider a certain percentage based on some predetermined association (x translate of bone1 from -5" to 10" moves the pose slider 0 to 100%) This may sound like a strange need, but I have been using A:M to program animatroncs with the majority of the control generated through key framed poses exported through an A:M action file. I am looking to combine the pose sliders with an IK rig, but I want that IK rig to drive the pose sliders in a couple cases. Charles Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 12, 2019 Hash Fellow Share Posted November 12, 2019 Hi Charles, What other motion does the bone1 have, beside moving from -5 to +10? There are probably several ways to link the pose slider to bone motion. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 12, 2019 Hash Fellow Share Posted November 12, 2019 Charles, try this... clip4869BoneMotionDrivePoseSlider.mov Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 13, 2019 Author Share Posted November 13, 2019 Robert, can't thank you enough for this. It may totally solve the problem. I imagine that I will need to bake the animation to get key frames recorded to the pose slider timeline. I wonder if there is an expression for that Expressions did not even occur to me. I use them all the time in after effects, never think about it in A:M Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 15, 2019 Author Share Posted November 15, 2019 Hello Robert, This works with translate, do you think it can be made to work with the longitude or latitude motion of a bone? Charles Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 15, 2019 Hash Fellow Share Posted November 15, 2019 Do you mean rotation? If you just need to tie a pose slider to the rotation of a bone, that is smartskin. You can link anything that can be keyframed to the rotation of a bone. Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 15, 2019 Author Share Posted November 15, 2019 I am going to go into more explanation here of my goal and issue so that it may help spark some ideas. Normally the animatronics we build have a single actuator tied to a single point of motion, usually a rotational axis, stacked on another point of motion. In an animation model and rig I build accurately to the real world items as possible. This usually results in a single bone that has a certain range of rotation applied through a a pose slider. Then in an action file I would animate to the prerecorded audio simply adjusting the pose sliders per axis of motion. This FK animation process work very well for the majority of the characters we have built. I would animate a neck rotation, then the head tilt for example, building each layer individually. All of these key framed pose sliders are exported in an action file to some custom software we created to run a filter through the channels to adjust the acceleration/deceleration profiles to match what the real world actuators can do based on load specs and so on. Then this is exported to the controller hardware. I can send this data both ways as well. Once the adjustments are made to the channels, I can bring it back into A:M to see how it may have changed and then adjust if necessary. One day i hope to just have this function in A:M as a plugin instead having to export and re import. So now this is where my current problem lies. We have a mechanical design that uses two actuators to control a gimbal. This means that there are some tricky rigs to emulate accurately. In most cases I would like to use a pose slider to control each actuator independently so I have recorded key frames on the pose channel. I can make this work now and is acceptable. However, this is a good case to look at using a more IK workflow where I am moving a single null and the pair of actuator follow and automatically record key frames to their respective channels. I don't spend quite enough time building complex rigs in A:M to instantly know the cleanest approach. I am attaching a stripped down model of what I am doing so you can look at it. This is to scale as well. There is a single null target that is essentially the nose of the character. This null is followed by a single bone using an aim at constraint. The base of this bone represents the gimbal. There is a triangular frame (the gimbal plate) that has two nulls used as targets to aim the actuators at. Each actuator has a pose slider that moves it 0 to 100% through its range of extension and retraction. In the Demo02 action I animated the head aim target, then by hand animated the pose sliders to line up with their respective targets on the gimbal plate. This gives me the ability to very simply perform the head, and then also generate the key framed poses specific to the actuators needed for export. So, this last step of hand positioning the pose sliders and generating those pose key frames is what I was hoping to find a way to automate. Am I dreaming? I have another element that would operate in a similar fashion, but has 4 actuators. A second pass by hand to set those key frames could be time consuming. Charles Gimbal Demo.prj Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 15, 2019 Hash Fellow Share Posted November 15, 2019 there should be a straightforward solution. i can almost taste it. To summarize: you want the linear motion of Act_Target_Left and Act_Target_Right to be mirrored in the motion of posesliders? Was doing that with expressions not working? Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 15, 2019 Hash Fellow Share Posted November 15, 2019 Tell me if I'm getting this... clip4891GimbalBakingA.mov Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 15, 2019 Author Share Posted November 15, 2019 So to answer the first question, yes, expressions could probably be made to do what I want in this case. So the example you provided in the video was based on the "demo02" action I set up where I hand animated the actuator to match the gimbal motion. In this case if I hand animate the poses then I get what I need in the pose sliders and there is no need for a baking step. I placed this action in there to demonstrate the end result I was looking for. Look at the "demo01" action. You will see that the actuators are not moving. This is the where I would like to find a rig setup to automatically move the actuators to match the gimbal motion. Also, yes, it is true I can pull the translate value out of file and run that to the controller. It does create an extra step because I will need to process that separately from the other motions pulled from pose sliders. In fact our first version of the translation tool worked specifically on bone rotation values and not pose slider positions. Quote Link to comment Share on other sites More sharing options...
fae_alba Posted November 16, 2019 Share Posted November 16, 2019 I've always wondered if a:m could be used to drive an anamatronics rig. I'm working on building a finding Nemo seagull now in am and 3d printing it. I figured I would have to build my one controller and interface in either raspberry pi or arduino. But using am...now that gets me wondering what the workflow would look like. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 16, 2019 Hash Fellow Share Posted November 16, 2019 try this... clip4894GimbalExpression.mov Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 16, 2019 Hash Fellow Share Posted November 16, 2019 Charles, The above technique causes the Pose slider to move with the bone motion but it doesn't create an actual data channel of key frames for the Pose slider. If that is a problem, I have a solution. Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 18, 2019 Author Share Posted November 18, 2019 Robert, This is getting so close to where I need to be. But yes, getting the pose sliders to record key frames would be ideal. I came across another issue I overlooked as I was working through this with you. In my other projects because of their simplicity, I can just use key framed pose sliders in an action, export that action, run it through the filtering software to refine any acceleration or deceleration issues, then import that edited action file back in to A:M, drop it on the model and watch the play back to visualize the changes. This ability goes away to some degree with the expressions. What I think I need to do is build an animation rig and a separate playback rig if I continue down this path. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 18, 2019 Hash Fellow Share Posted November 18, 2019 What is the origin of the tool you use to extract Pose slider data into a format for your "actuators" to use? Did you write it? Someone in your company? Is it a plugin that works in A:M or something that works on a saved file? Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 18, 2019 Author Share Posted November 18, 2019 It is a tool we wrote internally. It is a separate app that we wrote that is a basic converter to translate to the controller hardware we use, and we added some features to help with the real world issues of acceleration and deceleration limits of the actuators. I hope to at some point develop this stuff into an A:M plugin(s) that allows me to see in realtime on a timeline an overlay of an acceleration curve with the current position over time spline. This would allow me to animate to the limits preset into the plugin and make sure that nothing is moving in a way it can't in reality without having to save out and bring back in. When we did this during our first tests we just created an Excel project that did all of this conversion. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 19, 2019 Hash Fellow Share Posted November 19, 2019 Try this... clip4900BoneMotiontoPoseSlider.mov Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 19, 2019 Author Share Posted November 19, 2019 Thank you for all your efforts Robert! To address your comment in the video about using the translate channel (or any other channel) as the source of our motion data in the conversion to the controller, this is exactly what I planned to do if there was not an easy automated way to get there with pose sliders. The 0 to 100 values, and the small size of an action file with the ability to parse out the channels from logically named pose sliders was nice. I can get to the 0 to 100 values in other ways with constraints, but when parsing the data it requires more effort due to the duplicate naming. Search a project file for "matchname =Z" and see how many hits you get I had played with some of the text editing solutions to transfer the channels as well. I think you have definitively shown that I need to stick with our first version of the tool that pulled from a position channel. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 20, 2019 Hash Fellow Share Posted November 20, 2019 Quote I hope to at some point develop this stuff into an A:M plugin(s) that allows me to see in realtime on a timeline an overlay of an acceleration curve with the current position over time spline. I think you could do that now. Since you only need the Z translation channel, a non-relevant channel on the same bone could be given an expression that calculates the acceleration. Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 20, 2019 Author Share Posted November 20, 2019 17 hours ago, robcat2075 said: I think you could do that now. Since you only need the Z translation channel, a non-relevant channel on the same bone could be given an expression that calculates the acceleration. Hmm, I will need to research this more. This sounds promising. So then what you are saying is that on a x scale channel for example, an expression is linked to it to force the spline in the timeline to display the acceleration curve? Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 20, 2019 Hash Fellow Share Posted November 20, 2019 20 minutes ago, DrPhibes said: Hmm, I will need to research this more. This sounds promising. So then what you are saying is that on a x scale channel for example, an expression is linked to it to force the spline in the timeline to display the acceleration curve? I would set the bone to "Euler" rotation and use the Z rotation channel since that will produce little visible motion of the bone and yet the curve would still be viewable in the same window. There is a function in Expressions that lets you retrieve values for a parameter for any previous or future frame. something like this Z rotation = ((previous frame z translation - current frame z translation) - (current frame z translation - next frame z translation) ) * some scaling factor Quote Link to comment Share on other sites More sharing options...
DrPhibes Posted November 21, 2019 Author Share Posted November 21, 2019 I have played with this a bit, but I think I am missing something. I am getting a syntax error. Have you tried it? Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 21, 2019 Hash Fellow Share Posted November 21, 2019 It is easy to get it wrong because the paths are so complicated. Our resident expert on expressions is David Simmons (it'sjustme). Drop him a message see if you can get him to look in on this. Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 21, 2019 Hash Fellow Share Posted November 21, 2019 David has a page of tuts on expression that may be instructive... Quote Link to comment Share on other sites More sharing options...
Hash Fellow robcat2075 Posted November 21, 2019 Hash Fellow Share Posted November 21, 2019 I did a little experimenting and found that an expression in the form of... AtFrame(GetFrame(),..|..|Translate.X) ... does create a "Missing a Right Parenthesis" error even though they appear to match. Quote Link to comment Share on other sites More sharing options...
itsjustme Posted November 22, 2019 Share Posted November 22, 2019 8 hours ago, robcat2075 said: I did a little experimenting and found that an expression in the form of... AtFrame(GetFrame(),..|..|Translate.X) ... does create a "Missing a Right Parenthesis" error even though they appear to match. It usually means there is an error somewhere in the expression if it says "Missing a Right Parenthesis". Something like this works: AtFrame(GetFrame()-30,..|..|..|..|Bone1.Transform.Translate.Z) Sometimes adding some extra parentheses will fix a calculation. It isn't necessary in this case, but it would look like this: AtFrame(GetFrame()-30,(..|..|..|..|Bone1.Transform.Translate.Z)) Hope that helps. Expressions_example_11_21_2019.prj Expressions_example_11_21_2019b.prj Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.