diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-10-14 11:33:28 +0200 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-10-22 13:32:15 +0200 |
commit | dca23ffbc7568c9af5c5fbaa86e6a0761ecae50c (patch) | |
tree | af7dc53eee966b592c4d01c17675b51e4d293dc2 /libavcodec/imgconvert.c | |
parent | 3ee2c60cc296eee3f63d7b5fee9b4332eeeac9fa (diff) | |
download | ffmpeg-dca23ffbc7568c9af5c5fbaa86e6a0761ecae50c.tar.gz |
lavc: Deprecate AVPicture structure and related functions
This structure served as a bridge between data pointers and frames,
but it suffers from several limitations:
- it is not refcounted and data must be copied to every time
- it cannot be expanded without ABI break due to being used on the stack
- its functions are just wrappers to imgutils which add a layer of
unneeded indirection, and maintenance burden
- it allows hacks like embedding uncompressed data in packets
- its use is often confusing to our users
AVFrame provides a much better API, and, if a full blown frame is not
needed, it is just as simple and more straightfoward to use data and
linesize arrays directly.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavcodec/imgconvert.c')
-rw-r--r-- | libavcodec/imgconvert.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/imgconvert.c b/libavcodec/imgconvert.c index 53e7df810a..55a9213a92 100644 --- a/libavcodec/imgconvert.c +++ b/libavcodec/imgconvert.c @@ -252,6 +252,7 @@ static inline int is_yuv_planar(const AVPixFmtDescriptor *desc) (desc->flags & AV_PIX_FMT_FLAG_PLANAR)); } +#if FF_API_AVPICTURE int av_picture_crop(AVPicture *dst, const AVPicture *src, enum AVPixelFormat pix_fmt, int top_band, int left_band) { @@ -335,3 +336,4 @@ int av_picture_pad(AVPicture *dst, const AVPicture *src, int height, int width, } return 0; } +#endif /* FF_API_AVPICTURE */ |