1
0
mirror of https://github.com/libretro/RetroArch synced 2024-07-08 12:15:49 +00:00

(ffmpeg) Attempt to make ffmpeg recording driver forwards compatible

This commit is contained in:
twinaphex 2015-10-26 00:47:45 +01:00
parent 1943ccacfb
commit 8e7477ed07
2 changed files with 24 additions and 0 deletions

View File

@ -43,6 +43,10 @@ extern "C" {
#define CORE_PREFIX(s) s
#endif
#ifndef PIX_FMT_RGB32
#define PIX_FMT_RGB32 AV_PIX_FMT_RGB32
#endif
static bool reset_triggered;
static void fallback_log(enum retro_log_level level, const char *fmt, ...)
{

View File

@ -63,6 +63,26 @@ extern "C" {
#include "../../audio/audio_utils.h"
#include "../record_driver.h"
#ifndef PIX_FMT_RGB32
#define PIX_FMT_RGB32 AV_PIX_FMT_RGB32
#endif
#ifndef PIX_FMT_BGR24
#define PIX_FMT_BGR24 AV_PIX_FMT_BGR24
#endif
#ifndef PIX_FMT_RGB565
#define PIX_FMT_RGB565 AV_PIX_FMT_RGB565
#endif
#ifndef PIX_FMT_NONE
#define PIX_FMT_NONE AV_PIX_FMT_NONE
#endif
#ifndef PixelFormat
#define PixelFormat AVPixelFormat
#endif
#if LIBAVUTIL_VERSION_INT <= AV_VERSION_INT(52, 9, 0)
#define av_frame_alloc avcodec_alloc_frame
#define av_frame_free avcodec_free_frame