changeset 32517:a3ca3a1ae291

document how to add ffmpeg codecs in codecs.conf.txt
author compn
date Mon, 08 Nov 2010 00:28:28 +0000
parents d12d304b4dbd
children f0b00ea25de3
files DOCS/tech/codecs.conf.txt
diffstat 1 files changed, 39 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/DOCS/tech/codecs.conf.txt	Sun Nov 07 21:48:12 2010 +0000
+++ b/DOCS/tech/codecs.conf.txt	Mon Nov 08 00:28:28 2010 +0000
@@ -167,4 +167,43 @@
 The "flags" keywords identifies any additional abilities of this
 codec. Currently, seekable is the only supported flag.
 
+
+Adding FFmpeg Codecs
+-------------------
+example codec:
+
+videocodec ffmdec
+  info "FFmpeg Sony PlayStation MDEC (Motion DECoder)"
+  status working
+  fourcc MDEC ; internal MPlayer FourCC
+  driver ffmpeg
+  dll mdec
+  out YV12
+
+the "videocodec" name should start with ff to differentiate it from other
+libraries or binary codecs.
+
+the "dll" name comes from the codec source file or the libavcodec/allcodecs.c
+file.
+
+the "out" colorspace can be found in the codec source file in the PIX_FMT
+struct. Note that some codecs may have several pix_fmt structs.
+the pix_fmt can be converted to the mplayer "out" format by reading
+the fmt_conversion.c file.
+
+libmpdemux/mp_taglists.c
+--------------
+if the lavf demuxer does not pass on a fourcc (mostly video game formats
+or other containers that do not support isom/fourcc tags). you will have to
+make one based on the ffmpeg codec id. Note that it is a good idea to mark
+any fourcc you create as ' ; internal MPlayer FourCC'. just in case another
+codec uses that fourcc, you can easily change the internal one. also this
+will stop other projects from thinking your made up tag is a real fourcc
+found in the wild.
+
+libmpdemux/demuxer.c
+--------------
+some audio codecs require a parser, you can see which ones do
+by reading the parsers section in libavcodec/allcodecs.c
+
 EOF