]> git.sesse.net Git - ffmpeg/commitdiff
vdpau: deprecate av_vdpau_get_profile()
authorRémi Denis-Courmont <remi@remlab.net>
Sun, 27 Sep 2015 10:49:09 +0000 (13:49 +0300)
committerAnton Khirnov <anton@khirnov.net>
Mon, 28 Sep 2015 07:45:58 +0000 (09:45 +0200)
This function can intrinsically not deal with codec profile fallback
(for H.264 Constrained Baseline especially), and was made redundant
by av_vdpau_bind_context().

Signed-off-by: Anton Khirnov <anton@khirnov.net>
libavcodec/vdpau.h
libavcodec/version.h

index 4e5c3518e3e0e6506bc574f01c683a8df0e2d7bc..d25ee1ce17fbb5d18b6e091cf5df17b3e1074b43 100644 (file)
@@ -177,10 +177,13 @@ int av_vdpau_get_surface_parameters(AVCodecContext *avctx, VdpChromaType *type,
  */
 AVVDPAUContext *av_vdpau_alloc_context(void);
 
+#if FF_API_VDPAU_PROFILE
 /**
  * Get a decoder profile that should be used for initializing a VDPAU decoder.
  * Should be called from the AVCodecContext.get_format() callback.
  *
+ * @deprecated Use av_vdpau_bind_context() instead.
+ *
  * @param avctx the codec context being used for decoding the stream
  * @param profile a pointer into which the result will be written on success.
  *                The contents of profile are undefined if this function returns
@@ -188,7 +191,9 @@ AVVDPAUContext *av_vdpau_alloc_context(void);
  *
  * @return 0 on success (non-negative), a negative AVERROR on failure.
  */
+attribute_deprecated
 int av_vdpau_get_profile(AVCodecContext *avctx, VdpDecoderProfile *profile);
+#endif
 
 #if FF_API_CAP_VDPAU
 /** @brief The videoSurface is used for rendering. */
index ecd6e1d1eae5ba5f553198530a117dabd351fed8..c704d44b7aae8692fb77cf5083b430c03c8f6e66 100644 (file)
 #ifndef FF_API_SIDEDATA_ONLY_PKT
 #define FF_API_SIDEDATA_ONLY_PKT (LIBAVCODEC_VERSION_MAJOR < 59)
 #endif
+#ifndef FF_API_VDPAU_PROFILE
+#define FF_API_VDPAU_PROFILE     (LIBAVCODEC_VERSION_MAJOR < 59)
+#endif
 
 #endif /* AVCODEC_VERSION_H */