Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > New and alternative a/v containers

Reply
 
Thread Tools Search this Thread Display Modes
Old 4th January 2013, 16:24   #1  |  Link
Mierastor
Registered User
 
Join Date: Nov 2010
Posts: 15
Opus and Matroska

Is support for Opus in Matroska being actively developed? It has been mentioned in several places but there seems to be no activity for several months now.

http://wiki.xiph.org/MatroskaOpus
http://lists.matroska.org/pipermail/...read.html#4153
http://lists.matroska.org/pipermail/...read.html#4252

It would be great if one could use x264 + Opus which I think is not currently possible?
Mierastor is offline   Reply With Quote
Old 4th January 2013, 16:29   #2  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,191
mkvmerge: implement experimental Opus support ...4 days ago

Quote:
Originally Posted by Mierastor View Post
It would be great if one could use x264 + Opus which I think is not currently possible?
You should try latest FFmpeg or avconv builds...

Last edited by Kurtnoise; 4th January 2013 at 16:35.
Kurtnoise is offline   Reply With Quote
Old 8th January 2013, 23:12   #3  |  Link
Mierastor
Registered User
 
Join Date: Nov 2010
Posts: 15
Quote:
Originally Posted by Kurtnoise View Post
mkvmerge: implement experimental Opus support ...4 days ago


You should try latest FFmpeg or avconv builds...
Thanks! Good to see that something is happening! But I guess that since it is marked as experimental and there is still no official Matroska specification it is of limited use outside experimentation.

x264 + Opus seem to be a very good combination so I hope that there will eventually be an official method for combining them.

Last edited by Mierastor; 8th January 2013 at 23:14.
Mierastor is offline   Reply With Quote
Old 10th January 2013, 15:30   #4  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,191
Google has announced that WebM will support VP9 + Opus as audio codec...

I think that using a pre-build from mkvtoolnix you should be able to mux x264 stream within Opus.
Kurtnoise is offline   Reply With Quote
Old 10th January 2013, 15:33   #5  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,344
Using an experimental build for anything more then testing may not be a good idea, as it may happen that somethings change, and the file won't be readable with the final spec for Opus in MKV.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders
nevcairiel is offline   Reply With Quote
Old 10th January 2013, 15:40   #6  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
Yes. Currently the CodecID is even explicitly marked "EXPERIMENTAL", so this is almost guaranteed to happen.
sneaker_ger is offline   Reply With Quote
Old 10th January 2013, 17:25   #7  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,191
Agreed...I never said the contrary but it could be fun to test it though.

the CodecID will not change I think unless there will be a good reason...might be change is the storage of Opus stream into the container.
Kurtnoise is offline   Reply With Quote
Old 10th January 2013, 17:42   #8  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
The CodecID is "A_OPUS/EXPERIMENTAL", so it will definitely change, even if there are no other changes to the way Opus is stored.
sneaker_ger is offline   Reply With Quote
Old 10th January 2013, 17:49   #9  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,191
Quote:
Originally Posted by sneaker_ger View Post
The CodecID is "A_OPUS/EXPERIMENTAL", so it will definitely change, even if there are no other changes to the way Opus is stored.
Where did you see this ?

Reading the commit, it's :
Code:
+#define MKV_A_OPUS       "A_OPUS"
Kurtnoise is offline   Reply With Quote
Old 10th January 2013, 17:58   #10  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
It seems to be added dynamically, see p_opus.cpp line 44.
sneaker_ger is offline   Reply With Quote
Old 11th January 2013, 20:11   #11  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,278
Looks like this thread needs an official answer

ffmpeg has an implementation that writes Matroska files with CodecID A_OPUS. However, the way it is stored ignores all the problems surrounding the storage of Opus in Matroska. Add that the we (Matroska team) haven't specified the storage yet, and you can see that you should not use ffmpeg for muxing Opus into Matroska at the moment.

mkvmerge's support for Opus in Matroska is experimental. It can be read from Ogg and Matroska files (mkvmerge can read its own creation). However, as stated above the Matroska specs regarding Opus are not done yet. And mkvmerge also hasn't solved the remaining problems yet. That's why mkvmerge uses A_OPUS/EXPERIMENTAL. This will change to A_OPUS once the specs have been finalized and mkvmerge has been updated to match them. The storage format itself will not change too much, however, the way timecodes are calculated/offset/adjusted might -- meaning there is a definite chance you won't be able to play back A_OPUS/EXPERIMENTAL files in the future. So this means that you should not throw away the source files after using mkvmerge for muxing Opus at the moment

As for the specs: about a week ago I've grilled several guys in the Opus IRC channel about the problematic areas. I have a much better understanding of what is what and how stuff should be handled. However, how that translates into Matroska terms is still work that must be done.

I plan on continueing this work over the next couple of weeks, but I don't have a time frame for that. Nor does anyone else seem to want to help, so there.

The areas that no solutions/decisions exist for currently are:
  • Who is responsible for adjusting the timecodes for pre-skip -- the muxer, the demuxer, the codec? This directly influences the question "Must the pre-skip be stored in the Matroska track headers?".
  • Sample-accurate trimming in the last packet. For this we need a new element in the Matroska BlockGroup element. However, this can be solved easily (unlike the the pre-skip issue which is much more involved).
  • The question whether or not we can implement a solution for pre-skip that works for rolling intra video as well is still unresolved (mostly because I have no friggin' clue how rolling intra video is handled).

Areas we do have solutions for:
  • Handling of pre-roll (the new cue elements "cue relative position" and "cue duration" can be used for this, both muxers and demuxers must be enabled to make use of them)
  • CodecPrivate data format (simply the format header/first Opus packet in a logical stream -- if I remember correctly)


Note that the Xiph wiki page for Opus in Matroska is NOT up to date.
__________________
Latest MKVToolNix is v83.0

If I ever ask you to upload something, please use my file server.
Mosu is online now   Reply With Quote
Old 11th January 2013, 20:13   #12  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,278
Quote:
Originally Posted by nevcairiel View Post
Using an experimental build for anything more then testing may not be a good idea, as it may happen that somethings change, and the file won't be readable with the final spec for Opus in MKV.
My experimental builds (those in http://www.bunkus.org/videotools/mkvtoolnix/win32/pre/) are usually as stable as the releases.If the data storage format is still unstable/unfinished then I usually modify the CodecID that mkvmerge outputs for the corresponding format to make that very clear (as with A_OPUS/EXPERIMENTAL).

Of course some of my pre-builds might experiment with newly introduced Matroska elements that are removed again later. However, that's rather rare.
__________________
Latest MKVToolNix is v83.0

If I ever ask you to upload something, please use my file server.
Mosu is online now   Reply With Quote
Old 14th May 2013, 23:46   #13  |  Link
XeoneR
Registered User
 
Join Date: Jul 2003
Posts: 17
*
Does anybody aware how to split & playback an mkv with opus?
XeoneR is offline   Reply With Quote
Old 15th May 2013, 02:18   #14  |  Link
the_weirdo
Yes, I'm weird.
 
the_weirdo's Avatar
 
Join Date: May 2010
Location: Southeast Asia
Posts: 271
Quote:
Originally Posted by XeoneR View Post
*
Does anybody aware how to split & playback an mkv with opus?
LAV Filters can do that.
__________________
“Never argue with stupid people, they will drag you down to their level and then beat you with experience.” — Mark Twain
the_weirdo is offline   Reply With Quote
Old 18th August 2013, 17:17   #15  |  Link
bugmen0t
Banned
 
Join Date: May 2012
Location: _Lies|Greed|Misery_
Posts: 114
Bump.

Mosu, is there any news on the process of getting opus into matroska? Are you guys any closer to finishing the specs?







Villa Palmar Cancun Timeshare

Last edited by bugmen0t; 21st February 2014 at 23:52.
bugmen0t is offline   Reply With Quote
Old 18th August 2013, 23:40   #16  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
It has been finalized and already been implemented in mkvtoolnix git, so it should be in the very next stable version.
sneaker_ger is offline   Reply With Quote
Old 19th August 2013, 20:13   #17  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,278
What sneaker_ger said. However, the code is still untested. Only my own eyes have looked at the resulting files so far, and that means that there may still be bugs (things that aren't implemented 100% the way the specs say it should be done/how we discussed on matroska-devel how it should be done).
__________________
Latest MKVToolNix is v83.0

If I ever ask you to upload something, please use my file server.
Mosu is online now   Reply With Quote
Old 17th April 2014, 03:21   #18  |  Link
raine
Registered User
 
Join Date: Apr 2014
Posts: 9
Quote:
Originally Posted by Mosu View Post
Looks like this thread needs an official answer

ffmpeg has an implementation that writes Matroska files with CodecID A_OPUS. However, the way it is stored ignores all the problems surrounding the storage of Opus in Matroska. Add that the we (Matroska team) haven't specified the storage yet, and you can see that you should not use ffmpeg for muxing Opus into Matroska at the moment.

mkvmerge's support for Opus in Matroska is experimental. It can be read from Ogg and Matroska files (mkvmerge can read its own creation). However, as stated above the Matroska specs regarding Opus are not done yet. And mkvmerge also hasn't solved the remaining problems yet. That's why mkvmerge uses A_OPUS/EXPERIMENTAL. This will change to A_OPUS once the specs have been finalized and mkvmerge has been updated to match them. The storage format itself will not change too much, however, the way timecodes are calculated/offset/adjusted might -- meaning there is a definite chance you won't be able to play back A_OPUS/EXPERIMENTAL files in the future. So this means that you should not throw away the source files after using mkvmerge for muxing Opus at the moment

As for the specs: about a week ago I've grilled several guys in the Opus IRC channel about the problematic areas. I have a much better understanding of what is what and how stuff should be handled. However, how that translates into Matroska terms is still work that must be done.

I plan on continueing this work over the next couple of weeks, but I don't have a time frame for that. Nor does anyone else seem to want to help, so there.

The areas that no solutions/decisions exist for currently are:
  • Who is responsible for adjusting the timecodes for pre-skip -- the muxer, the demuxer, the codec? This directly influences the question "Must the pre-skip be stored in the Matroska track headers?".
  • Sample-accurate trimming in the last packet. For this we need a new element in the Matroska BlockGroup element. However, this can be solved easily (unlike the the pre-skip issue which is much more involved).
  • The question whether or not we can implement a solution for pre-skip that works for rolling intra video as well is still unresolved (mostly because I have no friggin' clue how rolling intra video is handled).

Areas we do have solutions for:
  • Handling of pre-roll (the new cue elements "cue relative position" and "cue duration" can be used for this, both muxers and demuxers must be enabled to make use of them)
  • CodecPrivate data format (simply the format header/first Opus packet in a logical stream -- if I remember correctly)


Note that the Xiph wiki page for Opus in Matroska is NOT up to date.
What is the status on this? The changelog suggests that it is now OK?
raine is offline   Reply With Quote
Old 17th April 2014, 12:18   #19  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,278
In mkvmerge it is, yes. I cannot comment on ffmpeg's muxer.
__________________
Latest MKVToolNix is v83.0

If I ever ask you to upload something, please use my file server.
Mosu is online now   Reply With Quote
Old 17th April 2014, 12:27   #20  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,191
It's well supported in FFmpeg since the release 2.1...
Kurtnoise is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 19:20.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.