Here is a small editable
Avisynth script, to import sequences of single image files into a video editing and encoding software like VirtualDub or Avidemux.
All you need is Avisynth 2.6 and the FFmpeg plugin for Avisynth.
Once installed, you can create a new .avs file and paste the script in it.
If the video and audio variables are set proper, the script could be opened as a video in
VirtualDub and other video editors.
[quote]#
#LoadPlugin(“X:…\ffms2.dll”)
#for the case, that avisynth does not find the FFmpeg plugin
#video variables
##########################################################################
startframe = 0
endframe = 0
lcdigits = “%07.0f” #enumerate images files with 7 leading digits
framerate = 24
v_dir = “” #directory of the image files
v_filename = “” #name of the image files
v_filetype = “” #file type of the images
#audio variables
#########################################################################
delay = 0 #audio delay in
ms
a_dir = “” #directory of the audio file
a_filename = “” #name of the audio file
a_filetype = “” #file type of the audio
#########################################################################
#load video
#########################################################################
inf=FFImageSource(v_dir+v_filename+String(startframe, lcdigits)+v_filetype)
v_width = inf.Width
v_height = inf.Height
v_type = inf.PixelType
video = BlankClip((endframe-startframe), v_width, v_height, pixel_type=v_type).KillAudio()
video = video.ScriptClip(""“FFImageSource(String(current_frame+startframe, v_dir+v_filename+lcdigits)+v_filetype)”"")
video = video.AssumeFPS(framerate)
#video filters
################################
#video = video.Levels(0,1,255,255,0) #converts video from negative to positve
#video = video.ConvertToRGB()
#video = video.ConvertToYUY2()
#video = video.ConvertToYV12() #only color space supported by avidemux
#video = video.Spline64Resize(720,576) #resizes video to given resolution (SD PAL), width = 720, height = 576
#video = video.TurnLeft() #rotates video by 90° counterclockwise
#video = video.TurnRight() #rotates video by 90° clockwise
#video = video.Tun180() #rotates video by 180°
########################################################################
#load audio (if present)
########################################################################
“” != (a_dir+a_filename+a_filetype) ? Eval(""“audio = FFAudioSource(a_dir+a_filename+a_filetype)”"") : Eval(""“audio = BlankClip()”"")
dubvid = AudioDubEx(video, audio).DelayAudio(Float(delay)/1000)
#audio filters
################################
#dubvid = dubvid.Normalize(1.0) #1.0 for peaking at 0dB
#dubvid = dubvid.ConvertAudioTo16bit()
#dubvid = dubvid.ConvertAudioTo24bit()
#dubvid = dubvid.ConvertAudioTo32bit()
#dubvid = dubvid.ConvertAudioToFloat()
#dubvid = dubvid.ResampleAudio(48000) #resamples audio to given sampling rate, spr = 48kHz
return dubvid[/quote]
Example:
[quote] #
#video variables
##########################################################################
startframe = 0
endframe = 1000
lcdigits = “%07.0f” #enumerate images files with 7 leading digits
framerate = 24
v_dir = “X:\video” #directory of the image files
v_filename = “video1_” #name of the image files
v_filetype = “.dpx” #file type of the images
#audio variables
#########################################################################
delay = 875 #875ms are 21 frames at a framerate of 24fps
a_dir = “X:\audio” #directory of the audio file
a_filename = “audio1” #name of the audio file
a_filetype = “.wav” #file type of the audio [/quote]
If the audio variables are left as in the unedited script, the video will be opened without
audio. So the audio can be added via the video editor or encoder