Using IVT in QT4

Help
2010-09-05
2013-05-09
  • Nobody/Anonymous

    Hello

    I'm trying to use the libraries from IVT in QTCreator but I can't get them to compile correctly. When I try to build the project, it says:

    Undefined symbols:
    "_NewHandle", referenced from:
    CQuicktimeCapture::dataProc(ComponentInstanceRecord*, char*, long)in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::sDataProc(ComponentInstanceRecord*, char*, long, long*, long, long, short, long)in libivtvideocapture.a(quicktime_capture.o)
    "_LockPixels", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_CDSequenceEnd", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    "_SGSetChannelUsage", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_FindNextComponent", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGStartRecord", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGIdle", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    "_DecompressSequenceBegin", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    "_OpenComponent", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGSetDataRef", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGGetChannelSampleDescription", referenced from:
    CQuicktimeCapture::dataProc(ComponentInstanceRecord*, char*, long)in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::sDataProc(ComponentInstanceRecord*, char*, long, long*, long, long, short, long)in libivtvideocapture.a(quicktime_capture.o)
    "_SGSetDataProc", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_DisposeGWorld", referenced from:
    CQuicktimeCapture::CloseCamera() in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    "_SGDisposeChannel", referenced from:
    CQuicktimeCapture::CloseCamera() in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    "_GetPixBaseAddr", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    "_SGStop", referenced from:
    CQuicktimeCapture::CloseCamera() in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    CQuicktimeCapture::~CQuicktimeCapture()in libivtvideocapture.a(quicktime_capture.o)
    "_SGSetGWorld", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_GetPortPixMap", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGSetChannelBounds", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_GetComponentInfo", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_DecompressSequenceFrameS", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    "_QTNewGWorld", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGInitialize", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_SGNewChannel", referenced from:
    CQuicktimeCapture::OpenCamera() in libivtvideocapture.a(quicktime_capture.o)
    "_GetGWorldPixMap", referenced from:
    CQuicktimeCapture::CaptureImage(CByteImage**) in libivtvideocapture.a(quicktime_capture.o)
    ld: symbol(s) not found
    collect2: ld returned 1 exit status
    make: *** [Test.app/Contents/MacOS/Test] Error 1
    make: Leaving directory `/Users/jaspermaes/Test'
    Exited with code 2.
    

    But when I try to compile an example (not in QTCreator) it works.
    How can I use the libraries from ivt in my project? I'm trying to display the video stream from my webcam onto a window.

    Thanks,

    Jasper

     
  • Pedram Azad

    Pedram Azad - 2010-09-05

    Hi Jasper,

    that is only a linker error. Try to add "-framework QuickTime" to your project Makefile.

    Pedram

     
  • Nobody/Anonymous

    Ok, I've added the framework but I still get the errors…
    Do I have to Include some files in one of the source files from ivt?

     
  • Pedram Azad

    Pedram Azad - 2010-09-05

    No, you don't. As it is a linker error, it is only related to the very last call to g++, which links all object files to an executable. Could you post that final call, exactly as it is displayed in the console window? Then I can say more…

     
  • Nobody/Anonymous

    The last call before the errors is this one:

    g++ -headerpad_max_install_names -arch i386 -o Test.app/Contents/MacOS/Test main.o mainwindow.o moc_mainwindow.o   -F/Library/Frameworks -L/Library/Frameworks -L/Users/jaspermaes/Test/lib/macos -livt -livtgui -livtvideocapture -framework QuickTime -framework QtGui -framework QtCore
    
     
  • Pedram Azad

    Pedram Azad - 2010-09-05

    Try to place "-livt -livtgui -livtvideocapture" at the very and. With static libraries, the order can be relevant, which is related to dependencies. I am not sure, if it will help you case though. Does it?

     
  • Nobody/Anonymous

    It doesn't help. I've also put the 3 libraries "-livt -livtgui -livtvideocapture" in all possible orders without any succes.
    The call is now:

    g++ -headerpad_max_install_names -arch i386 -o Test.app/Contents/MacOS/Test main.o mainwindow.o moc_mainwindow.o   -F/Library/Frameworks -L/Library/Frameworks -framework QuickTime -L/Users/jaspermaes/Test/lib/macos -framework QtGui -framework QtCore -livt -livtgui -livtvideocapture
    
     
  • Nobody/Anonymous

    Now I think of something that might help, before I could compile I had to add a line to the Makefile.Base. It had something to do with the migration from QuickTime to QTKit. I had to add "COMPILER += -arch i386" after the QuickTime option. This is where I found this:
    http://sourceforge.net/tracker/?func=detail&aid=2984025&group_id=155857&atid=797454

    But when I tell the compiler to use the QTKit framework it still doesn't work.

     
  • Nobody/Anonymous

    To be helpfull to others, you must add -framework ApplicationServices to your .pro file to be able to compile. I guess this is OSX-only. Later on I will port the program to Windows and will add the details then.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks