VideoHelp Forum




+ Reply to Thread
Results 1 to 10 of 10
  1. Hi,

    I've got this OGM (DivX/Vorbis) video file where I wanted to convert it into AVI container with XviD/MP3.

    So I was able to split the file into video/audio using OGMDemuxer v2.0.

    But after I convert the OGG audio into WAV, the length of the file has been shorten. Original length was 1hr 40min. The WAV output is 1hr 38min.

    Hence I tried to stretch the audio back to its original length using CoolEdit.

    But the audio still out of sync with the original video when I play it in Media Player Classic.

    Has anyone any idea how I can decode the OGG into WAV/MP3 without the loss of time?

    Thank you for any advice.

    EDIT: Sorry, I got the name mixed up. OGGDecoder -> OGMDemuxer.
    Quote Quote  
  2. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    try open the ogg directly with goldwave and convert to wav.
    Quote Quote  
  3. Thanks Baldrick. I'll try it right away.

    Previously I tried this using oggdecode.exe that I downloaded from vorbis.com (official site) and I've even converted the file to MP3 (LAME codec) using VirtualDubMod via Stream list using "Save WAV" way.

    I'll update here the result.
    Quote Quote  
  4. Member
    Join Date
    Dec 2004
    Location
    Australia
    Search Comp PM
    ogm != ogg, so using tools designed for ogg's might cause problems.

    You won't gain any quality converting from DivX to XviD.

    mencoder -oac mp3lame -ovc copy input.ogm -foucc XVID -o output.avi should work assuming that it is DivX 4.x or 5.x. Never tried setting a fourCC with -ovc copy though.
    Quote Quote  
  5. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    i mean open the ogm, ogg media file directly with goldwave. you need the oggds installed.

    you can also try use ogmdemuxer to strip the audio.

    or just try mencoder as celtic_druids says...very easy method if you know how to use command line tools. maybe time to make a mencoder container converter gui for us lazy ones...
    Quote Quote  
  6. Ok guys, thanks for all the input.

    These are what I've done so far, prior to starting this thread.

    1) I've used OGMDemuxer (always forgot the name, too many similar names, how about calling it EGG instead? :P *no offence to the original author*to split the OGM video file into .AVI (DivX) and .OGG (Vorbis).
    2) Then I decode the .OGG file into .WAV using OggDec v1.0 (CLI), oggdropXPd v1.8.3 (Drag & Drop). Both returned the same discrepancy in .WAV output.
    3) I've even tried to Demux the audio into MP3 (based on Baldrick's instructions) using VirtualDubMod v1.5.10.1.

    Final results, time/duration of file is shown in Media Player Classic v6.4.8.4
    OGG = 1:40:02
    MP3 = 1.38:58
    WAV = 1.38:58

    NOTE: When I use OggDec.exe (oggdec.exe audio.ogg [no switches]), the process finished at 98.5% and ended without error. I don't understand why. But when I listen to it, the audio was not truncated at all, they both basically are the same at the end, just that source file (.OGG) was a bit longer in duration than the output.

    Code:
    K:\TORREN~2\_JAVFA~1.UNC>oggdec audio.ogg
    OggDec 1.0
    Decoding "audio.ogg" to "audio.wav"
            [ 98.5%]
    Up to now, I've tried & tested GoldWave. It gave the same results.
    1) Drag & Drop the .OGG file into GoldWave, it shows 1:38:58.112 though. So I suspect GoldWave first decoded the file into WAV for editing purposes.

    Is this caused by the nature of OGG file that it's VBR?

    celtic_druid: Thanks for the advice. The reason why I want to convert my video to XviD is because I want a shorter keyframes (150 frames/key) as opposed to 300, which is a tad too slow on the seek when I view the video.

    Secondly, I don't know why, now my PC plays DivX video like a resource hog. XviD seems to play fine. Must be some filters that I've installed that came with K-Lite Mega Codec Pack v1.20.

    Will update you guys when I try the Mencoder/MPlayer.
    Quote Quote  
  7. Member
    Join Date
    Dec 2004
    Location
    Australia
    Search Comp PM
    XviD can decode DivX 4.x and 5.x just fine.

    You can actually re-encode to XviD using mencoder: -ovc xvid, use -xvidencopts to set options, like bitrate, etc.

    Could also try mplayer.exe -ao pcm:file=out.wav -vo null -vc dummy input.ogm to decode just the audio to wav and see if you can get the correct length.
    Quote Quote  
  8. I wouldn't mind the trouble, as long as I can get the correct length.

    Since I've already spent so much time on this already.

    Yeah, I know about the interchangeable between DivX/XviD. Both can play each other, it's like one of them was a cheap rip off the other. LOL!

    But can I set the keyframe without re-encoding the whole video? I don't think there's shortcut in it, cause the keyframe was set in the codec itself.

    Anyway, I've already re-encoded the video to XviD now, it's on standby to be merged with the audio file, if I can get the correct length.

    Another reason I don't want to make it into .OGM file is, I can use SHIFT+LEFT/RIGHT arrow to skip to next keyframe using MPC's built-in AVI filter. Pretty neat and the seek is damn fast, so I like it alot. But occassionally jammed up the playback. LOL!

    EDIT: Tested with mencoder, these are what I get from the output
    Code:
    Writing AVI index...
    Fixing AVI header...
    ODML: Aspect information not (yet?) available or unspecified, not writing vprp h
    eader.
    
    Video stream:  988.766 kbit/s  (123595 bps)  size: 733908373 bytes  5937.971 sec
    s  179890 frames
    
    Audio stream:  135.547 kbit/s  (16943 bps)  size: 100617888 bytes  5938.488 secs
    Alright, seems like the audio is sync'ed, but the whole video file shrunken to 1hr 38min 58sec (from 1hr 40min 02sec originally), which is the length of the audio after decoded from OGG.

    Playback is a little broken at certain frames.
    Quote Quote  
  9. Hmm, I don't know if it can help, but what if you put a delay upon multiplexing the video/audio?
    Quote Quote  
  10. Originally Posted by Abond
    Hmm, I don't know if it can help, but what if you put a delay upon multiplexing the video/audio?
    You mean in VirtualDub when doing Multiplexing?

    Tried that, but the audio started late, still causes the final output video file to be out of sync with the audio.

    Maybe I'll start off from the output I created using mencoder, since the audio is in-sync already.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!