mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-07 23:45:12 +00:00
macos: fix build for arm64
Adds arm64 branches to some x86 specific code and modifies some casting logic to make Clang happy
This commit is contained in:
parent
219ddf3e11
commit
e761b3235c
5 changed files with 20 additions and 5 deletions
|
|
@ -166,7 +166,7 @@ namespace utils
|
|||
struct scoped_av
|
||||
{
|
||||
AVFormatContext* format = nullptr;
|
||||
AVCodec* codec = nullptr;
|
||||
const AVCodec* codec = nullptr;
|
||||
AVCodecContext* context = nullptr;
|
||||
AVFrame* frame = nullptr;
|
||||
SwrContext* swr = nullptr;
|
||||
|
|
@ -180,8 +180,8 @@ namespace utils
|
|||
swr_free(&swr);
|
||||
if (context)
|
||||
avcodec_close(context);
|
||||
if (codec)
|
||||
av_free(codec);
|
||||
// AVCodec is managed by libavformat, no need to free it
|
||||
// see: https://stackoverflow.com/a/18047320
|
||||
if (format)
|
||||
avformat_free_context(format);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue