Int main (int arg c, char * * argv)
{
If (arg c!
=2)
return -1;
CV: : namedWindow (GPU, CV: : WINDOW_OPENGL);
CV: : cuda: : setGlDevice ();
CV: : cuda: : GpuMat d_frame;
CV: : Ptr
While (true)
{
if (! D_reader - & gt; NextFrame (d_frame))
break;
CV: : imshow (" GPU, "d_frame);
If (CV: : waitKey (3) & gt; 0)
break;
}
return 0;
}
Note:
I tried to join the nvidia video decoding module to compile, results in the graphics for MX250 createVideoReader error of the machine, I guess because of the type of graphics card does not support hardware decoding, then again on another machine GTX1050ti were tested, the results createVideoReader successfully read by video, but d_reader - & gt; NextFrame (d_frame) is an error, I have to do,