VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss...

31
VirtualDubMod is a project that was born when suddenly a lot of modifications to the original VirtualDub by Avery Lee sprung up, mainly on the Doom9 forums. Some people got tired of needing several diffrent modified VirtualDub executables, so the idea arose to put them all together into a single app, VirtualDubMod. The founders were: VirtualDubOGM - Cyrius VirtualDubMPeg2 - Pulco-Citron VirtualDubAVS - Belgabor

Transcript of VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss...

Page 1: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

VirtualDubModisaprojectthatwasbornwhensuddenlyalotofmodificationstotheoriginalVirtualDubbyAveryLeesprungup,mainlyontheDoom9forums.SomepeoplegottiredofneedingseveraldiffrentmodifiedVirtualDubexecutables,sotheideaarosetoputthemalltogetherintoasingleapp,VirtualDubMod.

Thefounderswere:

VirtualDubOGM-CyriusVirtualDubMPeg2-Pulco-CitronVirtualDubAVS-Belgabor

Page 2: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

ExtendedfeaturesinVirtualDubMod1.5.x

Nb:VirtualDubModnowhasabasicUnicodesupport.HoweverthissupportisonlyavailableinWindowsversionsthathandleitnatively(2k/XPhandleit).Win9xdoesn'thandleUnicodenativelyandsoyouwon'thaveUnicodesupportinVirtualDubModwiththisOS.

ThisshortdocumentationgiveyousomeinformationonthefollowingsubjectsinVirtualDubMod1.5.x:

PreferencesAVIInformationImageformatsStreamsmenuMultiplestreamshandlingCommentsandchaptershandlingPreviewingandSavingBatchmodeMiscellanea

Preferences

Sinceversion1.5.4.xVirtualDubModalsousesanextendedtreelistthankstowhichyoucanaccessallitspreferences.Dependingonwhichkindofpreferenceitis,clickingonaniteminthetreewillmakeappearacomboboxoraneditbox(optionallyanicontopopupafileselector).Forenabling/disablingpreferences(checkbox/radiobutton)clickonthecheckboxorradiobutton.

Thedefaultvideomode(Directstreamcopy,Fastrecompress,Normalrecompress,Fullprocessingmode)inwhichVirtualDubModstartscanbechangedintheMainpreferences.

Page 3: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

TheDisplaypreferencesletyouchoosetoenable/disablebydefaulttheDisplayinputvideoandDisplayoutputvideooftheOptionsmenu.Youcanaskforthewindowtobeautomaticallyresized(accordingtothesizeoftheopenedvideo)andcentered.Youcanalsospecifyaspecificlanguagedlltouse(allorpartofthestrings/messagesintheprogramwillbeaffected).

TwonewAVIoptionshavebeenaddedintheAVIPreferences.ThefirstoneletyouspecifythedefaultbehaviourofVirtualDubModconcerningMP3VBRalaNandubinAVIfiles.YoucaneitherforceVirtualDubModtohandlethestreamthesamewayNandubdoes,orlettheprogramfixtheVBRstreamasVirtualDubdoes.Notethatyouwillbeaskedtoconfirmthisbehaviour(ortousetheotherone)ifaVBRstreamisdetectedwhenopeninganAVIfile(justclickYesifyouwanttousethebehaviouryouspecifiedinthepreferences).ThesecondoneconcernsthewaytohandleAC3andDTSsourceswhensavingtoAVI.IthasbeenreportedmanytimesthatNandub(andVirtualDub)cutanAC3trackanywhere(andgenerallyinthemiddleofanaudioframe)wheneditinganAVIfile.ThissometimesleadtotroubleswhenusingtheAC3trackwithothertools.YoucanaskVirtualDubModtowritethesizeoftheaudioframes(onlypossiblewithCBRstreams)intheAVIheaders.Thespecstheoricallyallowitbutactuallyprogramsgenerallyfixthisvalueto1(meaningthattheprogramcancutthestreamoneverybyteifitwants).Writingthesizeoftheframesintheheadershouldforceothereditingtoolstodealwithfullaudioframes(andsoitshouldn'tcutanywhere).UsethisfeatureATYOUROWNRISKS!!

AnewAudiosectionhavebeenaddedinthePreferences.Thistabletyouaccess5optionsinVirtualDubMod:

Page 4: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Defaultpreload:defaultpreloadvalue(inms)touseforaudiostreamsDisablepreloadfornonAVIoutput:letyoudisablepreloadwhennotsavingtoAVIPrissrocks!:letyouusePriss(VirtualDubinternalMpegaudiodecoder)insteadofanACMonewhendecodingMP3audio.Theremaybesomebugs(inthewayitisimplemented,notinPriss;))butitseemstoworkbetterthanACMonMP3VBR:)Groupframes:minimumnumberofaudioframestopackinablock.0meanstoprocessoneframeatatime.OnlyeffectivewhennotsavingtoAVI,notprocessingMP3VBRalaNandub,orwhenusingtheFramemode(seebefore)Keepcorrupteddata:tellsVirtualDubModwhattodowithcorrupteddatafoundinMP3/AC3/DTSfiles.Whenkepttheprogramwilltrytokeepthestreaminsynchbyprocessingthecorrupteddataasrealdata(computingtheequivalentnumberofsamplescorrespondingtothesizeofthecorrupteddata)

AndaMatroskasectionhasalsobeenaddedforthosewhowanttotestdifferentsettings.

AVIInformation

ThefieldPreloadskewintheAVIinformationwindowgiveyouthenumberofblocksandanestimatednumberofsamplesusedforpreloading.Twofieldshavebeenaddedinthiswindow:

FourCCcode:giveyoutheFourCCcodeofthecompressionformatforthevideo.NotethattheDecompressorfielddoesn'tnecessarilygiveyouthecodecinwhichthevideohasbeencompressed(e.g.DivX3/4videoisdecompressedbytheDivX5decoder).Thesecondlinegiveyouthename(ifknown)oftheformatcorrespondingtothisFourCCcode.Audiotag:giveyouthecompressionformat(thewFormatTagvalue)oftheaudiostream.TellsyouifanACMdecoderisavailableforthisformat(thefieldCompressiongiveyouthenameoftheACMcodecinthiscase).Thesecondlinegiveyouthename(ifknown)oftheformatcorrespondingtothistag.

Page 5: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

NotethatthenameoftheformatisretrievedfromtheCodecs.inifile(thatshouldbeinyourVirtualDubModdirectory).ThisfilecomesfromTheCoreMediaPlayer.Wethankitsdeveloppersforthisgreatplayer,havingmadethisfileandlettingususeit:).

Imageformats

VirtualDubModnowusetheCoronalibrary.ThislibraryhandleBMP,TARGA,PNG,JPEG,GIFandPCXimageformatsoninput,andPNGonoutput.

Thismeansthatyoucanopenimagesequencesinoneofthoseformats(BMPandTARGAarestillhandledbyVirtualDubinternalroutinesthough),andsavetoaBMP(usingVirtualDubBMProutines),TARGA(usingVirtualDubTARGAroutines)orPNG(usingCoronaPNGroutines)sequenceofimages.

ThedefaultselectedformatisTARGA.WhenusingmultipletimesthisfeatureduringasameVirtualDubModsessionthelastusedformatiskeptinmemoryandselectedonnextcalls.

Page 6: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

AnewfeaturehasbeenaddedintheVideomenu.ThisfeatureletyousavethecurrentinputoroutputimagetoaBMP(usingVirtualDubBMProutines),TARGA(usingVirtualDubTARGAroutines)orPNG(usingCoronaPNGroutines)file.ThisfeatureisavailablethankstothenewSnapshotsourceframeandSnapshotoutputframeitems.

ThedefaultselectedformatisTARGA.WhenusingmultipletimesthisfeatureduringasameVirtualDubModsessionthelastusedformatiskeptinmemoryandselectedonnextcalls.ThisdefaultselectedformatissharedwiththeSaveimagesequencefeature(i.e.ifyousavedanimageinPNGformatthedefaultformatselectedwhensavingasequenceofimageswillbePNG,andvice-versa).

Streamsmenu

Startingfromversion1.5.xVirtualDubModallowtheuseofmultiplestreamsinitsstandarduse(e.g.whenwritingAVIfiles).

Page 7: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

InthispurposetheAudiomenuhasbeenreplacedbyStreamsinthemainmenu.ThisnewmenuletyouaccessfeaturesfortheVideostreamandthelistofcurrentlyavailablestreams(Streamlist).TheReportitemletyouaccessawindowwhereareportoncurrentlyopenedfilesandavailablestreamsappears.Thisreportsgiveyougeneralandspecificinformationforeachopenedfileorstream(caracteristics,errors,...),suchasthisone:

P.S.:ifyourreportlookslikethisonethenyouarereallyunlucky:p

Multiplestreamshandling

YoucanmanagetheavailablestreamsthankstoStreams->Streamlist.The

Page 8: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

windowthatappearslistallstreamspresentlyopenedin

VirtualDubMod(exceptthevideostreamofcourse).

Picturesandcolorsgiveyousomemoreinformationonastream.Thecurrentlyselectedstreamhasagrey(insteadofwhite)backgoundinthelist.Ifastreamisdisabled(i.e.youdon'twantitwhenmuxing)somehatchingsaredrawnonit.Youcandisableastreambydouble-clickingonit.

meansthestreamcomesfromthecurrentlyopenedfileinVirtualDubMod.Anaudiostreamswith isselectedforpreviewingwhileonewith isn't(justclickonthisimagetochangethestateofanaudiostreamregardingpreview).Notethatonlyoneaudiostreamcanbeselectedforpreviewing(youcanalsoselectnone),andthatyoucanselectadisabledstream.Sinceversion1.5.xVirtualDubModincludestheliba52library.Thankstothislibraryyoushouldbeabletodecompress(i.e.useinprevieworinFullprocessingmode)anAC3track(thestreamisconvertedtoDolbysurroundcompatiblestereobythelibrary).NotethatanoptionalsoallowyoutousePriss(internalMpegaudiodecoder)insteadofanACMonetodecodeanMP3track(seebefore).

YoucanchangetheorderofthestreamsbyusingMoveuporMovedown.You

Page 9: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

canaddexternalsourceswiththeAddbutton,orremoveastreamfromthelistwiththeDeletebutton(notethatstreamscomingfromtheopenedfilecan'tberemovedfromthelist,toselect/deselectsuchastreamyouneedtodisableitthankstothe(Un)Selectbutton-theDeletebuttonbecomeSelectorUnselectforthiskindofstream-orbydouble-clickingonthecorrespondantiteminthelist).Currentlysupportedexternalsourcesare:

WAVfilesMP3filesAC3filesOggVorbisfilesDTSfilesSRTfiles(ASCII/Unicode)

NotethatforMP3filestheprogramlookifthereisaRIFFheaderatthebeginning(i.e.itisaWAVfilebutyouforcedtheprogramtoopenitasMP3)ortags(atthebeginningorendofthefile).Thosedata(RIFFheaderandtags)aren'tmuxedintheoutputfile.ForAC3andDTSfilestheprogramalsocheckifthereisaRIFFheaderatthebeginningofthefile.Inanycaseyouwillfindallthoseinformation(wasthereaRIFFheader,tags,andordataseenascorruptedinthefile)intheReportwindow.

AsyoucanseeUnicodefilenamesarealsosupported(inWindowsversionthatsupportit).Whenopeninganexternalsourceadialogboxshowingprogressoftheprocesswillappear.Ifthefilewasn'tvaliditwon'tbeaddedinthestreamlist.YoucanverifyallwentwellthankstotheDescripionorLengthinformationgiveninthestreamlist(ifitisfardifferentfromwhatyouexpectedmaybesomethingwentwrong).Theexternalsourcesareparsedandallnecessaryinformationarestoredinmemoryforfasterdataaccessafterwards.Theamountofmemoryuseddependsofthetypeoffileopened,anditscontent.SomeimprovementshavebeenmadesincethepreviousversionofVirtualDubMod;).Forstandard(i.e.CBR)AC3/DTSfilesitshouldbeafewhundredbytes,around1MBforanMP3source(1hours)and2MBforanOggVorbisfilewithsameduration.Subtitlesarecompletlystoredinmemorybutthisdoesn'trepresentanexcessiveamount

Page 10: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

ofmemory:pToaccessaudiostreamsfeaturesyoucanright-clickonthecorrespondantiteminthelist.TheAudiomenuwillthenpopup.Notethatthemode(i.e.None,AVIaudio,WAVaudio)havebeenremovedfromthemenusinceuselessnow.

YoucandemuxastreamwithorwithoutaWAVheaderbyselectingSaveWAVorDemux.

OggVorbisstreamswillbeautomaticallydemuxedtoanOggfile.Textstreamswillbeautomaticallydemuxedtoasubtitle(SRT)file.Youwillhavetochooseinwhichformat(ASCII,UTF-8orUnicode)youwanttosavethesubtitles.

Thedefaultselectedformatdependsontheformatofthesubtitlesyouwanttosave.IfsubtitlesareASCIIthenthedefaultproposedformatisASCII,otherwiseitisUnicode.

Commentsandchaptershandling

YoucanaccessspecificcommentsorchaptersforastreamthankstoCommentsandChapters.ThevideocommentsandchaptersareaccessiblethankstoVideocommentsandVideochaptersintheStreamsmenu.Generallyyouputyourchaptersinthevideostream.Notethatonlythecommentsandchaptersspecifiedinthevideostreamaretakenintoaccount

Page 11: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

whensavingtoafilethatonlyhandlecommentsorchaptersatthefilelevel(andnotatthestreamlevel).ThisisforexamplethecaseforAVIfiles(whichonlyhandlecomments).Andcommentsorchapterscomingfromsuchfileswillonlybeaddedinthevideostream.

Commentshave3properties:Type:definesthetypeofcomment(seebelow)Tag:thenameofthecomment(onlymattersforGenericcomments)Value:thevalueofthecomment

Therearevarioustypeofcomments.Typesareaconvenientwaytousethesamecommentforanyoutputformat(theoutputfunctionsautomaticallyformatacommentaccordingtoitstype).Notethatsomeoutputformatsdoesn'thandlecomments,oronlysometypes(notall).HereisthelistofcurrentlydefinedcommentsunderVirtualDubMod1.5.x:

Type Description HandledforAVI

Handledfor

OGM

Handledfor

MKVCommentspecifictoacontainer.Thiskindofcommentcanonlycomefromafile(youcan't

Page 12: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Specificinsertoneyourself)andwon'tbeincludedintheoutputfileunlessbothformats(inputandoutput)arethesameoryouedititstypeyourself.

* * No

Generic

Genericcomment(usethistypeofcommentandfilltheTagfieldifnoneofthetypeusedsuitsyou).

Yes Yes Yes

Software

Softwareusedtomakethefile.Notethatyoucan'teditthiscomment,andthattheoriginalvaluewon'tbekeptwhengeneratinganewfile.

Yes No Yes

Title Titleoftheclip/track(TitlepropertyinWMPlayer). Yes Yes Yes

DescriptionSubjectoftheclip/track(DescriptionpropertyinWMPlayer,exceptforAVIfile).

Yes Yes Yes

Language LanguagepropertyinWMPlayer. No Yes Yes

Author

Theartistgenerallyconsideredresponsibleforthework.Inpopularmusicthisisusuallytheperformingbandorsinger.Forclassicalmusicitwouldbethecomposer.Foranaudiobookitwouldbetheauthoroftheoriginaltext.(AuthorpropertyinWMPLayer)

Yes Yes Yes

Copyright Copyrightattribution(CopyrightpropertyinWMPlayer). Yes Yes Yes

License

Licenseinformation,eg,'AllRightsReserved','AnyUsePermitted',aURLtoalicense,etc.

No Yes Yes

Page 13: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

CommissionerPersonororganisationthatcommissionedthesubjectofthefile.

Yes No Yes

Comment Commentontheclip/track. Yes No YesGenre Yes Yes Yes

Keywords Keywordsreferingtothefileoritssubject. Yes No Yes

Date Creationdate. No Yes No

Version

Theversionfieldmaybeusedtodifferentiatemultipleversionsofthesametracktitleinasinglecollection(e.g.remixinfo).

No Yes No

Performer

Theartist(s)whoperformedthework.Inclassicalmusicthiswouldbetheconductor,orchestra,soloists.Inanaudiobookitwouldbetheactorwhodidthereading.InpopularmusicthisistypicallythesameastheAuthorandisomitted.

No Yes Yes

Album Thecollectionnametowhichthistrackbelongs. No Yes Yes

TrackNumber

Thetracknumberofthispieceifpartofaspecificlargercollectionoralbum.

No Yes No

OrganisationNameoftheorganizationproducingthetrack(i.e.the'recordlabel').

Yes Yes No

Location Locationwheretrackwasrecorded. Yes Yes No

Contact

Contactinformationforthecreatorsordistributorsofthetrack.ThiscouldbeaURL,anemailaddress,thephysicaladdressoftheproducinglabel.

No Yes No

Page 14: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

ISRC ISRCnumberforthetrack. No Yes YesURL No No No

(Track)Name Nameofthetrack(asdescribedinAVIorMatroskaspecs). Yes No Yes

AsyoucouldseeUnicodecommentsaresupportedheretoo(exceptforWin9xassaidatthebeginning).

Nb:pleasenotethatwhensavingtoAVIcommentsaretranslatedtotheANSIcodepage(inmytestsIwasn'tabletoproperlyincludeUnicodecommentsinanAVIfile).

Whenselecting(ormodifying)aLanguagecommentanothercombo-boxcontainingalistofpredefinedlanguageswillappear.ThislistlanguagesdefinedintheISO-639-1standard.YoucanaccessthefulllistoflanguagesdefinedintheISO-639-2standardbycheckingtheFulllanguagelistbox.Chaptersarenowhandledinanotherwindow.Timeisstoredasfractioninthecode,butintheGUItheformatusedisHH:MM:SS.mmm(HH=Hour;MM:Minute;SS:Second;mmm:Millisecond).Ifthetimeyouenteredinthefielddoesn'tfollowthisformatyouwillbewarnedwhentryingtoAddorEditachapterinformation.

YoucanuseUnicodechapternamestoo(unlessunderWin9x).

Youcanalsoimportachapterlist(.txtfile)thankstotheImportbutton.Knownfilesformatsare:

SmartRipperchapterXtractor(selectOGGformat)DVDDecrypter(selectOGGformat)

Page 15: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

PreviewingandSaving

AfewthingshavebeenchangedintheFilemenu.

SinceyoucannowappendOGMsegments,AppendAVIsegmenthasbeenrenamedAppendsegment.Whenusingthisfeaturetheprogramwillselectthecorrectextensionoffilestoappend(i.e.AVIfileswhenyouhaveopenedanAVIfile,andOGMfileswhenyouhaveopenedanOGMfile).Commentsandchaptersshouldbeappendedcorrectlytoo.Ifcommentsareequalsduplicatedonesareremoved.Ifchaptersseemsequals(samename,andtimedifferencebetweenthemislessthan2ms)thentheduplicatedonesareremoved.

AnewPreviewVBRitemhasbeenadded.Usingthispreviewmode(insteadofthenormalPreview)shouldgivebetterresultswhentheaudiostreamyou

Page 16: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

selectedforpreviewisVBR(especiallywhenyoustartpreviewinginthemiddleoftheclipandnotatthebeginning).

ThepreviousSaveasAVI,SaveoldformatAVI,SavesegmentedAVIandSaveasOGMitemshavebeenreplacedbyauniqueSaveaswindow.

ThenewSaveasitemletyouaccessawindowyoucanusetosaveinthedesiredformat,withthedesiredoptions.

ThiswindowmergetheoptionssothatyoucansaveintheoldAVIformat(AVI1.0,VfW1.1e;thedefaultformatbeingAVI2.0,OpenDML1.02).

Youcanselectthedesiredoutputformat(i.e.AVI,OGMorMKVfile).TheformatusedinthelastcallofSaveasisstoredintheWindowsregistryandautomaticallyselectedeachtimeyouaccessthewindow.

Youcanalsoasktosegmenttheoutputfile(accordingtoasizeornumberofframeslimit).

NotethatsuringasessionofVirtualDubModtheprogramremembersifyouusedtheJoblisttoqueuethepreviousjobornot.i.e.ifyouputajobinthelist,nexttimeyoucallSaveasthenthecorrespondingcheckboxwillbecheckedbydefault.

Page 17: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Thiswindowalsoremindyouofthecurrentvideomode,andtheselectedcodec(whenreencoding).Youcanchangethemodeand/orchangethecodectouseforreencoding.TheMaintabintheDubbingstatuswindowremainsunchanged:itstillshowyoustatusaboutthevideostreamandanaudiostream.Theaudiosectionactuallygiveyouinformationonthefirststreambeingmuxedintheoutputfile(i.e.itmayinfactbeatextstream).TheEstimatedtotaltimeisalsocomputedonlybytakingintoaccountthevideoandaudiostatus.However,evenifnoinformationisshownaboutotherstreams(ifany)theProjectedfilesizeandtheProgressinformationtakeintoaccountallthestreamsbeingmuxed.

FormoreinformationonthedubbingprocessanewStreamstabhavebeenadded.Thistabstillgiveyouinformationaboutthevideostream,butalsolistinformationaboutalltheotherstreams(intheorderinwhichtheyaremuxedinthefile).Thenumbergivenforeachstreamisnotanindexbuttheserialgiventothestreamintheoutputfile.Thismeansthateachnumberisuniqueforadubbingprocess,but(evenifitismostlikelytobelikethis)theyarenotnecessarily1,2,3,...(e.g.having7803,204,65214doesn'talwaysmeanthereisabug:p)HerebothProjectedfilesizeandEstimatedtotaltimetakeintoaccountallthestreams.Asyoucanseeascrollbarappearsinthetabwhenthenumberofstreamsmakeitnecessary(i.e.whenyouhavemorethan1streams-notincludingvideo-tomux).

Alltheexternalfilesyouaddedasinput(andallthevideocommentsandchapters)areremovedfromthelistwhenclosingthecurrentlyopenedvideofile.Thishappenswhenyouopenanewvideofile,whenyouselectFile->Closevideofileinthemenu,attheendofajob,and(ofcourse)whenleavingVirtualDubMod.

Page 18: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Sodon'topenthoseexternalfilesbeforeopeningyourvideofilebecauseinthiscaseyouwillhavetodoitagain:p

Batchmode

LastbutnotleasttheJobfilewillsavealltheinformationconcerningusedstreamsandtheiroptions(compression,...),commentsandchapters.SoyoucanstillusetheDon'trunthisjobnow;addittojobcontrolsoIcanrunitinbatchmodefeature.NotethataSkipbuttonhasbeenaddedintheJoblistwindow.OnthecontrarytotheAbortbutton(whichstopjobsprocessing)itabortthecurrentjobandgothenextone.

Alsoyourcurrentconfiguration(inputstreamsselectedandtheirassociatedcommentsandchapters)shouldbesavedwhenusingSaveprocessingsettings,andcanbereloadedwhenusingLoadprocessingsettings.

Miscellanea

TheGotolastkeyframefeature(comingfromNandub)hasbeenaddedintheEditmenu.Thisfeatureletyoujumptothenearestpreviouskeyframeprecedingacertainposition(expressedinmegabytes)inthefile.

Youcanseethepositioninfileofthecurrentlyshownframeatthebottomofthewindow.Thefilepositiononlytakeintoaccountthecurrentlyopenedvideofile,andsoisonlyworthywhenyouplantosave(inDirectstreamcopy

Page 19: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

mode)tothesamefileformat(AVIandOGMdon'thavesimilaroverheads).

Page 20: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

ScriptingwithVirtualDubMod

LikeVirtualDub,VirtualDubModusesSylia(developpedbyAveryLeetoo).Somespecificfunctionshavebeenaddedthough.YouwillfindbelowalistofthefunctionsyoucanuseinascriptwithVirtualDubMod.Thislistalsogiveyouthetypeofparametersyoucanusewiththefunction.Thereare2possibletypes:

:signedlonginteger(32bits)whichvaluecanbefrom-2147483648to+2147483647:astandardstring

Integerscanalsobeusedasbooleanvalues:0meansfalseandanyothervaluemeanstrue.Inthefunctionsdescribedbelowthevaluesreturned(whenany)areintegervalues.Youwillseethatsomeparametersusethefirstletteroftheirnametodescribetheirtype:

b:booleanvaluef:thisvalueisaflag(generallyaboolean)inVirtualDubsettings(e.g.'Preferences'settings)n/l:generallyalonginteger(sometimesitisusedasDWORD,i.e.unsignedlonginteger)w:generallymeansthevalueisaWORD(unsignedinteger)

Sinceversion1.5.5VirtualDubsupportUnicodefilenames.ThusfilenamesusedinthescriptfilesareactuallyconvertedtoUTF-8,andthenprocessedbythestrCifyfunctiontomakethemfitinthescriptasastring.Hereisthelistofdefinedfunctions:

Generalfunctions(VirtualDub.):Subsetfunctions(VirtualDub.subset.):Videofunctions(VirtualDub.video.):Videofiltersfunctions(VirtualDub.video.filters.):Videofiltersfunctions(VirtualDub.video.filters.instance[n].):Stream(mainlyaudio,sometimestext)functions(VirtualDub.stream[n].):

Page 21: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Audiofiltersfunctions(VirtualDub.stream[n].filters):Audiofiltersfunctions(VirtualDub.stream[n].filters.instance[n]):

ForcompatibilityreasonssomefunctionsthataresomehowdeprecatedinVirtualDubMod1.5.xarestillkept.ForthesamereasonsnotethatVirtualDub.audiowillbeinterpretedasVirtualDub.stream[0]forkeepingcompatibilitywithVirtualDubscripts:AllthisshouldmakeVirtualDubscriptsstillbeinterpretedcorrectlyinVirtualDubMod1.5.x.

Hereisalistofpossiblecommenttypes(seethedocumentationforadescriptionofthosetypes):

Type ValueSpecific 0x00000000Generic 0x00000001Software 0x00000002Title 0x00000003

Description 0x00000004Author 0x00000005

Copyright 0x00000006License 0x00000007

Commissioned 0x00000008Comment 0x00000009Genre 0x0000000A

Keywords 0x0000000BDate 0x0000000C

Version 0x0000000DPerformer 0x0000000EAlbum 0x0000000F

TrackNumber 0x00000010Organisation 0x00000011Location 0x00000012

Page 22: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Contact 0x00000013ISRC 0x00000014URL 0x00000015

(Track)Name 0x00000016Language 0x00010000

Notethatthevalue0x00010000meansauser-definedlanguage.LanguagesdefinedintheISO-639-1&2standardsusevaluesbeyond0x00010000...

Hereisalistofpossibleinputtypes:Type ValueWAV 0x0201MP3 0x0202AC3 0x0203

OggVorbis 0x0204DTS 0x0205SRT 0x0301

Hereisthelistoffunctionsthathavebeenremoved:

Page 23: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

HereisalistofcommandlineoptionsyoucanusewhenlaunchingVirtualDubMod.

FirstofalloptionscomingfromVirtualDub:

Option Comment/s"ScriptFile.vcf" Executethespecifiedscriptfile.

/c Clearthejoblist./p"srcfile","dstfile" Addfilebatchprocesstojoblist./b"srcdir","dstdir" Adddirectorybatchprocesstojoblist.

/r Runthejoblist./x Exitwhenjobscomplete./h Disablethecrashhandler.

/w

Settheglobalg_fWineflagtotrue,whichmakesomedisplayfunctionbehavedifferently.MaybefixsomeissueswhenrunningtheprogramunderWine...

/fsck MakeVirtualDubcrash(totestthecrashhandler).

Notethatwhenspecifyingfileordirectoriestoprocesstherearenospacesbetweentheswitchandthenamespecifiedbetweenquotes.

NowoptionsaddedinVirtualDubMod:

Option Comment

/log

Generatesthevdenc.loglogfilewhenrecompressingvideo.Eachlinegiveinformationaboutaframe(firstnumbergivesthekindofframe-1forkeyframe,0forothers-,thesecondnumbergivethesizeofthecompressedframe.

/log"LogFile.log" Withthisoneyoucanspecifywherewillbewrittenthelogfile.

/nowrite ThisonepreventsVirtualDubModfromactuallywritingthevideodataintheoutputfile.

Page 24: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

thelogandnowriteoptionshavebeenproposedandaddedbyjonny,authorofDivX5Enc.

Page 25: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

VirtualDubModFAQ

WhatdoIneedtorunVirtualDubMod?ReadthisifVirtualDubModdoesn'trunforsomereason!GetthelatestreleaseandunpackitsomewhereonyourHD.GetthelatestDllpackandunpackitinthesamedirectory.Ifyoudon'thavealltheVirtualDubDlls(sylia.dll,vdrslink.dll,etc.)getthem(eithercomingfromtheofficialVirtualDub,orgogetthelatestspecialDllpackwiththosefilesfromSourceForge).

IfyouwantAviSynthsyntaxcoloringyoualsoneedAviSynthLexer.lexer.Syntaxcoloringforcommandsfromexternalplug-insworkssinceAviSynth2.5.2.

Therewillbealsosometranslationpacksavailable.

Ifoundabug/Iwanttoproposethisfeature.WhatshouldIdo?

1. AllbugreportsandfeaturerequestsgototheTrackersonourprojectpageonSourceForge.Youdon'tneedtoregistertheretobeabletoreport,butdoingsohasabigadvantage.Wheneversomebodycommentsonyourrequest,youwillgetanotificationemail,soyouwillasapknowwhensomethingisup.

2. Makesureyourrequesthasn'tbeenreportedbefore!We(thedevelopers)closetheitemsthatareresolved,somakesureyouselect"All"inthestatusboxontherespectivetracker(normallyonlytheopenitemsareshown).PleasetakealsothetimetolookatthecurrentChanglog.YoucanfindthisviatheSFCVSbrowser(CVS->BrowseCVSRepository->VirtualDubMod15->VirtualDub->mod->res->ChangesMod.txt(clickontheversionnumberrightofthefilename))

3. Thestatusofallbugsregarding1.4.xhasbeenchangedto'Pending'afterthereleaseof1.5.x.Thiswasdonetogetridofstuffthatdoenstapplyanymoreduetothemajorchanges.Ifyoufindyourbugtostillexist,pleasechangeitsstatusbacktoopeninsteadofsubmittingitanew.

Ofcourseyoucanalsopostyourstuffintheforumfordiscussion,butalwaysaddittotherespectivetracker,otherwisebookkeepingishellforusanditemsmightslipout.Weallareonlyhumans,sowemightoverlookimportantstuffif

Page 26: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

it'snotcollectedatacentralpoint.

Wherehastheaudiomenugoneto?Rightmousebuttoninthestreamlist.

HowdoIuse'OpenviaAviSynth'?ThisallowsyoutoopenanyAVISynthcompatiblevideofilebyautomaticallygeneratingasuitablescriptbyaselectabletemplate.Thesetemplatesgointothe'templates'directoryinyourVirtualDubdirectory.TemplatesyntaxisthesameasforAVISynthesizer(Iincludedreadme_AVISynthesizer.txtbecauseasofthiswritingtheAVISynthesizerhomepageisnotavailable).Youcanchoosethedefaulttemplateshownintheopendialogbystartingthetemplatedescriptionwith"Default"(notethatthetemplatefilenamehasnothingtodowiththis).Thisfunctionhasnointelligencewhatsoever!You'reresponsibletochoosetherighttemplateforthefile(egaSegmentedAVISourcetemplateformulti-segmentavisorgivingtherightfpstoDirectShowSource)ForthistoworkflawlesslyyouneedAVISynth2.05andacorrectlysetplugindirectory.(Createaregistrykeycalled"PluginDir"inHKEY_LOCAL_MACHINE\Software\Avisynth\)Aworkaroundifyoudon'twanttodothisisaddingtheneededLoadPluginlinesintothetemplates.

Whyisusingvbrmp3inavisabadidea?WediscussedthisissueatlengthinircandCyrius(suiryc)gaveaprettygoodexplanation:

[21:33]<Belgabor|Home>cyrius,whatdidyourexperimetstell?

[21:33]<Suiryc>Belgabor|Home:IthinkIknowknowwhyVBRisnotgood,andalsowhyNando'shackworks(somehow)

[21:33]<Suiryc>s/know/now

[21:33]<Belgabor|Home>ok,tellme

[21:33]<Suiryc>:)

[21:34]<Suiryc>firstofallthereare2'headers'intheAVI(audio)stream

[21:34]<Belgabor|Home>Ihavethefeelingineedtohammerthatdownsomethroatsoon:p

[21:34]<ChristianHJW>lol

[21:34]<Suiryc>firstoneisageneralone(thesamestrutureisusedforeachtrack)

[21:35]<Suiryc>AVISTREAMINFO

[21:35]<Suiryc>(IIRC...thereshoulduseshorternames...)

[21:35]<Belgabor|Home>lol

[21:37]<spyder482>ChristianHJW:Iwon'tbemovingforafewmonthsstillthough

[21:37]<Suiryc>thisonetellhowmanyframesthereareinthestream

[21:37]<Suiryc>andwhatistherateoftheframes

[21:37]<Suiryc>thankstodwRate&dwScalefields

[21:37]<Belgabor|Home>gotthat

Page 27: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

[21:38]<Suiryc>italsocontainsafieldsayingthesizeof1frame

[21:38]<Suiryc>ifVBR,thenitissetto0,otherwiseitissettothecorrectvalue

[21:38]<Belgabor|Home>dwSampleSize

[21:39]<Suiryc>yep

[21:39]<Suiryc>thenthereisaheaderspecifictotheaudiostream(basedonWAVEFORMATEX)

[21:39]<Suiryc>thisonetellthesamplerate(44100,48000,...)

[21:39]<Suiryc>thebyterate

[21:39]<Suiryc>theformat(wFormatTag)

[21:40]<Suiryc>andespeciallycontainsafieldnamesnBlockAlign

[21:40]<Suiryc>nBlockAligntellhowmanybytesanaudioframecontains

[21:40]<Suiryc>_BUT_

[21:40]<Belgabor|Home>Andthatmusntbe0

[21:40]<Suiryc>cannotbesetto0

[21:40]<spyder482>somuchworkforAVI...

[21:40]<Suiryc>:)

[21:40]<Belgabor|Home>ok,ithinkigetthepicture

[21:40]<Suiryc>oksolet'scontinue

[21:41]<Belgabor|Home>ok

[21:41]<ChristianHJW>allwithyouguys...

[21:41]<Suiryc>inNandubhereiswhathappenswithanMP3stream(VBRone)

[21:42]<Suiryc>NandosetdwRatetothesamplerate(44100,48000,...)

[21:42]<spyder482>don'tyoutwohaveachannelforthis?:)

[21:42]<Suiryc>spyder482:shutup:P

[21:42]<Suiryc>andsetdwScaleto1152

[21:42]<spyder482>lol

[21:42]<Belgabor|Home>no,theotheroneisjustforlurking

[21:42]<Belgabor|Home>:p

[21:42]<Suiryc>:]

[21:42]<spyder482>hehe

[21:43]<Suiryc>andsetnBlockAlignto1152too

[21:43]<Suiryc>then,whenmuxingitonlytreatwholeMP3frames

[21:43]<Suiryc>(i.e.eachMP3frameisinitsownChunk)

[21:44]<Suiryc>youstillfollow?

[21:44]<md`>whohasdonethempeg2importpartofvdmod?

[21:44]<Belgabor|Home>ok,onemp3frameiswhat?

[21:44]<Belgabor|Home>pulco-citron

[21:44]<md`>hmpf

[21:44]<spyder482>pulco-citron

[21:44]<spyder482>oh

[21:44]<spyder482>:)

[21:45]<md`>whydoeshegenerated2vanddontlettheuserdecidetopickone...

[21:45]<Belgabor|Home>dunno

[21:45]<md`>ifthereisonealready

[21:45]<md`>hmmm

[21:45]<Suiryc>Belgabor|Home:anMpeg1-Layer3frameistheshorterblockofdatayoucanuse

[21:45]<ChristianHJW>letSuirycfinishguys..please

[21:45]<md`>yesok

[21:45]<Belgabor|Home>ok

[21:45]<spyder482>ChristianHJW:check#virtualdub

[21:45]<Suiryc>itcontainsanheadersayingwhatisintheframe,andthenthedata(audio)

Page 28: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

[21:46]<ChristianHJW>wehavetoknowwhatswronginAVItobeabletoadvertisematroska;-)

[21:46]<Belgabor|Home>thisishowmuchdata?

[21:46]<Suiryc>somehow1MP3frame~1videoframe

[21:46]<Belgabor|Home>ChristianHJW:lol

[21:46]<Suiryc>thesizeofaframedependsontheMP3settings

[21:46]<Suiryc>(i.e.bitrate,...)

[21:46]<Belgabor|Home>ok

[21:47]<Belgabor|Home>isitfixedforafileorvaribleinvbr?

[21:47]<Suiryc>howeveraMpeg1-layer3frameconatins1152samples

[21:47]<Suiryc>thesizeofaframeisvariable

[21:47]<Suiryc>eveninCBR

[21:48]<Suiryc>(e.g.frameswillbeof417or418bytes)

[21:48]<Belgabor|Home>ok,but1152istheupperlimit?

[21:48]<Suiryc>becauseafixedbtratemustbeachieved

[21:48]<Suiryc>1152isthenumberofsamplesaframecontains

[21:48]<Suiryc>eachframe(whateveritssizemaybe)contains1152samples

[21:49]<Belgabor|Home>oic

[21:49]<Suiryc>solet'scontinue;)

[21:49]<Suiryc>eachframecontains1152samples

[21:49]<Belgabor|Home>ok

[21:49]<Suiryc>andtherateofthestream(inAVISTREAMINFO)hasbeensetto:

[21:49]<Suiryc>dwRate/dwScale=SampleRate/1152

[21:50]<Suiryc>sinceeachFramecontains1152itisequaltothe'framerate'

[21:50]<Suiryc>(asforvideo)

[21:50]<Belgabor|Home>ok,ithinkigotthat

[21:50]<Suiryc>nowyoumustrecallthateachframeisinitsownAVIchunk

[21:50]<Belgabor|Home>ok

[21:50]<Suiryc>soitisalsothe'chunkrate'

[21:51]<Suiryc>sohereisnowwhathappens(itismostlikelywhathappens)whenplayingthefileinWindowMediaPlayer

[21:51]<Belgabor|Home>ic

[21:51]<Suiryc>WMPwillgetbothheaders

[21:52]<Suiryc>whichwillsaytoitthattherateofthestreamisSampleRate/1152

[21:52]<Belgabor|Home>gimmeasec,brb

[21:52]<Suiryc>andthateachaudioframeis1152byteslong(nBlockAlign)

[21:52]<Suiryc>k

[21:53]<Belgabor|Home>back

[21:54]<Suiryc>oksoWMPbelieveeachframeis1152byteslong

[21:54]<Belgabor|Home>yeah

[21:54]<Suiryc>whichisnotthecase(generallyframesarearound400byteslongwith128kbpsstream)

[21:55]<Suiryc>but

[21:55]<Belgabor|Home>yeah,gotthatmuch

[21:55]<Suiryc>nowyouarereadingdatainthefile

[21:55]<Suiryc>andWMPneedstoknowwhentoreadtheaudio

[21:55]<Suiryc>(i.e.towhichtimecorrespondanaudioframe)

[21:56]<Suiryc>todosoitwilllookatallthepreviousaudiochunksinthefile

[21:56]<Suiryc>foreachshunkitdividethesize(inbytes)ofthechunkbynBlockAligntoknowhowmanyframestherewereinthechunk

[21:56]<Belgabor|Home>ok

[21:56]<Suiryc>s/shunk/chunk

[21:57]<Belgabor|Home>ok

[21:57]<Suiryc>(sinceeverytoolsdealingwiththestreammustcutonnBlockAlignboundaries)

Page 29: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

[21:57]<Suiryc>sinceeachchunkisshorterthan1152bytes(nBlockAling)itshoulget0

[21:57]<Suiryc>butthisisnotpossible

[21:58]<Suiryc>sincetoolsworkonblocksofnBlockAlignbytes,itmustassumethanthereisatleast1frameinthechunk

[21:58]<Suiryc>(evenifthechunkisshorter)

[21:59]<Suiryc>soforeachchunkitfindthereis1frameinit

[21:59]<Suiryc>whichisreallythecase(eachmp3frameisinitsownchunk)

[21:59]<Suiryc>soWMPgotthecorrectnumberofmp3framesplayedsofar

[22:00]<Suiryc>andsinceithasthecorrectrate(eachframecontains1152samples,andtherateofthestreamisSampleRate/1152)

[22:00]<Suiryc>italsogotthecorrecttimecodefortheframe

[22:00]<Belgabor|Home>ok

[22:00]<Suiryc>resultinginaperfectlysynchedMP3stream

[22:01]<Suiryc>IwasleadtothisconclusionwithoutdebuggingWMPwhileplaying;)butwithsometestsImade:

[22:02]<Suiryc>IchangedthedwScalevalue(withorwithoutthenBlockAlignvalue)

[22:02]<Suiryc>butthisresultedinotuofsynchissues(audioplayingtoofast/slow)

[22:02]<Suiryc>out*

[22:02]<Suiryc>IchangedthenBlockAlignvaluie:

[22:03]<Suiryc>settingitto1andthenIhaveoutofsynchissuestoo

[22:03]<Suiryc>butsettingit2304andIstilhaveaperfectlysynchedstream

[22:03]<Belgabor|Home>ok

[22:04]<Suiryc>soinfactthe1152valueinnBlockAligncouldbeanythingelse

[22:04]<Suiryc>_but_

[22:04]<Suiryc>mustbehigherthanthesizeofanmp3frame

[22:04]<Belgabor|Home>ok,whathappensifyousetitto0?

[22:04]<Suiryc>lol

[22:05]<Suiryc>ifyousetitto0thenWMPwon'tplaythestream(theiconforaudioisdisabledlikeifthereisnoaudiointhefile)

[22:05]<Suiryc>sonoVBR;)

[22:05]<Belgabor|Home>ok

[22:06]<Belgabor|Home>sothefailureisinpriciplenotinavi,butintheWAVEFORMATEXheader

[22:06]<Suiryc>yep

[22:06]<Suiryc>butsincetheAVIwilluseWAVEFORMATEXforaudioheaders,itisstillafailureinAVIspecs

[22:07]<Belgabor|Home>doyouhavetheresemblanceofanideawhyvbrmp3fails?

[22:07]<Belgabor|Home>yep

[22:07]<Suiryc><Belgabor|Home>doyouhavetheresemblanceofanideawhyvbrmp3fails?<--youmeanwhyitisnotgood?

[22:08]<Belgabor|Home>yep,whyitfailssometimes

[22:08]<ChristianHJW>thatswhatiaminterestedinalso

[22:08]<Suiryc>wellinthecaseofWMP,itwilldividethechunksizebynBlockAlign

[22:08]<Suiryc>(that'swhatIthink,sincethesynchisgood)

[22:08]<Suiryc>andwillsetitto1ifthechunksizeistoosmall

[22:09]<Suiryc>butthereisanotherwaytocomputetimecode

[22:09]<Suiryc>(assumingthatyouhaveCBRofcourse)

[22:09]<Suiryc>youtakethetotalbytesinpreviouschunks

[22:09]<Suiryc>anddivideitbynblockAlign

[22:10]<Belgabor|Home>whichfailsmiserablyforthevbrhack

[22:10]<Suiryc>ofcourseinthiscaseyougetacompletlywrongvaluesincemp3framesarenot1152byteslnog

[22:10]<Suiryc>yep

[22:10]<Suiryc>otehrtoolsmayalsoassumethatthechunkisnotvalid(corrputed)sinceitssizeisshorterthannBlockAlign

[22:11]<Belgabor|Home>ok,thatsthefailureinprinciple,butwhyaresomefilesbroken?

[22:12]<Suiryc>whatfiles?

[22:12]<Suiryc>broken?whatdoyoumeanbybroken?

[22:13]<Belgabor|Home>ihadsomevbrmp3aviswhichseemedlikehavingdivx3freezeframesbutwhereokwhendemuxed

Page 30: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

[22:13]<Suiryc>dunno

[22:13]<Suiryc>maybeaproblemwiththedecoder

[22:14]<Belgabor|Home>ok,wellthatclearedthingsupabit

[22:14]<Belgabor|Home>thx:)

[22:14]<Suiryc>:)

[22:14]<Suiryc>btwtheremaybeproblemswithNandubcode;)

[22:14]<Suiryc>because:

[22:14]<Suiryc>1.layer1streamsonlyhave384samplesperframe

[22:15]<Suiryc>2.IIRCwithveryhighbitratesanmp3framecanbehigherthan1152bytes;)

[22:15]<Suiryc>s/higher/bigger

[22:16]<Suiryc>(themaxsizeisnear2000bytesIIRC)

[22:16]<Belgabor|Home>ok,sonBlockAlignshouldbe>2000

[22:17]<Suiryc>sodependingonthewaydividingisused(roundingtofloororceilornearestvalue)

[22:17]<Suiryc>andthemaxsizeofaframe,itmayfindthereare2framesinachunkwherethereisonly1frame

[22:17]<Belgabor|Home>ok,igotthat

[22:18]<Suiryc>butthisisforreallyhighbitrates...

[22:18]<Suiryc>lemmecheck...

[22:19]<Belgabor|Home>whatwouldhappenifweputtwoframesinonechunk?akasetdwRate=2*samplerateandsoon?

[22:20]<Belgabor|Home>no,nottwo,justdoublethevalues?

[22:21]<Suiryc>ifyoudoublethevaluetherateoftheaudiowillbechangedaccordingly

[22:21]<Suiryc>sotokeepitcorrectyouwouldhavetoput2mp3framesineachchunk

[22:22]<Suiryc>butthenyouwouldmostlikelygobeyondthe1152bytesperchunk

[22:22]<Suiryc>andincreasethechancestogenerateoutofsynchproblems

[22:23]<Belgabor|Home>letmerethink

[22:24]<Suiryc>changingdwRateanddwScaleonlyaffectstherateofthestream

[22:25]<Suiryc>multiplyingdwRateby2=>audioplay2timesfaster

[22:25]<Suiryc>multiplyingdwScaleby2=>audioplay2timesslower

[22:25]<Belgabor|Home>ifwedoubledwrate,dwscale,nblockalignanddwsamplesize?

[22:25]<Suiryc>multipylingboth=>nochange

[22:25]<Suiryc>dwSampleSizeissetto0

[22:26]<Belgabor|Home>ahok,soskipthat

[22:26]<Suiryc>(dwRate,dwScale)andnBlockAlignarenotlinked

[22:26]<Suiryc>youcanuseahighervalueinnBlockAlign

[22:27]<Suiryc>(likethe2304Itested)

[22:27]<Belgabor|Home>nvertheless,ifwedoubleallthree,shouldntitbesafeforlargermp3frames?

[22:27]<Suiryc>thiswon'tchangeanythinginthecaseofWMPbecausesomethinglowerthan1152dividedby1152or2304willstillberoundedto0

[22:27]<Suiryc>Belgabor|Home:thiswouldbesafer

[22:28]<Suiryc>butwouldcauseevenmoretroublesinappsthatdon'tworkthesamewaythanNandub&WMP

[22:28]<Suiryc>Ithinksomeappssometimescheckavalueof1152toknowitwasmadebyNandub

[22:28]<Belgabor|Home>ok,iseethepoint

[22:29]<Belgabor|Home>faultyconceptstaysfaulty

[22:33]<Suiryc>kIchecked

[22:33]<Suiryc>keeping1152shoudln'tcausetoomuchproblems

[22:33]<Suiryc>forMpeg1-Layer2/3themasisnear1750byteslong

[22:34]<Suiryc>therecouldbeproblemswithMpeg2/2.5-layer2/3

[22:34]<Suiryc>wherea160kbpsstreamof8kHzhaveframesof2881byteslongatmost

[22:35]<Suiryc>anywayIdon'tthinkpeopleusethiskindofstream;)

[22:36]<ChristianHJW>highlyunlikely..

[22:51]<Suiryc>nite

[22:52]*Suirychasleft#matroska

Page 31: VirtualDubMod is a project that was born when suddenly a ... · Priss rocks! : let you use Priss (VirtualDub internal Mpeg audio decoder) instead of an ACM one when decoding MP3 audio.

Thecentralproblemis(imho)itworksnow.AssoonasM$changestheroundingfunctionintheiraviparserfromceiltosomethingelse,itwillstopworking.