Hardware:
A linux compatible webcam (USB or a Firewire)
Software:
Fedora Core 9 (i386)
Also compatible with Fedora Core 10 (i386)
Installation instructions:
- I’m asuming you have a clean installation of Fedora Core 9 (with Software Development packages) installed.
- First install all dependencies:
su – yum install cmake svn opencv opencv-devel freeglut freeglut-devel fftw2 fftw2-devel libXmu libXmu-devel exit
- Now to install osc, checkout the latest version on the SVN:
cd ~ mkdir multitouch cd multitouch mkdir oscpack cd oscpack svn co https://www.smartelectronix.com:9000/repos/osc/oscpack/trunk/ .
(or you could get the source oscpack_1_0_2.zip)
Unfortuntately rev. 76 of oscpack is not compatible with gcc 4.3. Before running make it is required to make some fixes in the sourcecode. Use your favorite editor and edit the following files:
tests/OscUnitTests.cpp
– add #include <cstring>osc/OscPrintReceivedElements.cpp
– add #include <cstring>tests/OscSendTests.cpp
– add #include <cstdlib>tests/OscReceiveTest.cpp
– add #include <cstdlib>examples/OscDump.cpp
– add #include <cstring>
– add #include <cstdlib>Next type the following commands:
cd oscpack/ make su – cd /home/username/multitouch/oscpack make install exit
- Now compile touchlib:
cd /home/username/multitouch mkdir touchlib cd touchlib svn checkout http://touchlib.googlecode.com/svn/trunk/ . cmake . (or “ccmake .” if you want a GUI) make
- Touchlib should now be ready to use.
More information:
http://gcc.gnu.org/gcc-4.3/porting_to.html
Known bugs:
Due a problem with the OpenCV library in Linux, Touchlib might crash after a few minutes.
A fix for rev.393 is available here.
A mirror to the file: Touchlib race condition fix rev.393
(old)
A fix for rev.90 is available in here.
A mirror to the file: Touchlib race condition fix rev.90
(Optional) Import the touchlib project in Eclipse (3.4+ Ganymeade):
- Open up a console and go to the touchlib directory
- Type:
cmake -G”Eclipse CDT4 – Unix Makefiles” .
- Two new files should be added to the directory (.project and .cproject).
- Launch Eclipse.
- Import the project using File -> Import…
- Select General -> Existing projects into workspace.
- Browse to your touchlib directory.
- After selecting the directory, the project should be visible in the overview.
- Keep “Copy projects into workspace” unchecked.
- Done!
6 responses
Hello! very valuable info , but unfortunately I can’t get any signal from my camera to any of the demo applications (they compile fine). I use Fedora 10. At /dev there’s nothing like cam0 or similar that is requested at the CvCaptureFilter.cpp . I ‘ve been experimenting with fw0 etc which do appear at the /dev folder. Any ideas? Thanks in advance!
Hi, Am trying to compile touchlib but I get this error in fc7: (something to do with /usr/lib/libgtk-x11-2.0.so.0 ??? /usr/lib/libgtk-x11-2.0.so.0: undefined reference to `g_bookmark_file_get_applications’ collect2: ld returned 1 exit status make[2]: ** [src/configapp] Error 1 make[1]: ** [src/CMakeFiles/configapp.dir/all] Error 2 make: *** [all] Error 2 Any suggestions ?? Many thanks.
Do I need to designate path when im compiling?
[root@localhost js]# gcc -I/usr/local/opencv/include/opencv -L/usr/local/opencv/lib -I/home/SimJS/multitouch/touchlib/include -L/home/SimJS/multitouch/touchlib/lib -lcv -lhighgui -lstdc++ touch.cpp -o touch /tmp/cc07Cjyt.o: In function
main’: touch.cpp:(.text+0x84): undefined reference to
touchlib::TouchScreenDevice::getTouchScreen()’ collect2: ld returned 1 exit status i try to compile .. why occur this error? please help me ã… ã…in GNU/linux ubuntu 9.04 at “make install” i get this error (don’t pay attention to the spanish things): g++ -shared -Wl,-soname,liboscpack.so -o liboscpack.so.1.0.2 ./ip/IpEndpointName.o ./ip/posix/NetworkingUtils.o ./ip/posix/UdpSocket.o ./osc/OscOutboundPacketStream.o ./osc/OscPrintReceivedElements.o ./osc/OscReceivedElements.o ./osc/OscTypes.o -lc -fPIC /usr/bin/ld: ./ip/IpEndpointName.o: relocation R_X86_64_32 against `a local symbol’ can not be used when making a shared object; recompile with -fPIC ./ip/IpEndpointName.o: could not read symbols: Bad value collect2: ld devolvió el estado de salida 1 make: *** [liboscpack.so.1.0.2] Error 1 i fix it editing the makefile like this change this line COPTS = -Wall -O3 for this one COPTS = -Wall -O3 -fPIC i hope help someone thanks for this great tutorial!
in GNU/linux fedora 12 at “cmake .” CMake Error: The following variables are used in this project, but they are set to NOTFOUND. Please set them or make sure they are set and tested correctly in the CMake files: GLUT_Xi_LIBRARY (ADVANCED) linked by target “configapp” in directory /home/marz/multitouch/src linked by target “smoke” in directory /home/marz/multitouch/demos/smoke – Configuring incomplete, errors occurred! I fix it installing the libXi-devel.i686 Awesome work