]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/thread.h
avformat: Switch AVChapter.id to 64bits
[ffmpeg] / libavcodec / thread.h
index 540135fbc922ea3e59daaed095cdb520ef9349ea..413196269f59dc007b3db4a0f36e8c267ecce3b0 100644 (file)
@@ -96,6 +96,7 @@ void ff_thread_report_progress(ThreadFrame *f, int progress, int field);
  */
 void ff_thread_await_progress(ThreadFrame *f, int progress, int field);
 
+#if FF_API_THREAD_SAFE_CALLBACKS
 /**
  * Wrapper around get_format() for frame-multithreaded codecs.
  * Call this function instead of avctx->get_format().
@@ -105,6 +106,9 @@ void ff_thread_await_progress(ThreadFrame *f, int progress, int field);
  * @param fmt The list of available formats.
  */
 enum AVPixelFormat ff_thread_get_format(AVCodecContext *avctx, const enum AVPixelFormat *fmt);
+#else
+#define ff_thread_get_format ff_get_format
+#endif
 
 /**
  * Wrapper around get_buffer() for frame-multithreaded codecs.
@@ -129,7 +133,7 @@ int ff_thread_get_buffer(AVCodecContext *avctx, ThreadFrame *f, int flags);
  */
 void ff_thread_release_buffer(AVCodecContext *avctx, ThreadFrame *f);
 
-int ff_thread_ref_frame(ThreadFrame *dst, ThreadFrame *src);
+int ff_thread_ref_frame(ThreadFrame *dst, const ThreadFrame *src);
 
 int ff_thread_init(AVCodecContext *s);
 int ff_slice_thread_execute_with_mainfunc(AVCodecContext *avctx,