[FFmpeg-devel] [PATCH 6/6] doc: add API porting guide

Andreas Cadhalpun andreas.cadhalpun at googlemail.com
Sat Aug 8 13:37:37 CEST 2015


Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun at googlemail.com>
---

It would be great if someone knowledgeable would fix the TODOs.
Lacking documentation it might be better to delay removal of those APIs.

---
 doc/API-porting-guide.txt | 62 +++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 62 insertions(+)
 create mode 100644 doc/API-porting-guide.txt

diff --git a/doc/API-porting-guide.txt b/doc/API-porting-guide.txt
new file mode 100644
index 0000000..1c6e16c
--- /dev/null
+++ b/doc/API-porting-guide.txt
@@ -0,0 +1,62 @@
+FF_API_PIX_FMT:
+Rename:
+PIX_FMT_* -> AV_PIX_FMT_*
+Exceptions:
+PIX_FMT_{BE,PAL,BITSTREAM,HWACCEL,PLANAR,RGB,PSEUDOPAL,ALPHA} -> AV_PIX_FMT_FLAG_*
+
+FF_API_PIXELFORMAT:
+Rename:
+PixelFormat -> AVPixelFormat
+
+FF_API_AVCODEC_FRAME:
+Rename:
+avcodec_alloc_frame        -> av_frame_alloc
+avcodec_get_frame_defaults -> av_frame_unref
+avcodec_free_frame         -> av_frame_free
+
+FF_API_GET_BUFFER:
+Remove reget_buffer and release_buffer.
+Replace get_buffer with get_buffer2, which has an additional 'int flags' argument.
+TODO: What has to change in the custom get_buffer implementation?
+
+FF_API_AUDIOCONVERT:
+Rename:
+libavutil/audioconvert.h -> libavutil/channel_layout.h
+
+FF_API_SWS_CPU_CAPS:
+CPU capabilities are runtime detected now.
+Remove:
+SWS_CPU_CAPS_*
+
+FF_API_DEINTERLACE:
+TODO
+
+FF_API_CODEC_ID:
+Rename:
+CODEC_ID_* -> AV_CODEC_ID_*
+
+FF_API_CONTEXT_SIZE:
+Instead of providing a buffer of size av_*_size use av_*_alloc.
+
+FF_API_REQUEST_CHANNELS:
+Replace
+avctx->request_channels = N;
+with:
+avctx->request_channel_layout = av_get_default_channel_layout(N);
+
+FF_API_AVCODEC_RESAMPLE:
+TODO
+
+FF_API_DESTRUCT_PACKET:
+TODO
+
+FF_API_AVFILTERBUFFER:
+TODO
+
+FF_API_AVFILTERPAD_PUBLIC:
+Call avfilter_pad_get_name() and avfilter_pad_get_type() to access the name and type fields.
+There should be no need to access any other fields from outside of libavfilter.
+
+FF_API_VIMA_DECODER:
+Rename:
+AV_CODEC_ID_VIMA -> AV_CODEC_ID_ADPCM_VIMA
-- 
2.4.6


More information about the ffmpeg-devel mailing list