Go to the documentation of this file.
28 if (!in_video.
openURL(video_url,
false ,
true ))
35 unsigned int nFrames = 0;
40 double fps = ++nFrames / tictac.
Tac();
50 cout <<
"Video FPS: " << in_video.
getVideoFPS() << endl;
53 std::this_thread::sleep_for(10ms);
55 if (
win.keyHit() &&
win.waitForKey() == 27)
break;
68 cout <<
"Usage: " << endl;
69 cout <<
" Open a video file: " <<
argv[0] <<
" <VIDEOFILE>" << endl;
70 cout <<
" Open an IP camera: " <<
argv[0]
71 <<
" rtsp://a.b.c.d/live.sdp" << endl;
80 catch (
const std::exception& e)
87 printf(
"Another exception!!");
void Test_FFMPEG_CaptureCamera(const std::string &video_url)
A high-performance stopwatch, with typical resolution of nanoseconds.
Contains classes for various device interfaces.
double Tac() noexcept
Stops the stopwatch.
mrpt::gui::CDisplayWindow3D::Ptr win
void Tic() noexcept
Starts the stopwatch.
This class creates a window as a graphical user interface (GUI) for displaying images to the user.
Classes for creating GUI windows for 2D and 3D visualization.
A class for storing images as grayscale or RGB bitmaps.
virtual void textOut(int x0, int y0, const std::string &str, const mrpt::img::TColor color)
Renders 2D text using bitmap fonts.
std::string exception_to_str(const std::exception &e)
Builds a nice textual representation of a nested exception, which if generated using MRPT macros (THR...
std::string std::string format(std::string_view fmt, ARGS &&... args)
void pause(const std::string &msg=std::string("Press any key to continue...")) noexcept
Shows the message "Press any key to continue" (or other custom message) to the current standard outpu...
Page generated by Doxygen 1.8.17 for MRPT 2.0.4 at Sat Jun 27 14:00:59 UTC 2020 | |