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. |
26th November 2010, 18:37 | #1 | Link |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
[solved] Decoding DNxHD 10bit with MPlayer?
Since I managed to get mencoder&mplayer to playback/decode Apple ProRes I was wondering if someone here knows a way how to playback/decode DNXHD 10bit Material?
Maybe by using the Quicktime Components coming with the Avid QuickTime Codecs LE 2.1? (AvidAVdnCodec.qtx should be the one needed,..) Cu Selur Ps.: No, I don't want to use Avisynth or any Avisynth plugin to do the job, I'm interested to know if someone know a way do to it with mplayer/mencoder. Last edited by Selur; 26th November 2010 at 21:07. Reason: solved -> see last post |
26th November 2010, 19:46 | #2 | Link |
Registered User
Join Date: Jun 2005
Posts: 278
|
Implement 10-bit support in FFmpeg's DNxHD decoder?
But in principle yes, using the Quicktime component should be possible, it is basically a matter of adding an entry for it to the codecs.conf file (so should not even need a recompile, though you would probably need a SVN checkout to get an "initial" copy if that file). There is supposed to be a document describing how to add support for a binary codec somewhere in the documentation but I don't know where exactly. |
26th November 2010, 19:57 | #3 | Link | |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
Looking at the codecs.conf file in the SVN I really need some good documentation to get this working,.. so still hoping someone know a bit more about this,...
(just realized there are two codecs.conf files one in the main folder and one under etc,..) Okay, I found: http://www.mplayerhq.hu/DOCS/tech/codecs.conf.txt, copied etc/codecs.conf to the folder where my mplayer bianary lies, removed: Code:
videocodec ffdnxhd info "FFmpeg DNxHD" status working fourcc AVdn driver ffmpeg dll "dnxhd" out 422P Code:
videocodec dnxhd info "QuickTime Avid DNxHD" status untested fourcc AVdn driver qtvideo dll "AvidAVdnCodec.qtx" out YUY2 Code:
MPlayer Sherpya-SVN-r32492-4.2.5 (C) 2000-2010 MPlayer Team Playing test - clips\problematic\DNxHD_10bit.mov. libavformat file format detected. [dnxhd @ 01f14fb0] 10 bit per component [dnxhd @ 01f14fb0] 10 bit per component [dnxhd @ 01f14fb0] 10 bit per component [dnxhd @ 01f14fb0] 10 bit per component [dnxhd @ 01f14fb0] 10 bit per component [dnxhd @ 01f14fb0] 10 bit per component [lavf] stream 0: video (dnxhd), -vid 0 [lavf] stream 1: audio (pcm_s16be), -aid 0, -alang eng VIDEO: [AVdn] 1920x1080 24bpp 25.000 fps 183500.8 kbps (22400.0 kbyte/s) Clip info: major_brand: qt minor_version: 537199360 compatible_brands: qt ========================================================================== Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family Selected video codec: [ffdnxhd] vfm: ffmpeg (FFmpeg DNxHD) ========================================================================== ========================================================================== Opening audio decoder: [pcm] Uncompressed PCM audio decoder AUDIO: 48000 Hz, 2 ch, s16be, 0.0 kbit/0.00% (ratio: 0->192000) Selected audio codec: [pcm] afm: pcm (Uncompressed PCM) ========================================================================== AO: [dsound] 48000Hz 2ch s16le (2 bytes per sample) Starting playback... ... Exiting... (End of file) -> found it, needs to be in a 'mplayer' named subdirectory of the directory where mplayer is located Code:
mplayer "test - clips\problematic\DNxHD_10bit.mov" -demuxer mov -forcedsubsonly -noautosub -fps 25 -lavdopts threads=8 -font "C:/Windows/Fonts/10249.ttf" -osdlevel 3 -fixed-vo -vo direct3d Quote:
got it working with: Code:
videocodec dnxhd info "QuickTime Avid DNxHD" status untested fourcc AVdn driver qtvideo dll "AvidAVdnCodec.qtx" out BGR24 Cu Selur Last edited by Selur; 26th November 2010 at 20:39. |
|
26th November 2010, 21:47 | #4 | Link | |
Registered User
Join Date: Nov 2004
Location: Poland
Posts: 2,843
|
Quote:
No gamma, color shifts? It would be better to have YUY2 on the output. Most DNxHD steams will be YUV, only in some cases they will be RGB (DNxHD supports both) Is decoding multithreaded ? Andrew Last edited by kolak; 26th November 2010 at 21:57. |
|
26th November 2010, 21:58 | #5 | Link | |||||
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
I accidentally deleted my DNxHD test file -> downloading it in the background
Quote:
Quote:
=> Update: Code:
mplayer "D:\Hybrid\test - clips\DNxHD_10bit.mov" -demuxer mov -forcedsubsonly -noautosub -nosound -lavdopts threads=8 -font "C:/Windows/Fonts/10249.ttf" -benchmark -vo null Quote:
Code:
mencoder "D:\Hybrid\test - clips\DNxHD_10bit.mov" -ovc raw -noskip -demuxer mov -vid 0 -vf scale,format=i420 -forcedsubsonly -noautosub -nosound -mc 0 -lavdopts threads=8 -really-quiet -fps 25 -aspect 1.77778:1 -of rawvideo -o - | x264 --preset ultrafast --qp 18 --sync-lookahead 15 --fps 25 --input-res 1920x1080 --output "D:\Hybrid\test - clips\test_22_20_49_871_01.264" - Quote:
Quote:
Cu Selur Last edited by Selur; 26th November 2010 at 22:25. |
|||||
26th November 2010, 23:21 | #8 | Link |
Registered User
Join Date: Nov 2004
Location: Poland
Posts: 2,843
|
Try simple decode to something easy to encode or uncompressed if you have RAID. This will show possibilities of decoding.
I can get about 1.5x-2x faster than RT decoding to uncompressed (avisynth with QT import plugin). If it goes through AVID codecs than it will be probably the same. AVID's QT decoder is not multithreaded- this what I have heard. Would be nice to have faster decoding. Andrew |
27th November 2010, 08:58 | #11 | Link | ||
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
Quote:
YVYU -> no video -> Code:
videocodec dnxhd info "QuickTime Avid DNxHD" status working fourcc AVdn driver qtvideo dll "AvidAVdnCodec.qtx" out UYVY,BGR24 Code:
BENCHMARKs: VC: 4.168s VO: 0.001s A: 0.000s Sys: 2.362s = 6.531s BENCHMARK%: VC: 63.8187% VO: 0.0153% A: 0.0000% Sys: 36.1660% = 100.0000% Quote:
Cu Selur Ps.: Looking at the .qtx files coming with Avid QuickTime Codecs LE 2.1 some additional formats would be possible to decode,.. - AvidAV1xCodec.qtx: Avid 1:1x codec (Uncompressed MXF 8-bit) - AvidAVd1Codec.qtx: Avid DV 100 codec (MXF) - AvidAVdnCodec.qtx: Avid DNxHD codec (MXF) - AvidAVdvCodec.qtx: Avid DV codec(DV 25 and DV 50, OMF and MXF) - AvidAVpkCodec.qtx: Avid Packed codec (Uncompressed MXF 10-bit) - AvidQTAVJICodec.qtx: Avid Meridien Compressed codec (OMF 8-bit) - AvidQTAVUICodec.qtx: Avid Meridien Uncompressed codec (OMF 8-bit) -> won't test these since I got no samples to test with. Last edited by Selur; 27th November 2010 at 09:31. |
||
27th November 2010, 10:58 | #12 | Link | ||
Registered User
Join Date: Jun 2005
Posts: 278
|
Quote:
It's a good idea to delete your custom codecs.conf version, even though MPlayer should start ignoring it when it notices it is outdated. Quote:
|
||
27th November 2010, 11:05 | #13 | Link | |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
Quote:
While at it: Could you also change the "printf("-calls in the components.h to "printf(stderr, " calls? The printf calls break the video output when using stdout-pipes. I stumbled over it when trying to reencode ProRes content with mencoder, see: http://forum.doom9.org/showthread.php?t=158066 Cu Selur |
|
27th November 2010, 12:40 | #14 | Link | |
Registered User
Join Date: Nov 2004
Location: Poland
Posts: 2,843
|
Quote:
mencoder "D:\Hybrid\test - clips\DNxHD_10bit.mov" -ovc raw -noskip -demuxer mov -vid 0 -vf scale,format=i420 -forcedsubsonly -noautosub -nosound -mc 0 -lavdopts threads=8 -really-quiet -fps 25 -aspect 1.77778:1 -of rawvideo -o Is it this part and then output format? What do I have to add to save to uncompressed avi? Did you try with MXF- should be faster. Thanks, Andrew Last edited by kolak; 27th November 2010 at 12:45. |
|
27th November 2010, 13:16 | #15 | Link | ||||
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
Quote:
Quote:
Quote:
If you want another raw format you need to modify the 'format=i420' part,... If you want the raw video inside an avi you need to change '-of rawvideo' to '-of avi' and "-o -" to " -o test.avi" (if you remove '-vf scale,format=i420' output should be "UYVY") Quote:
Cu Selur |
||||
27th November 2010, 13:27 | #16 | Link | |
Registered User
Join Date: Jun 2005
Posts: 278
|
Quote:
I don't want to change that file since other stuff uses it as well, and if anything it should use mp_msg instead of printf, but I changed it so it will only be printed if you use -v, which for your purpose should have the same effect. |
|
27th November 2010, 13:43 | #18 | Link | |
Registered User
Join Date: Nov 2004
Location: Poland
Posts: 2,843
|
Quote:
MXF samples: http://opencubetech.com/page47/ no DNxHD sample Andrew Last edited by kolak; 27th November 2010 at 13:50. |
|
27th November 2010, 14:06 | #19 | Link |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,277
|
Yup, downloaded these samples and couldn't playback some them:
op1a-jpeg2k-wave_hd.mxf -> no video - missing 'm3jp2k32.dll', the one in mplayers package was a expired trial so I deleted it some time back op1a-mpeg2-wave_hd.mxf -> no video - [mxf @ 01d5d5d0] only frame wrapped mappings are correctly supported op1a-up-wave_hd.mxf -> no video - Cannot find codec matching selected -vo and video format 0x18524742. op2b-mpeg2-wave_hd.mxf -> broken output - Slices start in the middle! xdcam-pal-d10-imx30.mxf -> broken output - Slices start in the middle! xdcam-pal-d10-imx50.mxf -> broken output - Slices start in the middle! dvcpro25\CONTENTS\VIDEO\000002.MXF" [mxf @ 01bd0fe0] only frame wrapped mappings are correctly supported [mxf @ 01bd0fe0] material track 3: no corresponding source package found [mxf @ 01bd0fe0] material track 4: no corresponding source package found [mxf @ 01bd0fe0] material track 5: no corresponding source package found [mxf @ 01bd0fe0] material track 6: no corresponding source package found dvcpro50\CONTENTS\VIDEO\000001.MXF" [mxf @ 01bd0fe0] only frame wrapped mappings are correctly supported [mxf @ 01bd0fe0] material track 3: no corresponding source package found [mxf @ 01bd0fe0] material track 4: no corresponding source package found [mxf @ 01bd0fe0] material track 5: no corresponding source package found [mxf @ 01bd0fe0] material track 6: no corresponding source package found the imx files will probably work with the QuickTime IMX Codec for Windows (400€/ 500$) the dvpro files should work with the Quicktime DVCPRO HD Decoder (250,00€/350.00$) the jpeg2k should work with the Morgan M-JPEG codec V3 ($20/20€) no clue about the wave_hd files But for the moment, I'm happy with mov(DNxHD) decoding. :P Cu Selur Last edited by Selur; 27th November 2010 at 14:31. |
27th November 2010, 14:40 | #20 | Link | |
Registered User
Join Date: Nov 2004
Location: Poland
Posts: 2,843
|
Quote:
Yes - you need decoders for DVCPROHD etc. Andrew |
|
|
|