Can't get Avisynth Proxy to open my .avi clip

Started by torpare, March 10, 2012, 03:02:05 PM

Previous topic - Next topic

torpare

Last July I succeeded (thanks to Agent_007) in using Avisynth Proxy to open a clip in Avidemux, the aim being to apply an external Avisynth filter (DeVCR) to my clip before pre-processing/encoding it with Avidemux.

Unfortunately I then had to abort the encoding because of insufficient free space on my hard disk - and gave-up in disgust.  I still don't have enough space but, not wanting to waste the learning-experience, returned to the project yesterday - expecting to be able to repeat it step-for-step.  Alas, I'm now encountering a problem which didn't occur first time around, and am in need of further guidance.

Here's the scriptfunction DetectVCRLines(clip c,int threshold)
{
  spacial_data = GeneralConvolution(ConvertToRGB(c),0,"0 -1 0 0 2 0 0 -1 0")
  bar_data = ConvertToRGB(BilinearResize(spacial_data,16,c.height))
  st_data = Overlay(bar_data,Trim(bar_data,1,0),mode = "subtract")
  st_data2 = Greyscale(Levels(st_data,threshold,10.0,threshold+1,0,255,coring = false))
  st_data3 = Greyscale(Levels(st_data2,127,10.0,128,0,255,coring = false))
  st_data4 = Overlay(st_data3,st_data3,y = -1, mode = "add")
  return PointResize(st_data4,c.width,c.height)
}

function deVCR(clip c,int threshold)
{
  mybars = DetectVCRLines(c,threshold)
  return Overlay(c,Trim(c,1,0), mask = mybars,greymask = true) 
}

myclip = AVISource("E:\VHS caps\Captures\morgan_test.avi")
fixedclip = deVCR(myclip,30)
return fixedclip
This script opens my clip in Avsp (Avisynth editor).  But when I paste it into AvsProxy, 'Custom' tab and click on 'Create Proxy' I get an error-message which didn't appear on the previous occasion:-
"AVS Proxy has detected an invalid color space. Currently only the YV12 (YUV 4:2:0) color space is supported. Please try appending 'ConvertToYV12' to your script!"
So what has changed?

Using Avsp I've tried to edit the script as suggested, but all my attempts have failed.  Each time I hit one syntactical error or another and don't know how to respond (scripting is a total mystery to me).  So next I tried re-cap'ing the clip (with VDub) making absolutely certain I was using YV12, and got the same error; and when I checked 'Video Info' in Avsp I found that the clip's colorspace is YUY2.  How come?

So I'm completely deadlocked.  Any help would be greatly appreciated.

EDIT  In case it's relevant, I should have mentioned that the clip I'm now trying to open is in black-and-white whereas on the earlier occasion it was in colour.

Agent_007

As it says, add ConvertToYV12 to the input
e.g.
myclip = AVISource("E:\VHS caps\Captures\morgan_test.avi").ConvertToYV12
I am away between 15th of May - 15th of June. (yes, I am playing D3)

torpare

#2
Hi Agent_007

Doing this brings up a script error in Avsp: "syntax error"

EDIT

Sorry!  I didn't notice I'd put a comma as separator not a full-stop.  It now opens in Avidemux