I have searched for several hours trying to find a solution to this problem and have only made it so far. I am trying to take an f-curve that I have baked from a sound file and free transform it so that I can manually move it around to fit the data correctly. To be specific, rotate a needle on an axis. The only problem is, the max value is exactly 1 degree. I was wondering if anyone knew how to manually move the f-curves after they’ve been baked from the sound file. I’ve already tried using the “Bake Curve” option, but nothing changes. Thank you for any help.
You can move points on an f-Curve just like objects in the scene.
Simply select them all and issue a move command.
For instance to move all the points in an f-Curve up by one, select them all (A-Key) then type GY1 enter. (Grab in the Y direction one unit)
I’ve tried this. When I press G, S, or R, it does nothing. It acts as though it is locked.
Still not getting anywhere with this… It seems as though even Google doesn’t have the answer. This appears to be a rather unexplored topic. I would really like to solve this.
The curve also has and edit mode. You need to enter the edit mode for the curve by pressing TAB-Key, select points, then try to (G)rab the points to move them.
no, I dont think you can edit baked fcurves -as those you get from baking a sound- that was the point of writing the scripts…
I would say the best way would be to do it the same way you would work with audio to keyframes in Adobe AfterEffects. Bake the sound clip to an f-curve in an empty object, then add a driver to the rotation channel for the object you wish to animate.
Go into the graph editor and switch to from F-Curves to Drivers and add a variable to your new driver which is linked to the f-curve channel of your empty object with the baked audio (i find the scale channel is best one to use) then you can use that variable and modify it to your hearts content. Eg, (var*90)-45 should change the movement so rather than being 1 degree, it will swing between -45 and positive 45 degrees.
As an aside, my above example is actually incorrect as blender’s back end uses radians rather than degrees, but i used the your terminology to keep the answer consistent. A radian is actually 180/pi (or about 57 degrees) so assuming your audio f-curves amplitude lies between 0 and 1, if you wanted your animated needle it to swing 90 degrees you would actually have to convert the degrees to radians by using the formula varmath.pi(90/180)
Also, if you wish to keep everything together in the one object, you can add a custom property to the object you wish to animate, bake the sound to that custom property, and then link your driver to that property. Personally (probably due to my use of AfterEffects) i like to keep my audio f-curves in an isolated control object, that all the other objects in my scene i wish to animate can link back to.
Hope that helps.
I can’t seem to figure out how to add a driver. I tried switching from F-Curves to Drivers, but nothing shows up. Adding a marker doesn’t seem to do much either. Maybe you could give me some sort of example script as well, because I’m not sure exactly what I’m looking for here. Sorry if I seem new to this, but I’ve just never came across an issue like this.
Nevermind. Finally got it working! Thanks a lot for your very detailed answer. This helped out my project a lot.
Yeah, to add a driver, you have to right click on the property you wish to animate and choose “Add Drives” or “Add Single Driver”. To tell you the truth i think its kindof a pain, and I’m pretty pissed that the blender team have basically removed all the older methods of more in depth real time scripting such as pyConstraints and scriptLinks.
As a guy that does mainly television motion graphics this has presented a bit of a problem for my workflow. In my opinion, the only reason why Cinema4D continues to be the insustry standard in this field is because of its animation scripting and MoGraph toolkit, which blender seems to have really taken a step backwards with in the 2.5 release. But enough of my ranting and raving, you work with what you’ve got i guess.
In case anyone else is interested, I’ve attached a blend file with the drivers and stuff already set up for sound baked to f-curves
AudioLink.blend (424 KB)
yep, even drivers are much easier to setup in cinema, but that just means things can improve
try the little addon i wrote in upper link, you get a curve to copy and paste/transform elsewhere
I know it’s an old thread, but it has good SEO placement.
One technique you can use if you just want to get a rough idea of the highs in a sound clip and map them to another value is to setup a dummy object or node and then map the sound to an f-curve for that dummy object/node. Then in the graph editor you can overlay the value you want to set to the sound over the baked curve and use it as a reference for keyframed points. It’s not perfect but it works.