• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

how can I make expresion work vice versa ?

Community Beginner ,
Jul 13, 2017 Jul 13, 2017

Copy link to clipboard

Copied

Hi!

Been making a music visualizer that includes some speed up expresions. Basicly in one main comp I have 2 pre-comps of visualizer [inside and outside] The outter one is basicly a stroke and audio spectrum, spining in a circle around the logo, and it speeds up every time theres bass [Im using sound keys to check where the bass is]5.png

[expresion I use]

spd = thisComp.layer("SoundKeys").effect("Sound Keys")("Output 1")

mult = .5;

n = spd.numKeys;

if (n > 0 && spd.key(1).time < time){

  accum = spd.key(1).value*(spd.key(1).time - inPoint);

  for (i = 2; i <= n; i++){

    if (spd.key(i).time > time) break;

    k1 = spd.key(i-1);

    k2 = spd.key(i);

    accum += (k1.value + k2.value)*(k2.time - k1.time)/2;

  }

  accum += (spd.value + spd.key(i-1).value)*(time - spd.key(i-1).time)/1;

}else{

  accum = spd.value*(time - inPoint);

}

value + accum*mult

-----------------------------------------------------------------------------------------------------------------------------------------------
Inside the "Stroke" pre-comp I have stroke and audio visualizer [2collor] keyframed to rotate in place for 10 [its not a loop, its keyframed to rotate like 180 times]6.png

The problem Im getting is, that in my main comp, when it speeds up and speed downs, the spectrum gets out of sync because it speeds up not only the spining but the spectrum aswell.
  Is there a way for me to effect only spining, but not whole comp ? Maybe I can pre-comp visualizer and aply the same expresion just to slower the video not to speed it up ? [Im not the best with expresions, tried to change numbers in it to negative din't really worked] Or maybe I can apply the expresion not only to time remaping but to rotation aswell ?

Any suggestions or ideas are apreciated ! 

Views

234

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jul 13, 2017 Jul 13, 2017

Nothing stops you from using the result from one expression as a multiplier on the other, but of course using time-remapping won't work. You can not muddle up things. Either you use the expressions on the native properties or on time-remapping, but not both. You have to make your mind up about it and think it through rather than just grabbing expressions from the web whose inner workings you don't understand.

Mylenium

Votes

Translate

Translate
LEGEND ,
Jul 13, 2017 Jul 13, 2017

Copy link to clipboard

Copied

LATEST

Nothing stops you from using the result from one expression as a multiplier on the other, but of course using time-remapping won't work. You can not muddle up things. Either you use the expressions on the native properties or on time-remapping, but not both. You have to make your mind up about it and think it through rather than just grabbing expressions from the web whose inner workings you don't understand.

Mylenium

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines