streamts.cpp: Try to fix LIBAVFORMAT_VERSION_INT comparsion

This commit is contained in:
2024-12-22 16:37:37 +01:00
parent 87c7ff4fd3
commit 19dbe692f8
2 changed files with 4 additions and 4 deletions

View File

@@ -113,7 +113,7 @@ bool CStreamInstance::Stop()
running = false; running = false;
return (OpenThreads::Thread::join() == 0); return (OpenThreads::Thread::join() == 0);
} }
#if LIBAVFORMAT_VERSION_INT > AV_VERSION_INT(59, 27, 100) #if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(61, 1, 100)
bool CStreamInstance::Send(ssize_t r, const unsigned char *_buf) bool CStreamInstance::Send(ssize_t r, const unsigned char *_buf)
#else #else
bool CStreamInstance::Send(ssize_t r, unsigned char * _buf) bool CStreamInstance::Send(ssize_t r, unsigned char * _buf)
@@ -820,7 +820,7 @@ CStreamStream::~CStreamStream()
Close(); Close();
} }
#if LIBAVFORMAT_VERSION_INT > AV_VERSION_INT(59, 27, 100) #if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(61, 1, 100)
int CStreamStream::write_packet(void *opaque, const uint8_t *buffer, int buf_size) int CStreamStream::write_packet(void *opaque, const uint8_t *buffer, int buf_size)
#else #else
int CStreamStream::write_packet(void *opaque, uint8_t *buffer, int buf_size) int CStreamStream::write_packet(void *opaque, uint8_t *buffer, int buf_size)

View File

@@ -54,7 +54,7 @@ class CStreamInstance : public OpenThreads::Thread
t_channel_id channel_id; t_channel_id channel_id;
stream_pids_t pids; stream_pids_t pids;
stream_fds_t fds; stream_fds_t fds;
#if LIBAVFORMAT_VERSION_INT > AV_VERSION_INT(59, 27, 100) #if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(61, 1, 100)
virtual bool Send(ssize_t r, const unsigned char * _buf = NULL); virtual bool Send(ssize_t r, const unsigned char * _buf = NULL);
#else #else
virtual bool Send(ssize_t r, unsigned char * _buf = NULL); virtual bool Send(ssize_t r, unsigned char * _buf = NULL);
@@ -102,7 +102,7 @@ class CStreamStream : public CStreamInstance
bool Stop(); bool Stop();
static int Interrupt(void * data); static int Interrupt(void * data);
#if LIBAVFORMAT_VERSION_INT > AV_VERSION_INT(59, 27, 100) #if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(61, 1, 100)
static int write_packet(void *opaque, const uint8_t *buffer, int buf_size); static int write_packet(void *opaque, const uint8_t *buffer, int buf_size);
#else #else
static int write_packet(void *opaque, uint8_t *buffer, int buf_size); static int write_packet(void *opaque, uint8_t *buffer, int buf_size);