Showing posts with label fftw. Show all posts
Showing posts with label fftw. Show all posts

Thursday, 22 October 2009

FFTW finally working under Qt code

FFTW was not working the way I wanted actually and yesterday I became crazy about it, giving me a not so good day...

Today I am quite sure that the problem is solved.

I found some hints on the net that helped me...

http://www.fftw.org/faq/section3.html#linkfails

"Question 3.13. My program does not link (on Unix).

The libraries must be listed in the correct order (-lfftw3 -lm for FFTW 3.x) and after your program sources/objects. (The general rule is that if A uses B, then A must be listed before B in the link command.)."

http://www.qtcentre.org/forum/archive/index.php/t-337.html

I tried a simple example of FFTW and it worked out perfectly not giving any error either warning.

Since I am working on Qt projects, it was not so easy as writing gcc -lfftw3 -lm helloworld.c,
so I had to add a line in the .pri file.
Here the new line in bold:
LIBS += -L$${QWT_ROOT}/lib -l$${QWTLIB} \
/usr/local/lib/libfftw3.a

Thanks to the ones who helped me to realise about this (basic) problem.

More inspired than yesterday Fer

Wednesday, 21 October 2009

FFTW...

FFTW libraries downloaded,
now we have to let it work with basic spectrums and link it with my Qwt graphs.
Easy?
I'll try to tell you as soon as possible!

;)