I try to load a tiff image with ImageAccessCV.
But if I try to compile this simple src code here,
I have this error:
/main.cpp|15|undefined reference to `ImageAccessCV::LoadFromFile(CByteImage*, char const*)'|
#include<iostream>#include"Image/ImageProcessor.h"#include"Image/ImageProcessorCV.h"#include"Image/ImageAccessCV.h"#include"Image/ByteImage.h"usingnamespacestd;intmain(intargc,char**args){CByteImageimage;if(!ImageAccessCV::LoadFromFile(&image,"tool_scene.tiff")){printf("Fehler: konnte Bild nicht öffnen \n");return1;}//convert color image to grayCByteImagegray_image(image.width,image.height,CByteImage::eGrayScale);ImageProcessor::ConvertImage(&image,&gray_image);gray_image.SaveToFile("output1.bmp");return0;}
I've seen this code on en example… but it's won't work.
What do I wrong here?
I try to compiling under ubuntu 9.10 with g++
Thanks for your help! :)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
I try to load a tiff image with ImageAccessCV.
But if I try to compile this simple src code here,
I have this error:
/main.cpp|15|undefined reference to `ImageAccessCV::LoadFromFile(CByteImage*, char const*)'|
I've seen this code on en example… but it's won't work.
What do I wrong here?
I try to compiling under ubuntu 9.10 with g++
Thanks for your help! :)
Hi,
you must set USE_OPENCV = 1 and USE_OPENCV_HIGHGUI = 1 in IVT/src/Makefile.base. Then run make in IVT/src. Then compile your application.
Pedram
Hi,
I forgott to say that I have set this variables. After changing this
variables I have run this commands in /Ivt/src :
>make clean
>make
but it's not working. And make seems running without error..
I've solved it.
I simple forgett to add the two new libs generated by make to the project proberties
upsserla.. ;)
Thanks!