bcb调用libx264-129
在网上下了个编译好的libx264-129.dll,和相应的头文件x264_config.h,x264.h
implib成lib后加入lib到项目,然后
extern "C"
{
#include "x264.h"
#include "x264_config.h"
}
提示warning You must include stdint.h or inttypes.h before x264.h
将下载的stdint.h,inttypes.h 加入项目就是一堆的错误:
type name expected,multi declare
[解决办法]
unit1.cpp中改为:
#include "rtmp.h"
#include "rtmp_sys.h"
#include "log.h"
extern "C"
{
#include "x264.h"
}
#if !defined(_STDINT_H) && !defined(_STDINT_H_) && \
!defined(_INTTYPES_H) && !defined(_INTTYPES_H_)
# ifdef _MSC_VER
# pragma message("You must include stdint.h or inttypes.h before x264.h")
# else
# warning You must include stdint.h or inttypes.h before x264.h
# endif
#endif
#if !defined(_STDINT_H) && !defined(_STDINT_H_) && \
!defined(_INTTYPES_H) && !defined(_INTTYPES_H_)
//# ifdef _MSC_VER
//# pragma message("You must include stdint.h or inttypes.h before x264.h")
//# else
//# warning You must include stdint.h or inttypes.h before x264.h
//# endif
#endif