2017-10-23 16 views
0

에 대한 지수 autofade 발현 난 그냥 아래의 식을 추가하여 내 배경 음악의 끝을 autofade하는 선형 autofade 식을 사용하고있다 : 그러나는 AE 수정 ExtendScript - 오디오

fadeTime = 9; 
audio.audioLevelsMin = -50; 
audio.audioLevelsMax = 0; 
layerDuration = outPoint - inPoint; 
singleFrame = thisComp.frameDuration; 
animateOut = linear(time, (outPoint - fadeTime+1), (outPoint-singleFrame), audio.audioLevelsMax, audio.audioLevelsMin); 
[animateOut,animateOut]; 

, 이것은 단지입니다 선형 페이드. 기하 급수적 인 변덕을 만들고 싶습니다. 이것은 표현식에서도 가능합니까?

지수는 완전하게 올바른 단어 아마도 - 그래서 오른쪽 단어를 알고 부족, 내가 무엇을 의미하는지 보여주기 위해 아래 이미지를 게시하도록하겠습니다 :

enter image description here

+0

After Effects 질문은 videoproduction.stackexchange.com에서 더 많은 관심을받습니다. – stib

답변

0

당신이 원하는 페이드 x = -1과 x = 1 사이의 y = 0 - (x^3)처럼 보입니다.

enter image description here 그래서 우리는 -1에서 1까지 진행 정규화 변수 t를 생성하여 해당 범위에 페이드 매핑 및 다음 큐브 다음 범위 1-0

enter image description here

해당 다시 매핑
fadeTime = 9; 
levelsMin = -50; 
levelsMax = 0; 

//not sure why you want to add an extra second to the fade time, but I included the + 1 
fadeStart = outPoint - fadeTime+1; 

t = linear(time, fadeStart, outPoint, 1, -1); //t goes from 1 to -1 over the fade 
fade = 0.5 + Math.pow(t, 3)/2; // goes from 1 to 0, but with the curve you want 
// map 1 → 0 ⇒ levelsMax → levelsMin 
finalLevel = levelsMin + fade * (levelsMax - audio.audioLevelsMin); 
[finalLevel, finalLevel]