mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2026-09-05 20:04:13 +00:00
Fix video decoding on newer versions of FFmpeg (#155)
Fixes video decoding issues and enables compatibility with newer versions of FFmpeg. Co-authored-by: MaranBr <maranbr@outlook.com> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/155
This commit is contained in:
@@ -22,7 +22,7 @@ extern "C" {
|
||||
#include <libavcodec/avcodec.h>
|
||||
#include <libavutil/opt.h>
|
||||
#ifndef ANDROID
|
||||
#include <libavcodec/codec.h>
|
||||
#include <libavcodec/codec_internal.h>
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__) || defined(__clang__)
|
||||
@@ -106,7 +106,11 @@ public:
|
||||
}
|
||||
|
||||
bool IsInterlaced() const {
|
||||
return m_frame->interlaced_frame != 0;
|
||||
#if defined(FF_API_INTERLACED_FRAME) || LIBAVUTIL_VERSION_MAJOR >= 59
|
||||
return m_frame->flags & AV_FRAME_FLAG_INTERLACED;
|
||||
#else
|
||||
return m_frame->interlaced_frame;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool IsHardwareDecoded() const {
|
||||
|
||||
Reference in New Issue
Block a user