mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-21 06:23:53 +00:00
Fix compilation of the FFmpeg decoder
This commit is contained in:
parent
e48745b68e
commit
9a48002025
2 changed files with 15 additions and 6 deletions
|
@ -126,19 +126,22 @@ set(OPENMW_LIBS ${MANGLE_ALL} ${OENGINE_ALL})
|
|||
set(OPENMW_LIBS_HEADER)
|
||||
|
||||
# Sound setup
|
||||
set(SOUND_INPUT_INCLUDES "")
|
||||
set(SOUND_INPUT_LIBRARY "")
|
||||
set(SOUND_DEFINE "")
|
||||
if (USE_FFMPEG)
|
||||
find_package(FFMPEG REQUIRED)
|
||||
set(SOUND_INPUT_INCLUDES ${FFMPEG_INCLUDE_DIR})
|
||||
set(SOUND_INPUT_LIBRARY ${FFMPEG_LIBRARIES})
|
||||
set(SOUND_DEFINE -DOPENMW_USE_FFMPEG)
|
||||
set(SOUND_INPUT_INCLUDES ${SOUND_INPUT_INCLUDES} ${FFMPEG_INCLUDE_DIR})
|
||||
set(SOUND_INPUT_LIBRARY ${SOUND_INPUT_LIBRARY} ${FFMPEG_LIBRARIES})
|
||||
set(SOUND_DEFINE ${SOUND_DEFINE} -DOPENMW_USE_FFMPEG)
|
||||
endif (USE_FFMPEG)
|
||||
|
||||
if (USE_MPG123)
|
||||
find_package(MPG123 REQUIRED)
|
||||
find_package(SNDFILE REQUIRED)
|
||||
set(SOUND_INPUT_INCLUDES ${MPG123_INCLUDE_DIR} ${SNDFILE_INCLUDE_DIR})
|
||||
set(SOUND_INPUT_LIBRARY ${MPG123_LIBRARY} ${SNDFILE_LIBRARY})
|
||||
set(SOUND_DEFINE -DOPENMW_USE_MPG123)
|
||||
set(SOUND_INPUT_INCLUDES ${SOUND_INPUT_INCLUDES} ${MPG123_INCLUDE_DIR} ${SNDFILE_INCLUDE_DIR})
|
||||
set(SOUND_INPUT_LIBRARY ${SOUND_INPUT_LIBRARY} ${MPG123_LIBRARY} ${SNDFILE_LIBRARY})
|
||||
set(SOUND_DEFINE ${SOUND_DEFINE} -DOPENMW_USE_MPG123)
|
||||
endif (USE_MPG123)
|
||||
|
||||
# Platform specific
|
||||
|
|
|
@ -3,6 +3,11 @@
|
|||
|
||||
#include <string>
|
||||
|
||||
// FIXME: This can't be right? The headers refuse to build without UINT64_C,
|
||||
// which only gets defined in stdint.h in either C99 mode or with this macro
|
||||
// defined...
|
||||
#define __STDC_CONSTANT_MACROS
|
||||
#include <stdint.h>
|
||||
extern "C"
|
||||
{
|
||||
#include <avcodec.h>
|
||||
|
@ -25,6 +30,7 @@ namespace MWSound
|
|||
virtual void rewind();
|
||||
|
||||
FFmpeg_Decoder();
|
||||
public:
|
||||
virtual ~FFmpeg_Decoder();
|
||||
|
||||
friend class SoundManager;
|
||||
|
|
Loading…
Reference in a new issue