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. |
8th November 2013, 18:01 | #1041 | Link |
Registered User
Join Date: Sep 2006
Posts: 1,657
|
I did the test with the vpy script through using the VSimport wrapper, seems that it slows down the speed quite a lot, compared to simply threw the vpy script into virtualdub and ran analysis pass.
with wrapper: R21 --> 30 test1 --> 35 test2 --> crash without wrapper: R21 --> 40 test1 --> 65 test2 --> crash |
8th November 2013, 19:16 | #1042 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
I'll take a serious look at it later tonight. It should be almost as fast as tdecimate at least.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
8th November 2013, 20:05 | #1043 | Link | |
Registered User
Join Date: Sep 2006
Posts: 1,657
|
Quote:
Code:
vspipe "clip.vpy" - -y4m | x264 --preset fast --demuxer y4m --output "clip.mkv" - |
|
9th November 2013, 02:14 | #1045 | Link | |
Registered User
Join Date: Sep 2006
Posts: 1,657
|
Quote:
Code:
vspipe "clip.vpy" NUL |
|
10th November 2013, 13:42 | #1046 | Link |
Beyond Kawaii
Join Date: Feb 2008
Location: Russia
Posts: 724
|
https://bitbucket.org/mystery_keeper...te-vapoursynth
Mature enough, or still needs improvements?
__________________
...desu! |
10th November 2013, 16:24 | #1047 | Link |
Pajas Mentales...
Join Date: Dec 2004
Location: Spanishtán
Posts: 496
|
Hi Mystery Keeper
what is stdbool.h? http://sl1pkn07.no-ip.com/paste/view/97611430 howto build? "gcc -o templinearapproximate.so main.c -I/usr/include/vapoursynth -I"put here stdbool.h path" ? greetings |
10th November 2013, 16:42 | #1048 | Link |
Software Developer
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
|
Support for the "bool" type as well as the "true" and "false" constants in C language:
http://pubs.opengroup.org/onlinepubs...stdbool.h.html It's required, because C did not have a "bool" type before C99. Legacy code might still use "bool", "true" and "false" for other purposes, since they were not reserved before C99. So if you want C++-style booleans in C, you have to include <stdbool.h> or just define those three macros yourself. MSVC still doesn't support C99
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊ Last edited by LoRd_MuldeR; 10th November 2013 at 16:59. |
10th November 2013, 17:13 | #1049 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
The variable frames and planes can be allocated on the stack as an array of size 3. There will never be more than 3 planes in a format. You should be able to eliminate most other allocations as well using variable length arrays since you went with C99. https://bitbucket.org/mystery_keeper...=master#cl-208 You should pass input frame n instead of NULL. Otherwise all the existing properties such as colorimetry and times won't be copied over to your output frame. "planes:int[]: opt:empty;" <- you probably don't want empty there, it's most likely an error if a user wants to filter no planes https://bitbucket.org/mystery_keeper...=master#cl-114 "tla" should be "TempLinearApproximate". It makes more sense if the name reported when an error happens also matches the function used to create the filter. That's all I could see. The only other small comment I have that should probably be ignored is that this would be a good function to implement with templates in C++ to avoid repeating it.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
10th November 2013, 17:40 | #1051 | Link | |
Beyond Kawaii
Join Date: Feb 2008
Location: Russia
Posts: 724
|
Quote:
Also, silly me. Didn't free write pointers. That would cause a memory leak, so if anyone's already using it - you should update.
__________________
...desu! Last edited by Mystery Keeper; 10th November 2013 at 17:52. |
|
10th November 2013, 18:02 | #1052 | Link | |
Guest
Posts: n/a
|
Quote:
|
|
11th November 2013, 13:46 | #1053 | Link |
Registered User
Join Date: Mar 2012
Location: Texas
Posts: 1,666
|
Hi handaimaoh, welcome to the forum.
Great news about your progress/plans for RemoveDirt. Regarding SCSelect what's your thoughts about adding functionality to be able to output a scene change log and also make it compatible so that other plugins can use it as their scene change detector? (Similar to Chikuzen's scenechange plugin) |
11th November 2013, 14:21 | #1054 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
Note that Chikuzen's scenechange plugin also uses the absolute difference and should produce almost identical results. If you want the relative threshold mode as well just write a feature request Chikuzen.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet Last edited by Myrsloik; 11th November 2013 at 14:26. Reason: One more thing |
|
11th November 2013, 16:15 | #1056 | Link | |
͡҉҉ ̵̡̢̛̗̘̙̜̝̞̟̠͇̊̋̌̍̎̏̿̿
Join Date: Feb 2009
Location: No support in PM
Posts: 712
|
Quote:
__________________
dither 1.28.1 for AviSynth | avstp 1.0.4 for AviSynth development | fmtconv r30 for Vapoursynth & Avs+ | trimx264opt segmented encoding |
|
11th November 2013, 16:52 | #1057 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
Code:
if( dirmult * olddiff < lastdiff ) goto set_end; if( dirmult * lastdiff < olddiff ) goto set_begin;
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
11th November 2013, 17:42 | #1058 | Link |
Registered User
Join Date: Sep 2008
Posts: 365
|
There's a speed difference between SCSelect and using Avisynth's built-in runtime functions (xDifferenceFromPrevious/xDifferenceToNext), SCSelect is quite faster, no idea if the same would apply to vapoursynth's internal functions though...
__________________
(i have a tendency to drunk post) |
11th November 2013, 18:23 | #1060 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
SCSelect_Like function in script (behaves identically and not very good) from here:- http://forum.doom9.org/showthread.ph...23#post1644023
Code:
Avisource("D:\avs\test.avi") # RemoveDirt's SCSelect(clip input, clip scene_begin, clip scene_end, clip global_motion, float dfactor, bool debug, bool planar) Function SCSelect_Like(clip dclip,clip Start,clip End,clip Motion, float "dfactor",bool "debug") { # Start, End, Motion MUST all be same, dclip can be other colorspace/size (unlike SCSelect). dfactor=Float(Default(dfactor,4.0)) debug=Default(debug,false) Global SCM_A=0.0 Global SCM_B=0.0 Global SCM_SC=0 Global SCM_Prev=-1 Motion.ScriptClip(""" NotNext = (current_frame!=SCM_Prev+1) Global SCM_A=(NotNext)? RT_LumaDifference(dclip,dclip,n=current_frame-1,n2=current_frame) : SCM_B Global SCM_B= RT_LumaDifference(dclip,dclip,n=current_frame,n2=current_frame+1) # 0 = Start of scene, 1 = End of scene, 2 = Global motion Global SCM_SC=(current_frame==FrameCount-1)?1:(SCM_A>dfactor*SCM_B || current_frame==0)?0:(SCM_B>dfactor*SCM_A)?1:2 (SCM_SC==0) ? Start : (SCM_SC==1) ? End : Last # Choose Start, End or Motion(ie Last) (debug)?RT_Subtitle("%d ] %6.2f %6.2f SC=%d",current_frame,SCM_A,SCM_B,SCM_SC):NOP Global SCM_Prev=current_frame Return Last """,args="dfactor,Start,End,Dclip,debug") # Needs Grunt for args return Last } Start=Subtitle("START OF SCENE",align=3,size=30) End=Subtitle("END OF SCENE", align=1,size=30) Motion=Subtitle("GLOBAL MOTION",align=5,size=30) L=SCSelect_Like(Last,Start,End,Motion,debug=true) R=SCSelect(Last,Start,End,Motion) StackHorizontal(L,R)
__________________
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 ??? |
Tags |
speed, vaporware, vapoursynth |
|
|