Log in

View Full Version : How to use DV file in avisynth


ADLANCAS
12th September 2004, 14:52
Hi,

I´m just using for the first time my Canon DV device and after reading a lot of info in FAQ, Stickies, threads, search ...I have doubts if I use a script in the right way. Maybe this can be used in the future for DV newbies like me;)

Here is the script that works:
v = AviSource("D:\capture.avi",audio=false)
a = DirectShowSource("D:\capture.avi").AssumeSampleRate(48000)
Return AudioDub(v,a)
Reinterpolate411() # Fix chroma upsampling bug
ReverseFieldDominance() # Change field dominance to TFF

Comments about my tests and script:
- Captured file is DV-type 1 , interlaced and BFF. Checked from TBarry and Shodan scripts available here: http://www.avisynth.org/CheckParity
- DV decoder MainConcept 2.4.4.0
- Avisource (Avisynth 2.55) only open video from DV-type 1(not audio), then I included DirectShowsource to get audio. Since sample rate is wrong only with this command, it´s necessary to set it at 48000.
- Using only DirectShowSource to open video and audio, File Information from VDubMod says FourCC YV12 instead YUY2 when using Avisource.
- After installed Canopus DV decoder and changed FourCC from dvsd to cdvc, file opened in VdubMod continue to show MC decoder:confused:

So, this is the way to open a DV file ?
Is it possible to use MainConcept or Canopus DV Decoder with DirectShowSource?

Thanks for any suggestion,

Alexandre

bb
12th September 2004, 16:05
Another solution is to convert the DV type-1 to type-2 (which is lossless; in fact you only add a second audio stream and make it VfW compatible), then simply open video and audio via AviSource.

Regarding the MainConcept DV decoder: As far as I know it's registered to decode fourcc dvsd and cdvc by default.

bb

David caid
13th September 2004, 21:21
Hello,

I have a Sony HandyCam and I copied my tape on the HHD using the moviemaker software of WinXP. I didn't install anything else regarding my digital cam.
Then, I wanted to used avisynth to apply some filters.
Here is my problem
With Avisynth 2.54, when I want to open my DV type 1 file by writting a .avs script


AviSource(C:\DV\video.avi)

then I have the error message in virtualDub :
Couldn't locate a decompressor for fourCC dvsd

But if I directly open the video.avi with virtualdub 1.6, it works and the decompressor used is "Internal DV decoder"

So I can understand that VirtualDub is able to open the DV file, but why avisource is not opening my file (moviemaker is probably using a MS DV codecs to open and write the file on the HDD).

- Do I have to specify an option for avisource (use a different FourCC to open my file ?
- Do I have to install some codecs (I've seen some thread about that) ?

David

ADLANCAS
13th September 2004, 22:53
@@bb
Yes, this I have already done using Canopus converter. Disadvantage is this process time.
The easiest way is to use another application that delivers DV-Type2 instead of DV-Type1 file and then openning in Avisynth with Avisource as you described.
Thanks.

@David caid
:readfaq: Q5

Alexandre

Video Dude
13th September 2004, 23:06
Originally posted by David caid
With Avisynth 2.54, when I want to open my DV type 1 file by writting a .avs script


AviSource(C:\DV\video.avi)

then I have the error message in virtualDub :
Couldn't locate a decompressor for fourCC dvsd

But if I directly open the video.avi with virtualdub 1.6, it works and the decompressor used is "Internal DV decoder"


If you have no vfw DV codecs on your system then you have to use:

DirectShowSource(C:\DV\video.avi)


You can use AviSource only if you have a DV codec installed. If you need one, MainConcept offers a free playback only DV code.

bb
14th September 2004, 17:37
Originally posted by Video Dude
If you have no vfw DV codecs on your system then you have to use:

DirectShowSource(C:\DV\video.avi)

It should be DirectShowSource("C:\DV\video.avi", 25)
(the above is for PAL, adjust the fps parameter for NTSC).

Remember that you don't get the audio directly using DirectShowSource; using AviSource you get the sound directly if the DV file is type-2.

bb

David caid
14th September 2004, 22:16
If you have no vfw DV codecs on your system then you have to use:


This is where I 've got confused :
moviemaker and virtualdub were able to open the DV file, so I made the (wrong) conclusion that I had a generic DV codecs (at least the DECoder part).
ok, now I understand why it didn't work.

So I'll have a search to get the canopus codecs because I want to use avisynth.

Thanks for your answers.

David