View Full Version : How dose can "SelectEvery" command be used to....
Jynks
2nd November 2009, 08:53
Hi there...
I got some help form a guy on this fourm and he made this script for me...
#Sample avs script
#It is necessary that the resolution of all images is the same.
ImageReader("your imagefoler\img%04d.jpg",1,1000)
SelectEvery(2,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1)
AssumeFPS(25000,1000)
It is a simple script that simply loads a image sequence into VdubMod and on compile.. each image is held for 1/2 a second before the next frame is called...
So.. how dose this work.. as 1/2 a second is to short for the "timelapse" look I am going for... Can som,one please explain to me how this command works so I canplay with diffrent values and get a "pause on image b4 next frame" value that works well?
Thanks in advance
rkalwaitis
2nd November 2009, 09:10
Neuron has an explanation of it here.
http://neuron2.net/www.math.berkeley.edu/benrg/avisynth-reference.html#SelectEvery
Jynks
2nd November 2009, 09:54
Yea I read that but i do not understand it.... it seams to be saying that this selectevery is only used for selecting frame ranges... so like every 10th frame or every 2nd frame.. I can not see anything on how to select a frame and hold it for a period of time before selecting the next one
GodofaGap
2nd November 2009, 10:04
IMO the script given to you is bad usage of selectevery here.
What you want can be done much easier with
ImageReader("your imagefoler\img%04d.jpg",1,1000)
Assumefps(a,b)
Changefps(25,1) # this is optional for if you need to convert your frame rate to a standard frame rate
'a' and 'b' are integer values that determine the length of each image in seconds by
length in seconds = b/a
For example if you want an image to be shown 0.7 seconds, 'b' should be 7 and 'a' should be 10 (7/10 = 0.7)
Gavino
2nd November 2009, 10:14
Yes, ChangeFPS is the better solution here.
Explanation of original version:
SelectEvery(2,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1)
takes each pair of frames and repeats the first one 13 times and the second one 12 times. After setting the frame rate to 25fps, that means that each image will be shown alternately for 13/25 sec and 12/25 sec each. (only approx 1/2 sec)
Jynks
2nd November 2009, 10:25
IMO the script given to you is bad usage of selectevery here.
What you want can be done much easier with
ImageReader("your imagefoler\img%04d.jpg",1,1000)
Assumefps(a,b)
Changefps(25,1) # this is optional for if you need to convert your frame rate to a standard frame rate
'a' and 'b' are integer values that determine the length of each image in seconds by
length in seconds = b/a
For example if you want an image to be shown 0.7 seconds, 'b' should be 7 and 'a' should be 10 (7/10 = 0.7)
Interesting... so... if I wanted each image to be up for an entire second....
Pause on each from for:-
1 second:- a=1, b=1 (1/1 = 1.0 second)
1/2 a second:- a=10, b= 5 (5/10 = 0.5 seconds)
3 second:- a=1, b=3 (3/1 = 3.0 Second)
then just add
Changefps(25,1)
To fit it into a standard frame rate?
Is this all correct?
GodofaGap
2nd November 2009, 11:24
You got it.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.