0

I got a problem, my android stopped working.

This is my piece of program:

I'm using opencv-tutorial-mixed-processing.

case VIEW_MODE_SALIENCY:
    // input frame has  scale format
    ImgRe = inputFrame.gray();
    //ImgIm = inputFrame.();            
    ImgIm = Mat.zeros(ImgRe.size(), CvType.CV_8U);

    //List<Mat> ImgReImgIm = Arrays.asList(ImgRe, ImgIm);
    //Core.merge(ImgReImgIm, Fourier);
    Core.dft(ImgRe, tmp1, Core.DFT_REAL_OUTPUT, 0);
Arslan Ali
  • 17,418
  • 8
  • 58
  • 76
  • i tested canny, blur, gaussian, sobel, everything fine. but if i add one line code about Core.dft(src,dst); my android stopped working. could it be because the input is realtime. from inputFrame function. – arifkhumaidi Apr 11 '14 at 18:39
  • dft is looking for a floating point number so try converting it to say CV_32FC first. Also, there is a working example here: http://stackoverflow.com/questions/18123502/convert-opencv-dft-example-from-c-to-android/20807824#20807824 worth having a look at that. – timegalore Apr 11 '14 at 21:05
  • thx timegalore, your link will help me in no time. – arifkhumaidi Apr 15 '14 at 13:50
  • Thx, @timegalore, That's work for me. but after 3 second, my android stopped unexpectedly. may be because the input realtime and my processor can't handle as fast as it could be – arifkhumaidi Apr 19 '14 at 04:07
  • If you post up the revised code and the stack trace error you are getting we can have a look. – timegalore Apr 19 '14 at 18:59

0 Answers0