OpenCV is not Working with 300 fps camera

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

OpenCV is not Working with 300 fps camera

Somnath Mukherjee
    HI
           I am working with a very high speed camera greater than 300 fps
, My architecture is like as given below, but inshow () does not working

Camera Capture  by Different API  ---->>>>>  Grab Image ------->> Convert
Image Structure to cv::Mat---------> imshow() and waitkey() calling to show
the Mat..
everything is working , only the last part is not working , whenever
calling the last part the program crash in every time

Please suggest me any alternative solution for this , I think camera is
capturing frame more than 300 fps which is not support by imshow()











   Thanks & Regards
  Somnath Mukherjee
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: OpenCV is not Working with 300 fps camera

rtotop
Have you tried a parallelized solution such as the one mentioned in this post https://www.pyimagesearch.com/2015/12/21/increasing-webcam-fps-with-python-and-opencv/ (example shown with Python, but there should be some equivalent in C++ with CUDA)?

 Some of the solutions mentioned in this post https://stackoverflow.com/questions/21759995/opencv-imshow-at-120-fps may be of use, including upgrading your hardware and utilizing OpenGL support in OpenCV. According to the docs https://docs.opencv.org/3.2.0/df/d24/group__highgui__opengl.html, imshow() is indeed supported by OpenGL.
Reply | Threaded
Open this post in threaded view
|

Re: OpenCV is not Working with 300 fps camera

rtotop
How did you validate that the either the imshow() or waitkey() functions are crashing your program, and not something immediately before (but after conversion to cv::Mat) or immediately after?  This may be an issue with another part of the code if there is any more going on.

 Also, are there any other processes running in the background that may conflict with highgui? Some frameworks (ROS, other software which use older versions of GTK, etc.) are known to be incompatible with the highgui module in OpenCV.
Reply | Threaded
Open this post in threaded view
|

Re: OpenCV is not Working with 300 fps camera

Somnath Mukherjee
Hi  Thanks for replying, I debug the code line by line and tested it , its
still happened for imshow() and waitKey() functionalities, even when I
comment this section and write the image through imwrite() then its work
nicely and save the image in current directory .




   Thanks & Regards
  Somnath Mukherjee
[hidden email]


On Tue, Dec 4, 2018 at 12:37 PM [hidden email] [OpenCV] <
[hidden email]> wrote:

>
>
> How did you validate that the either the imshow() or waitkey() functions
> are crashing your program, and not something immediately before (but after
> conversion to cv::Mat) or immediately after?  This may be an issue with
> another part of the code if there is any more going on.
>
> Also, are there any other processes running in the background that may
> conflict with highgui? Some frameworks (ROS, other software which use older
> versions of GTK, etc.) are known to be incompatible with the highgui module
> in OpenCV.
>
>
Reply | Threaded
Open this post in threaded view
|

Re: OpenCV is not Working with 300 fps camera

Somnath Mukherjee
HI
    Finally I have solved this problem by applying multithread application,
thanks for looking into this.



   Thanks & Regards
  Somnath Mukherjee
[hidden email]


On Tue, Dec 4, 2018 at 12:43 PM Somnath Mukherjee <
[hidden email]> wrote:

> Hi  Thanks for replying, I debug the code line by line and tested it , its
> still happened for imshow() and waitKey() functionalities, even when I
> comment this section and write the image through imwrite() then its work
> nicely and save the image in current directory .
>
>
>
>
>    Thanks & Regards
>   Somnath Mukherjee
> [hidden email]
>
>
> On Tue, Dec 4, 2018 at 12:37 PM [hidden email] [OpenCV] <
> [hidden email]> wrote:
>
>>
>>
>> How did you validate that the either the imshow() or waitkey() functions
>> are crashing your program, and not something immediately before (but after
>> conversion to cv::Mat) or immediately after?  This may be an issue with
>> another part of the code if there is any more going on.
>>
>> Also, are there any other processes running in the background that may
>> conflict with highgui? Some frameworks (ROS, other software which use older
>> versions of GTK, etc.) are known to be incompatible with the highgui module
>> in OpenCV.
>>
>>
>