Lucklyric / qtffmpegwrapper

Automatically exported from code.google.com/p/qtffmpegwrapper
Other
0 stars 0 forks source link

compile problem #2

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I just get code from repository and try to compile QTFFmpegWrapper with this 
steps.

qmake config.pro
make

and output is

g++ -c -m64 -pipe -O2 -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 
-fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -Wall -W 
-D_REENTRANT -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED 
-I/usr/share/qt4/mkspecs/default -I. -I/usr/include/QtCore -I/usr/include/QtGui 
-I/usr/include -IQVideoEncoder -I../QTFFmpegWrapper -I. -o QVideoEncoder.o 
../QTFFmpegWrapper/QVideoEncoder.cpp
In file included from ../QTFFmpegWrapper/QVideoEncoder.cpp:17:
../QTFFmpegWrapper/QVideoEncoder.h:42: error: ISO C++ forbids declaration of 
‘uint8_t’ with no type
../QTFFmpegWrapper/QVideoEncoder.h:42: error: expected ‘;’ before ‘*’ 
token
../QTFFmpegWrapper/QVideoEncoder.h:45: error: ISO C++ forbids declaration of 
‘uint8_t’ with no type
../QTFFmpegWrapper/QVideoEncoder.h:45: error: expected ‘;’ before ‘*’ 
token
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘virtual bool 
QVideoEncoder::close()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:196: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘virtual int 
QVideoEncoder::encodeImage(const QImage&)’:
../QTFFmpegWrapper/QVideoEncoder.cpp:226: error: ‘outbuf’ was not declared 
in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:234: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘void 
QVideoEncoder::initVars()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:264: error: ‘outbuf’ was not declared 
in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:265: error: ‘picture_buf’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘bool 
QVideoEncoder::initOutputBuf()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:317: error: ‘outbuf’ was not declared 
in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:317: error: expected type-specifier before 
‘uint8_t’
../QTFFmpegWrapper/QVideoEncoder.cpp:317: error: expected ‘;’ before 
‘uint8_t’
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘void 
QVideoEncoder::freeOutputBuf()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:327: error: ‘outbuf’ was not declared 
in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:329: error: type ‘<type error>’ 
argument given to ‘delete’, expected pointer
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘bool 
QVideoEncoder::initFrame()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:341: error: ‘picture_buf’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:341: error: expected type-specifier before 
‘uint8_t’
../QTFFmpegWrapper/QVideoEncoder.cpp:341: error: expected ‘;’ before 
‘uint8_t’
../QTFFmpegWrapper/QVideoEncoder.cpp:340: warning: unused variable ‘size’
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘void 
QVideoEncoder::freeFrame()’:
../QTFFmpegWrapper/QVideoEncoder.cpp:356: error: ‘picture_buf’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:358: error: type ‘<type error>’ 
argument given to ‘delete’, expected pointer
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘bool 
QVideoEncoder::convertImage(const QImage&)’:
../QTFFmpegWrapper/QVideoEncoder.cpp:378: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp:378: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp:397: error: ‘picture_buf’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:421: error: ‘picture_buf’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp: In member function ‘bool 
QVideoEncoder::convertImage_sws(const QImage&)’:
../QTFFmpegWrapper/QVideoEncoder.cpp:472: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp:472: warning: comparison between signed 
and unsigned integer expressions
../QTFFmpegWrapper/QVideoEncoder.cpp:491: error: ‘uint8_t’ was not declared 
in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:491: error: ‘srcplanes’ was not 
declared in this scope
../QTFFmpegWrapper/QVideoEncoder.cpp:492: error: expected primary-expression 
before ‘)’ token
../QTFFmpegWrapper/QVideoEncoder.cpp:492: error: expected ‘;’ before 
‘img’
make: *** [QVideoEncoder.o] Error 1

Original issue reported on code.google.com by ozkan%az...@gtempaccount.com on 3 Jul 2010 at 9:38

GoogleCodeExporter commented 9 years ago
I added 
using namespace ffmpeg;

to the end of ffmpeg.h and it compiled. my system is 

mascix@mascix:~/tmp/qtffmpegwrapper/QTFFmpegWrapper$ cat /etc/issue
Ubuntu 10.04 LTS \n \l

Original comment by ozkan%az...@gtempaccount.com on 3 Jul 2010 at 10:18

GoogleCodeExporter commented 9 years ago
It may be safer to put ffmepg:: in front of the uint8_t.
Windows compiles also require stdint.h and inttypes.h eg from 
http://code.google.com/p/msinttypes/

Original comment by mgbeck...@gmail.com on 24 Jul 2010 at 3:21