Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Forums Adobe After Effects Expressions Transition from Hex Color to another from CSV displayed in Text layer

  • Transition from Hex Color to another from CSV displayed in Text layer

  • Gregory Graham

    September 22, 2021 at 11:18 pm

    Hi there! I’m trying to make a template that would make a video which would transition from one color to another. The first and second colors would be loaded from a CSV. I’ll include a link to an example of what I would want the finished product to look like:

     

    https://youtu.be/EbNVcFyIGKo

     

    My issue is – this concept works when entering the colors manually as keyframes. When I try to enter the colors via an expression referring to a CSV, the text layer/color does not constantly update/transition.

     

    For reference, the expression in my Color layer referring to the CSV reads as follows:

    colorText = thisComp.layer("Gradient Gram - CSV.csv")("Data")("Outline")("Left Color")("Left Color 0").toString();
    hexToRgb(colorText);

     

     

    This is the first color, the second color in my CSV would be (“Right Color”)(“Right Color 0”). I tried unsuccessfully to keyframe to this change.

     

    Any thoughts/ideas/help would be greatly appreciated!
    Thank you!

     

    Some contents or functionalities here are not available due to your cookie preferences!

    This happens because the functionality/content marked as “Google Youtube” uses cookies that you choosed to keep disabled. In order to view this content or use this functionality, please enable cookies: click here to open your cookie preferences.

  • Fabrice Leconte

    September 24, 2021 at 3:36 am

    Hello,

    You can use a linear expression

    c1 = thisComp.layer('Gradient Gram - CSV.csv')('Data')('Outline')('Left Color')('Left Color 0').toString();

    // #000000

    c2 = thisComp.layer('Gradient Gram - CSV.csv')('Data')('Outline')('Right Color')('Right Color 0').toString();

    // #FFFFFF

    linear(time,0,10,hexToRgb(c1),hexToRgb(c2));

  • Gregory Graham

    September 24, 2021 at 9:18 pm

    This worked perfectly, thank you so much!

    😄

Viewing 1 - 3 of 3 posts

Log in to reply.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy