FORUMS: list search recent posts

Animation of temperature graph

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
janek dole
Animation of temperature graph
on Jan 15, 2020 at 1:36:06 pm

Hey guys, I would appreciate your help and insight, how I could solve this problem:

I have a weekly temperature graph. Temperature values are taken from Txt file and with an expression converted to Y position value of Null layer. So, whenever I update the txt. file, the temperatures jumps in their position. Saves me ton of time.

But... I woul love to improve this, animate it so the temperature line moves to its position. I mean, in the begining it would be flat (all Nulls in the middle at 780px) and than every Null moves to whatever value it has.

I tried to use a slider to animate it from 0>100% of its position but I can not find a way to join my expression to a slider part of expression, it works separately though:)

//this works ☺ expression only for Y position, no movement

//overall minimal temperature in graph, already set in the txt file
var minValue = footage("weeklytemp_2020.txt").dataValue([5,0]);
//overall maximal temperature in graph, already set in the txt file
var maxValue = footage("weeklytemp_2020.txt").dataValue([6,0]);

//here I adjust values so the graph matches my vertical range of 880-680px
var temperature = footage("tyden_2020.txt").dataValue([3,0]);

I would like to add something like this:

//one slider could operate all Nulls, every null yould have different endPosition
sliderValue = thisComp.layer("control1").effect("Slider Control")("Slider");
startPosition = 780;
endPosition = ?? ...... here lies the problem, this value is the output from code above, how could I get it in here?

I hope you could understand what I am trying to do and possibly help me, thank you guys!


Return to posts index

Graham Quince
Re: Animation of temperature graph
on Jan 19, 2020 at 3:07:39 pm

I’ve only ever used linear() with time as the first variable, what we’re looking at for you is:

Current time,

Starting time,

End time,

Start position (i.e. 780),

End position (i.e. final calculated temperature position)


So start time would be 0, end time would be the time the animation takes.

I think. Hope it’s right.

Sounds like a useful project. - Free FX for amateur films - FX blog

Return to posts index

janek dole
Re: Animation of temperature graph
on Jan 20, 2020 at 3:36:17 pm

thank you Graham! I will definitely try your solution.

I SOLVED this not in the most elegant way I guess... I doubled the number of Nulls and its all animated through a Slider controll... but it works 😃

- so the line graph is operated with a set of Nulls, they get their position from txt file

- Now Ive created another set of Nulls, so one group of Nulls for holding the position data, the other group for movement

- it is connected to 1 slider, when on 0 its on start position (all flat) and when on 100 it moves to final position

You could see the animation concept here:

Thank you!

Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2020 All Rights Reserved