» AviSynth is a powerful video FrameServer for Win32.

AviSynth Links:
»Learn to script
»Discussion fora
»Project page
»External filters

» You can add pages to this website immediately. No login required.
Edit this document

» AboutAviSynth




( Diese Seite in flag-germany.gif Deutsch )

Trim(clip clip, int first_frame, int last_frame)

Trim(clip clip, int first_frame, int -num_frames)

Trim trims a video clip so that it includes only the frames first_frame through last_frame. The audio is similarly trimmed so that it stays synchronized. Remember AviSynth starts counting at frame 0.

If you pass a negative number for last_frames it returns frames first_frame through first_frame + num_frames - 1. For example:

Trim(100,-100) # same as Trim(100,199)

If you pass 0 for last_frame it means "end of the clip". This also means the only way to return just the first frame is to use the alternate syntax with num_frames. For example:

Trim(100,0) # deletes the first 100 frames

Trim(0,-1) # NOT the same as Trim(0,0) -- that would just return the whole thing

SourceForge Logo


Edit this document | View document history
Document last modified Tue, 22 Mar 2005 16:47:41