forked from bartvdbraak/blender
CMake: Fix FFMPeg/OpenEXR issues in CMake system and possibly the others. OpenEXR can be linked in DEBUG mode on Windows using the libraries in CVS and stub.
This commit is contained in:
parent
6e4b94ff51
commit
2a0fc46266
@ -53,7 +53,7 @@ IF(WITH_QUICKTIME)
|
||||
ENDIF(WITH_QUICKTIME)
|
||||
|
||||
IF(WITH_FFMPEG)
|
||||
SET(INC ${INC} FFMPEG_INC)
|
||||
SET(INC ${INC} ${FFMPEG_INC})
|
||||
ADD_DEFINITIONS(-DWITH_FFMPEG)
|
||||
ENDIF(WITH_FFMPEG)
|
||||
|
||||
|
@ -20,8 +20,12 @@
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#if defined(_WIN32) && defined(_DEBUG) && !defined(__MINGW32__) && !defined(__CYGWIN__)
|
||||
#include <stdint.h>
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <ffmpeg/avformat.h>
|
||||
#include <ffmpeg/avcodec.h>
|
||||
#include <ffmpeg/rational.h>
|
||||
@ -33,6 +37,10 @@
|
||||
#define FFMPEG_CODEC_TIME_BASE 1
|
||||
#endif
|
||||
|
||||
#if defined(WIN32) && (!(defined snprintf))
|
||||
#define snprintf _snprintf
|
||||
#endif
|
||||
|
||||
#include "BKE_writeffmpeg.h"
|
||||
|
||||
#include "MEM_guardedalloc.h"
|
||||
@ -471,7 +479,7 @@ static AVStream* alloc_audio_stream(int codec_id, AVFormatContext* of)
|
||||
}
|
||||
/* essential functions -- start, append, end */
|
||||
|
||||
static void start_ffmpeg_impl(RenderData *rd, int rectx, int recty)
|
||||
void start_ffmpeg_impl(struct RenderData *rd, int rectx, int recty)
|
||||
{
|
||||
/* Handle to the output file */
|
||||
AVFormatContext* of;
|
||||
|
@ -53,7 +53,7 @@ IF(WITH_QUICKTIME)
|
||||
ENDIF(WITH_QUICKTIME)
|
||||
|
||||
IF(WITH_FFMPEG)
|
||||
SET(INC ${INC} FFMPEG_INC)
|
||||
SET(INC ${INC} ${FFMPEG_INC})
|
||||
ADD_DEFINITIONS(-DWITH_FFMPEG)
|
||||
ENDIF(WITH_FFMPEG)
|
||||
|
||||
|
@ -35,6 +35,14 @@
|
||||
|
||||
extern "C"
|
||||
{
|
||||
|
||||
// The following prevents a linking error in debug mode for MSVC using the libs in CVS
|
||||
#if defined(_WIN32) && defined(_DEBUG) && !defined(__MINGW32__) && !defined(__CYGWIN__)
|
||||
_CRTIMP void __cdecl _invalid_parameter_noinfo(void)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
#include "MEM_guardedalloc.h"
|
||||
|
||||
#include "BLI_blenlib.h"
|
||||
|
@ -49,5 +49,9 @@ IF(WITH_OPENEXR)
|
||||
ADD_DEFINITIONS(-DWITH_OPENEXR)
|
||||
ENDIF(WITH_OPENEXR)
|
||||
|
||||
IF(WITH_FFMPEG)
|
||||
ADD_DEFINITIONS(-DWITH_FFMPEG)
|
||||
ENDIF(WITH_FFMPEG)
|
||||
|
||||
BLENDERLIB_NOLIST(blender_python "${SRC}" "${INC}")
|
||||
#env.BlenderLib ( libname='blender_python', sources = Split(sources), includes = Split(incs), defines = defs, libtype=['core','game2'], priority = [60,115] )
|
||||
|
@ -58,7 +58,7 @@ IF(WITH_QUICKTIME)
|
||||
ENDIF(WITH_QUICKTIME)
|
||||
|
||||
IF(WITH_FFMPEG)
|
||||
SET(INC ${INC} FFMPEG_INC)
|
||||
SET(INC ${INC} ${FFMPEG_INC})
|
||||
ADD_DEFINITIONS(-DWITH_FFMPEG)
|
||||
ENDIF(WITH_FFMPEG)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user