PDA

View Full Version : VirtualDubMod : AC3, MP3,MPEG2,OGG,OGM,PNG


pulco-citron
28th October 2002, 15:39
VirtualDubMod is a new project merging VirtualDubAVS&OGM (http://cyrius.bunkus.org/index.html) and VirtualDubMpg2 (http://virtualdubmpg2.sourceforge.net)

Its goal is to turn VirtualDub into a Swiss knife :)

This thread will gather the developpers' discussions.

sh0dan
29th October 2002, 08:51
Is all the developers of the mods coming together on this project, or is it a project that will have to keep up with the individual projects?

Suiryc
29th October 2002, 15:11
This project will merge the mods into one version.

Ookami
29th October 2002, 16:38
Where is the new website?

pulco-citron
29th October 2002, 16:48
I have now a version of VirtualDubMod's source code that compiles under VC++ 6.0 and that corrects a bug of mine in the MPEG2 support.



I'm looking for a fast (with MMX and the like) YV12 (or monochrome) horizontal resize filter. Does anyone know of one ?

pulco-citron
29th October 2002, 16:51
Originally posted by Ookami
Where is the new website?

The new website does not exist yet. But there should be something soon, since a project creation request has been made at SourceForge.

sh0dan
29th October 2002, 19:19
Really great to hear that the effords are being synchronized!

As some of you might know we're working on implementing YV12 support in AviSynth 2.5. We've come a long way, but we need a Virtual Dub supporting raw YV12 input.

For this to work (really well) Virtual Dub needs to be able to accept YV12 without a decompressor, and it needs to be able to "Fast recompress" YV12 data. (that would mean passing it unaltered to the compressor).

The easy task is, as you might know the "Fast recompress" passing, since it doesn't involve much interference for Vdub. But we still have the problem of making Vdub accept YV12 files. A temporary solution could be to disable preview and full recompress, if a codec cannot be found.

Does this make any sense to you, or have I just spend too many hours in front of AviSynth? :rolleyes:

Rrrough
29th October 2002, 22:45
just a one-word comment on this project :

YYYYYYYYYYYYYYYEEEEEEEEEEEEEEEEAAAAAAAAAAAAAAAAAHHHHHHHHHHHHHH !!!

sorry, couldn't hold it back... VirtualDub AVS & OGM ROCKS, and your additions will raise the value even more.
maybe you can also hack in a "even faster recompress" mode, which is supporting YV12 inputs... AviSynth 2.5 support... yummy...

keep up the great work :D

EDIT : sorry, I wasn't reading the replies to this thread, as my heart was jumping when I found it... sh0dan already explained the idea of YV12 input (AviSynth 2.5)

pulco-citron
30th October 2002, 08:32
Originally posted by sh0dan
Really great to hear that the effords are being synchronized!

As some of you might know we're working on implementing YV12 support in AviSynth 2.5. We've come a long way, but we need a Virtual Dub supporting raw YV12 input.

For this to work (really well) Virtual Dub needs to be able to accept YV12 without a decompressor, and it needs to be able to "Fast recompress" YV12 data. (that would mean passing it unaltered to the compressor).
What do you mean by "without a decompressor" ? Vdub able to open an AVI containing the YV12 fourCC without the codec being installed on the system ? ("native" support as for MJPEG ?)
I wonder if http://www.fourcc.org/fccyuy2.htm could be a solution.
VirtualDubMod already passes YV12 unaltered to the decompressor if both the source and the output report to support this format (is this what you mean ?)

The easy task is, as you might know the "Fast recompress" passing, since it doesn't involve much interference for Vdub.
3 lines of code exactly :)
But we still have the problem of making Vdub accept YV12 files. A temporary solution could be to disable preview and full recompress, if a codec cannot be found.

Does this make any sense to you, or have I just spend too many hours in front of AviSynth? :rolleyes:

sh0dan
30th October 2002, 08:47
What do you mean by "without a decompressor" ? Vdub able to open an AVI containing the YV12 fourCC without the codec being installed on the system ? ("native" support as for MJPEG ?)

Yes, this would be the "best-case-scenario" - at least from the user side of it (less codecs and other strange stuff to install).


I wonder if http://www.fourcc.org/fccyuy2.htm could be a solution.
VirtualDubMod already passes YV12 unaltered to the decompressor if both the source and the output report to support this format (is this what you mean ?)

Hadn't seen that page before - it does however seem like DivX5 does the same thing.
Yes, this would be the best solution - Vdub vanilla doesn't do this, but you have already done this? Do you have a link for a test version?

Wilbert
30th October 2002, 10:29
Hadn't seen that page before - it does however seem like DivX5 does the same thing.
Yes, this would be the best solution - Vdub vanilla doesn't do this, but you have already done this? Do you have a link for a test version?
It's the second url he gave in his first post.

However I installed his version and I still need DivX5 to open the YV12-avi's in his modified VirtualDub.

pulco-citron
30th October 2002, 11:02
Originally posted by sh0dan

Yes, this would be the "best-case-scenario" - at least from the user side of it (less codecs and other strange stuff to install).


Hadn't seen that page before - it does however seem like DivX5 does the same thing.
Yes, this would be the best solution - Vdub vanilla doesn't do this, but you have already done this? Do you have a link for a test version?

when I wrote "YV12 unaltered to the decompressor", I meant in fact YV12 unaltered to the compressor"

in fact, VirtualDubMpg2 supports this (it speeds up MPEG2 -> DivX5 considerably) : http://virtualdubmpg2.sourceforge.net .

So does VirtualDubMod.
The site is just born : http://virtualdubmod.sourceforge.net
with absolutely nothing interesting on it for the moment. I'm filling the CVS repository right now. It may take a while until all is ready...

sh0dan
30th October 2002, 11:20
[edit]
Really cool!!

Just tested it, and even though DivX sometimes crashes, YV12 to XVid is actually working!! Great!

I'll have to do some debugging to see if I pass wrong parameters to DivX, but strangely enough it seems to decode the image fine, when delivering as RGB or YUY2. Maybe I'm giving wrong BMPSize. I'll look into it.

Great work, again - hope to have a built in YV12 decoder soon :)

sh0dan
30th October 2002, 11:36
Just noticed a thing:

In void Dubber::InitSelectInputFormat() you should remember to indicate that YV12 is 12 bits per pixel!
So that // Attempt YV12.
bih.biCompression = '21VY';
bih.biBitCount = 12;
if (NegotiateFastFormat(&bih))
return;
bih.biBitCount = 16;

You should perhaps also attempt YV12 before UYVY and YUYV, but that more a matter of opinion.

Belgabor
31st October 2002, 11:26
Hi ppl,

Just to let you know, my stuff is in cvs (so far excluding toffs mod 'cause cvs was bitching at me yesterday), so we probably could make a release soon.

Cheers
Belgabor

Wilbert
31st October 2002, 11:35
That would be really cool! By that time we can use the line:
Smartripper --> dvd2avi --> VirtualDubMod
for getting Xvid/DivX with AC3/MP3 without any color conversions and without using other programs such as Besweet or Nandub. Very cool!

pulco-citron
31st October 2002, 14:45
Originally posted by sh0dan
Just noticed a thing:

In void Dubber::InitSelectInputFormat() you should remember to indicate that YV12 is 12 bits per pixel!
So that // Attempt YV12.
bih.biCompression = '21VY';
bih.biBitCount = 12;
if (NegotiateFastFormat(&bih))
return;
bih.biBitCount = 16;

You should perhaps also attempt YV12 before UYVY and YUYV, but that more a matter of opinion.


You're right with the 12 bits, I noticed it but I was too lazy to change it since it works fine for MPEG2 (I put 16 instead of 12 in the MPEG2 input too ... 2 bugs->looks like zero bug). I'll try to change it now since you caught me :)


Concerning color space preferred order, I don't know how to handle it : I think indeed that it would be better to negotiate formats with source and output with "quicker" formats first. But "quicker" often means "native", and a format that is "native" for a codec can be "supported" only (with internal colorspace conversions) by another.
However, since lots of people use vdub for MPEG-1/2/4 -> MPEG-4 conversions, putting YV12 first can't hurt. It will be done.

pulco-citron
31st October 2002, 14:49
Originally posted by Wilbert
That would be really cool! By that time we can use the line:
Smartripper --> dvd2avi --> VirtualDubMod
for getting Xvid/DivX with AC3/MP3 without any color conversions and without using other programs such as Besweet or Nandub. Very cool!

Unless you need features like luminance gain and offset, or dynamic range compression, VirtualDubMod can replace dvd2avi/vfapi.

sh0dan
31st October 2002, 19:55
For YV12 to work, I had to use the following code in Dup.cpp:


memcpy(&bih, vSrc->getImageFormat(), sizeof(BITMAPINFOHEADER));

bih.biSize = sizeof(BITMAPINFOHEADER);
bih.biPlanes = 1;
bih.biSizeImage = ((bih.biWidth+3)&(~3))*bih.biHeight;
bih.biSizeImage += bih.biSizeImage>>1;
bih.biXPelsPerMeter = 0;
bih.biYPelsPerMeter = 0;
bih.biClrUsed = 0;
bih.biClrImportant = 0;

// Attempt YV12.

bih.biCompression = '21VY';
bih.biBitCount = 12;

if (NegotiateFastFormat(&bih))
return;

// Attempt UYVY.
bih.biBitCount = 16;
bih.biCompression = 'YVYU';
bih.biSizeImage = (bih.biWidth+(bih.biWidth&1))*2*bih.biHeight;

if (NegotiateFastFormat(&bih))
return;

// Attempt YUYV.


So YV12 has to be first (which is also preferable). The image size is also different.

Belgabor
31st October 2002, 21:22
@suiryc & pulco-citron: please have a look at the devel forum at our project

Cheers
Belgabor

hakko504
1st November 2002, 10:48
Unfortunately it looks like YV12 isn't supported, at least the release notes (http://sourceforge.net/project/shownotes.php?release_id=119822) does not mention it.

bond@doom9
4th November 2002, 10:16
First of all VirtualDubMod is a great idea!!!

As VDM is going to support mp3 you are perhaps using the sources of nandub.
Are you also going to continue improving SBC where nando left (or at least add the current SBC features so that nandub isnt needed any more)?

pulco-citron
4th November 2002, 11:14
Originally posted by bond@doom9
First of all VirtualDubMod is a great idea!!!

As VDM is going to support mp3 you are perhaps using the sources of nandub.
Are you also going to continue improving SBC where nando left (or at least add the current SBC features so that nandub isnt needed any more)?

The sources of nandub were used for MP3 (and ogg, ac3...) support, indeed. However, only the modifications of nandub concerning audio were taken. There are currently no plans to include SBC (I personnally don't feel the need for it and I find that DivX or Xvid can produce very similar results while being simpler to use...).

bond@doom9
4th November 2002, 12:11
The implementation of SBC just came to my mind because of the huge amount of GKnot-(Newbie/Semi-Pro)-User, as i am one of them :D and GKnot with Nandub (DivX3) is still an excellent (and quite simple) choice of producing dvd-rips.

Belgabor
4th November 2002, 20:07
Sorry, thats very very unlikely. SBC is (imho) a dying format. Including it in VDubMod will be a major hassle and probably break compatibility with 'normal' codecs (as you remember nandub ONLY supports SBC). So from my point a definfite no, not worth the efford, sorry. We'll already have a major hassle with updating to 1.4.11 I fear.

Cheers
Belgabor

bond@doom9
5th November 2002, 02:39
no problem :)

Pasqui
5th November 2002, 21:18
According to my tests, this version does not support Avisynth 2.5 alpha and direct YV12 conversion. Do you plan to add ShOdan's hack ? (with his version I do not have any problem)
Edit: Just saw this bug was already submitted by Wilbert. Sorry :o

yawnmoth
8th November 2002, 22:01
When I load a vob with VirtualDubMod, all I see are motion vectors - I don't see any of the actual picture...
Also, there are a few problems in DVD2AVI that I wouldn't want to see carried over to this application...
for one, DVD2AVI doesn't always choose the frame rate you tell it. For example, if you're trying to encode a video at 23.976 fps, it will instead be encoded at 23.975, which leads to out of sync audio the farther into the movie you get...
Also, DVD2AVI doesn't decode MPEG Layer 2 audio - it just decodes AC-3 audio - perhapes an MPEG Layer 2 audio decoder could be added?

rc3105
8th November 2002, 22:36
mpeg mediator has taken the dvd2avi code & extened it quite nicely for transcoding to avi. no editing besides setting the start point and the ability to encode X # of frames, but still, it's usually quicker to encode the whole file (or segment) than go through the whole dvd2avi -> d2v -> vfapi steps & then encode with vdub

perhaps it would be quicker to add mpeg mediator's version of mpeg2 & layer2 / ac3 audio decoding to vdub.

www.mpeg-mediator.com

just my .02


--
Riley

*I'm working on adding transport stream compatability to mpeg-mediator

stax76
10th November 2002, 14:19
this project looks very interesting, I would like to replace VirtualDub, Nandub and OggMux with your tool in my project DVX, is OGM with language and subtitles supported by VirtualDubMod scripting?

Thanks,
Dolemite

Suiryc
10th November 2002, 18:39
There are all necessary function for the scripting language (Sylia).
As a consequence the "Add operation to job list and defer processing" works :)

If you need details about functions and how to use them just PM me (there is no doc about it in VirtualDubMod).

drebel
19th November 2002, 14:03
I thought that after the release of VirtualDubMod and the downfall of SBC, good old nandub would be obsolete .I guessed WRONG !

VDubMod seems to lack the " go to last keyframe..." function which,in my humble oninion ,is still the best way to cut a movie to a certain filesize.

Is there any possibility of adding this necessary function to the next release?

...just a thought
regards,
george

Wilbert
19th November 2002, 15:29
I also appreciate if you could add this feature to the next version ...

Suiryc
19th November 2002, 17:29
@drebel and Wilbert :
This feature has already been asked in fact (here (http://forum.doom9.org/showthread.php?s=&threadid=32909), don't know why Selur posted it in this thread BTW ;)).
It has been implemented and will be available in the next release :)

Next time could you also use the "Tracker -> feature request" on the SourceForge project page so that we can keep a trace of what users want :)

Thanks :)

Wilbert
20th November 2002, 10:25
This feature has already been asked in fact (here, don't know why Selur posted it in this thread BTW ).
It has been implemented and will be available in the next release

Ok, thanks!

drebel
21st November 2002, 00:35
...twice!

R3g
24th November 2002, 18:04
hi everybody !

I'm interested in the way of muxing VBR mp3 in AVI. I've been browsing VirtualDubMod and AVIMux (which comment are in german) source code for a couple of hours, but I still have some difficulties to figure out how it works.
Could anyone give me some hints on how to fond and understand the interesting part, and perhaps explain in a few words the idea of that thing ?

Belgabor
25th November 2002, 22:14
Originally posted by R3g
hi everybody !

I'm interested in the way of muxing VBR mp3 in AVI. I've been browsing VirtualDubMod and AVIMux (which comment are in german) source code for a couple of hours, but I still have some difficulties to figure out how it works.
Could anyone give me some hints on how to fond and understand the interesting part, and perhaps explain in a few words the idea of that thing ?

New VDubMod Version should support it, but DON'T USE IT! It doesnt work properly and probably never will. If you want vbr, use ogm as container.

bond
26th November 2002, 12:03
As Real went opensource (http://www.helixcommunity.org/) with its Realvideo9-Helix-thing ("everything but the codec") and RV9 is a pretty good codec for 1cd rips, would it be possible to implement the use of RV9 content into VDMod and/or to save rv9 streams in alternative container formats such as ogg/ogm (and perhaps also mcf in the future or even mp4)?

This would be a real big extension for VDMod, perhaps you can use the source code of real's rmeditor (source will be released on december 9)!

Sorry for the small doublepost but since i tested rv9 i am really shocked about the good results with this codec :D

EDIT: What about supporting also WindowsMedia9-files? Ok i see i am asking to much for now, i will stop that :D

Wilbert
26th November 2002, 17:47
I also would like to see that VDubMod can open uncompressed multichannel wav (provided by AviSynth 2.5 for example) and that is can be compressed to AC3 (or less important MP3).

Belgabor
29th November 2002, 11:27
/me points to signature :p

The People's Elbow
30th November 2002, 12:58
Hi folks,
after a little break in relation to a/v encoding and this stuff I was back last week and discovered VDubMod - very cool tool! ;)
Would it be possible to include direct .tpr support into it (or to rip-off the manual ivtc-interface of tmpeg and put it into vdubmod ;) ) ?
Anyway... huge compliment for your recent work, this programm really rocks!

greetz,
Elbow!