View Single Post
Old 25th March 2013, 21:15   #9  |  Link
Gavino
Avisynth language lover
 
Join Date: Dec 2007
Location: Spain
Posts: 3,431
Quote:
Originally Posted by bennynihon View Post
... it complains that it doesn't know what grainStrY is. Odd because it's assigned a value directly above in the FrameEvaluate line.
That assignment happens (for each frame) at run-time, but your assignment to ydiff is done (once only) at compile-time, when grainStrY does not yet exist. You need to put that assignment inside a FrameEvaluate as well.
Code:
FrameEvaluate("global ydiff = ydiff + grainStrY", after_frame=true)
__________________
GScript and GRunT - complex Avisynth scripting made easier
Gavino is offline   Reply With Quote