Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 1st October 2016, 12:42   #1  |  Link
BlockABoots
Registered User
 
Join Date: Dec 2012
Posts: 163
Help Needed With Time lapse

Im trying to make a time lapse video and need to remove certain parts of the video. This is my current script in AvsPmod.....

Code:
video=DirectShowSource("F:\Video Captures\2016-09-28_17-39-08.flv",audio=false).trim(164960,248037).trim(250614,272335).trim(272511,496443).trim(497934,515556).trim(515737,522800).selectevery(35,0).assumefps(29.97)
return=video
but the video clip is only like half a second long, im guessing its to do with the 'trims' ive made but not sure why its only make the video click half a second when it should be approx 5 minutes long??
BlockABoots is offline   Reply With Quote
Old 1st October 2016, 12:55   #2  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Try something like this:
Code:
v=XXSource()
a = v.trim(164960,248037)
b = v.trim(250614,272335)
c = v.trim(272511,496443)
d = v.trim(497934,515556)
e = v.trim(515737,522800)
a++b++c++d++e
__________________
Groucho's Avisynth Stuff
Groucho2004 is offline   Reply With Quote
Old 1st October 2016, 13:11   #3  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
As G2K4 said.

blockaboots, your script acts sort of like this (leaving out a few things)
Code:
DirectShowSource("F:\VideoCaptures\2016-09-28_17-39-08.flv",audio=false)

a=trim(164960,248037)
b=a.trim(250614,272335)
c=b.trim(272511,496443)
d=c.trim(497934,515556)
d.trim(515737,522800)      # assign to last
eg b is result of trimming already trimmed a, and not result of trimming original clip.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 1st October 2016 at 13:16.
StainlessS is offline   Reply With Quote
Old 2nd October 2016, 17:50   #4  |  Link
BlockABoots
Registered User
 
Join Date: Dec 2012
Posts: 163
Hmmm, ok i have tried...

Code:
video=DirectShowSource("F:\Video Captures\2016-09-28_17-39-08.flv",audio=false)
video0=trim(164960,248037)
video1=trim(250614,272335)
video2=trim(272511,496443)
video3=trim(497934,515556)
video4=trim(515737,522800).selectevery(35,0).assumefps(29.97)
return video4
but when i press F5 i get the error message...

Quote:
Script error: invalid arguments to function "trim"
whats the issue?
BlockABoots is offline   Reply With Quote
Old 2nd October 2016, 18:06   #5  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
You are not trimming 'video', you are trimming Last (which has not been assigned any value at all).
[EDIT: Also, you are using selectevery(35,0).assumefps(29.97) on only the last trim, not on a spliced result clip.]

try
Code:
DirectShowSource("F:\Video Captures\2016-09-28_17-39-08.flv",audio=false)  # assign to last
a=trim(164960,248037) # Trim from Last
b=trim(250614,272335) # Trim from Last
c=trim(272511,496443) # Trim from Last
d=trim(497934,515556) # Trim from Last
e=trim(515737,522800) # Trim from Last
a++b++c++d++e         # assign spliced clips to Last
selectevery(35,0).assumefps(29.97)
return Last
EDIT: Or as you seem to like typing
Code:
video=DirectShowSource("F:\Video Captures\2016-09-28_17-39-08.flv",audio=false)  # assign to video
video0=video.trim(164960,248037)
video1=video.trim(250614,272335)
video2=video.trim(272511,496443)
video3=video.trim(497934,515556)
video4=video.trim(515737,522800)
videoSpliced=video0++video1++video2++video3++video4
videoOut=videoSpliced.selectevery(35,0).assumefps(29.97)
return videoOut
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 2nd October 2016 at 18:21.
StainlessS is offline   Reply With Quote
Old 2nd October 2016, 19:53   #6  |  Link
BlockABoots
Registered User
 
Join Date: Dec 2012
Posts: 163
Ok thanks
BlockABoots is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:31.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.