Images grabbing example with the vpV4l2Grabber class.
#include <visp3/core/vpConfig.h>
#include <visp3/core/vpImage.h>
#include <visp3/sensor/vpV4l2Grabber.h>
int main()
{
#ifdef ENABLE_VISP_NAMESPACE
#endif
try {
#ifdef VISP_HAVE_V4L2
for (;;)
#endif
return EXIT_SUCCESS;
}
std::cout << "Catch an exception: " << e << std::endl;
return EXIT_FAILURE;
}
}
error that can be emitted by ViSP classes.
Class that is a wrapper over the Video4Linux2 (V4L2) driver.
void setWidth(unsigned w)
void setInput(unsigned input=vpV4l2Grabber::DEFAULT_INPUT)
void open(vpImage< unsigned char > &I)
void setHeight(unsigned h)
void setNBuffers(unsigned nbuffers)
void acquire(vpImage< unsigned char > &I)