こんにちは、よろしくお願いします。
AviSynth CUDA Filters関係を使ってみたいと思い
Avisynth2.6.0(32bit) -> AvisynthNeo-r2822(32bit) に変更してみたのですが、
AutoVfrのログが正しく出力されない症状が発生しました。
(Avisynth2.6.0時点では正常に処理されていたスクリプトです)
スクリプト中でプラグイン読み込みエラーや書式エラーは発生していません。
またAvsPModNeoのプレビューなどでも特におかしな挙動はありませんでした。
何かお分かりになりますでしょうか?
AutoVFR_log_temp.avs: スクリプトファイル本体
AutoVFR_log_temp1.txt: AutoVfrの出力先ログファイル
AutoVFR_log_temp.avs
※LoadPlugin関係省略
function Auto_VFR(clip c,string file,int "cut",int "number"
,int "cthresh",int "mi", bool "chroma", int "blockx", int "blocky"
,bool "IsCrop",int "crop_height",bool "IsTop",bool "IsBottom",bool "show_crop"
,bool "IsDup",int "thr_m",float "thr_luma"){
h=c.height()
count=c.framecount()
dwc=c.DoubleWeave()
dcount=dwc.framecount()
Iscut=Defined(cut)?true:false
Isnumber=Defined(number)?true:false
Assert(Iscut==Isnumber,"specify 'cut' and 'number'")
start=Isnumber?int(dcount*float(float(number-1)/float(cut))):0
end=Isnumber?int((dcount *float(float(number)/float(cut))))-1:0
dwc=Iscut?dwc.Trim(start,end):dwc
HDsize=720
IsDup=default(IsDup,false)
cthresh_default=(IsDup==true)?7:(h>=HDsize)?9:7
mi_default=(IsDup==true)?50:(h>=HDsize)?80:50
blocks_default=(h>=HDsize)?16:32
cthresh=default(cthresh,cthresh_default)
mi=default(mi,mi_default)
chroma=default(chroma,false)
blockx=default(blockx,16)
blocky=default(blocky,blocks_default)
crop_height=default(crop_height,(h==HDsize)?280:120)
mod=(IsYV12(c)==true)?4:2
Assert((h-crop_height)%mod==0,"crop_height is invalid.")
IsCrop=default(IsCrop,false)
IsTop=default(IsTop,false)
IsBottom=default(IsBottom,true)
show_crop=Default(show_crop,false)
thr_m=default(thr_m,10)
thr_luma=default(thr_luma,0.010)
int_t=( IsCrop==true && IsTop==true)?crop_height:0
int_b=( IsCrop==true && IsBottom==true)?crop_height:0
ScriptClip(dwc,"""
prg="0"
cmb="1"
start="""+string(start)+"""
count="""+string(count)+"""
dcount="""+string(dcount)+"""
file=""""+file+""""
cth="""+string(cthresh)+"""
mi="""+string(mi)+"""
chrm="""+string(chroma)+"""
bx="""+string(blockx)+"""
by="""+string(blocky)+"""
int_t="""+string(int_t)+"""
int_b="""+string(int_b)+"""
show="""+string(show_crop)+"""
isDup="""+string(IsDup)+"""
thr_m="""+string(thr_m)+"""
thr_luma="""+string(thr_luma)+"""
crnt=current_frame+start
str_num=string(crnt)
str_line=string("-")
str_total=(start==0)?string("total_f-")+string(count):""
str_dtotal=string("doubleweave_f-")+string(dcount)
(current_frame==0)?WriteFile(last,file,"str_total",append=false):nop
(crnt==0)?WriteFile(last,file,"str_dtotal",append=true):nop
str_main=(IsCombedTIVTC(last,
\cthresh=cth,MI=mi,chroma=chrm,blockx=bx,blocky=by)==true)?cmb:prg
str_crop=(int_t>0 || int_b>0)?(IsCombedTIVTC(last.crop(0,int_t,0,-int_b),
\cthresh=cth,MI=mi,chroma=chrm,blockx=bx,blocky=by)==true)?cmb:prg
:str_main
str_motion=(isDup==true && crnt%2 == 0)?
(Interleave(SelectEven().mt_motion(thY2=thr_m),SelectOdd()).AverageLuma() >thr_luma)?cmb:prg
:prg
result=str_num+str_line+str_main+str_line+str_crop+str_line+str_motion
(show==false)?WriteFile(last,file,"string(result)",append=true,flush=false):last
""")
return (show_crop==true)?last.crop(0,int_t,0,-int_b):last
}
MPEG2VIDEO("C\src\clip.ts")
clip0.AssumeTFF()
Trim(598,951)
Auto_VFR("C:\temp\AutoVFR_log_temp1.txt", cut=1, number=1, cthresh=80, mi=60, blockx=16, blocky=32, chroma=false, IsCrop=true, crop_height=136, IsTop=false, IsBottom=true, show_crop=false)
AutoVFR_log_temp1.txt
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
(以下繰り返し、略)
以上、よろしくお願いします。
こんにちは、よろしくお願いします。
AviSynth CUDA Filters関係を使ってみたいと思い
Avisynth2.6.0(32bit) -> AvisynthNeo-r2822(32bit) に変更してみたのですが、
AutoVfrのログが正しく出力されない症状が発生しました。
(Avisynth2.6.0時点では正常に処理されていたスクリプトです)
スクリプト中でプラグイン読み込みエラーや書式エラーは発生していません。
またAvsPModNeoのプレビューなどでも特におかしな挙動はありませんでした。
何かお分かりになりますでしょうか?
AutoVFR_log_temp.avs: スクリプトファイル本体
AutoVFR_log_temp1.txt: AutoVfrの出力先ログファイル
AutoVFR_log_temp.avs
※LoadPlugin関係省略
function Auto_VFR(clip c,string file,int "cut",int "number"
,int "cthresh",int "mi", bool "chroma", int "blockx", int "blocky"
,bool "IsCrop",int "crop_height",bool "IsTop",bool "IsBottom",bool "show_crop"
,bool "IsDup",int "thr_m",float "thr_luma"){
h=c.height()
count=c.framecount()
dwc=c.DoubleWeave()
dcount=dwc.framecount()
Iscut=Defined(cut)?true:false
Isnumber=Defined(number)?true:false
Assert(Iscut==Isnumber,"specify 'cut' and 'number'")
start=Isnumber?int(dcount*float(float(number-1)/float(cut))):0
end=Isnumber?int((dcount *float(float(number)/float(cut))))-1:0
dwc=Iscut?dwc.Trim(start,end):dwc
HDsize=720
IsDup=default(IsDup,false)
cthresh_default=(IsDup==true)?7:(h>=HDsize)?9:7
mi_default=(IsDup==true)?50:(h>=HDsize)?80:50
blocks_default=(h>=HDsize)?16:32
cthresh=default(cthresh,cthresh_default)
mi=default(mi,mi_default)
chroma=default(chroma,false)
blockx=default(blockx,16)
blocky=default(blocky,blocks_default)
crop_height=default(crop_height,(h==HDsize)?280:120)
mod=(IsYV12(c)==true)?4:2
Assert((h-crop_height)%mod==0,"crop_height is invalid.")
IsCrop=default(IsCrop,false)
IsTop=default(IsTop,false)
IsBottom=default(IsBottom,true)
show_crop=Default(show_crop,false)
thr_m=default(thr_m,10)
thr_luma=default(thr_luma,0.010)
int_t=( IsCrop==true && IsTop==true)?crop_height:0
int_b=( IsCrop==true && IsBottom==true)?crop_height:0
ScriptClip(dwc,"""
prg="0"
cmb="1"
start="""+string(start)+"""
count="""+string(count)+"""
dcount="""+string(dcount)+"""
file=""""+file+""""
cth="""+string(cthresh)+"""
mi="""+string(mi)+"""
chrm="""+string(chroma)+"""
bx="""+string(blockx)+"""
by="""+string(blocky)+"""
int_t="""+string(int_t)+"""
int_b="""+string(int_b)+"""
show="""+string(show_crop)+"""
isDup="""+string(IsDup)+"""
thr_m="""+string(thr_m)+"""
thr_luma="""+string(thr_luma)+"""
crnt=current_frame+start
str_num=string(crnt)
str_line=string("-")
str_total=(start==0)?string("total_f-")+string(count):""
str_dtotal=string("doubleweave_f-")+string(dcount)
(current_frame==0)?WriteFile(last,file,"str_total",append=false):nop
(crnt==0)?WriteFile(last,file,"str_dtotal",append=true):nop
str_main=(IsCombedTIVTC(last,
\cthresh=cth,MI=mi,chroma=chrm,blockx=bx,blocky=by)==true)?cmb:prg
str_crop=(int_t>0 || int_b>0)?(IsCombedTIVTC(last.crop(0,int_t,0,-int_b),
\cthresh=cth,MI=mi,chroma=chrm,blockx=bx,blocky=by)==true)?cmb:prg
:str_main
str_motion=(isDup==true && crnt%2 == 0)?
(Interleave(SelectEven().mt_motion(thY2=thr_m),SelectOdd()).AverageLuma() >thr_luma)?cmb:prg
:prg
result=str_num+str_line+str_main+str_line+str_crop+str_line+str_motion
(show==false)?WriteFile(last,file,"string(result)",append=true,flush=false):last
""")
return (show_crop==true)?last.crop(0,int_t,0,-int_b):last
}
MPEG2VIDEO("C\src\clip.ts")
clip0.AssumeTFF()
Trim(598,951)
Auto_VFR("C:\temp\AutoVFR_log_temp1.txt", cut=1, number=1, cthresh=80, mi=60, blockx=16, blocky=32, chroma=false, IsCrop=true, crop_height=136, IsTop=false, IsBottom=true, show_crop=false)
AutoVFR_log_temp1.txt
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'str_total' means.
I don't know what 'str_dtotal' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
I don't know what 'result' means.
(以下繰り返し、略)
以上、よろしくお願いします。