about
本文参考了:
OpenCV 3.1.0 Medio I/O官方文档
propid接口
propId: Property identifier
virtual double cv::VideoCapture::get(int propId) const
virtual bool cv::VideoCapture::set(int propId, double value)
enum {
cv::CAP_PROP_POS_MSEC =0,
cv::CAP_PROP_POS_FRAMES =1,
cv::CAP_PROP_POS_AVI_RATIO =2,
cv::CAP_PROP_FRAME_WIDTH =3,
cv::CAP_PROP_FRAME_HEIGHT =4,
cv::CAP_PROP_FPS =5,
cv::CAP_PROP_FOURCC =6,
cv::CAP_PROP_FRAME_COUNT =7,
cv::CAP_PROP_FORMAT =8,
cv::CAP_PROP_MODE =9,
cv::CAP_PROP_BRIGHTNESS =10,
cv::CAP_PROP_CONTRAST =11,
cv::CAP_PROP_SATURATION =12,
cv::CAP_PROP_HUE =13,
cv::CAP_PROP_GAIN =14,
cv::CAP_PROP_EXPOSURE =15,
cv::CAP_PROP_CONVERT_RGB =16,
cv::CAP_PROP_WHITE_BALANCE_BLUE_U =17,
cv::CAP_PROP_RECTIFICATION =18,
...
}
- 参数说明
CAP_PROP_POS_MSEC Current position of the video file in milliseconds or video capture timestamp.
CAP_PROP_POS_FRAMES 0-based index of the frame to be decoded/captured next.
CAP_PROP_POS_AVI_RATIO Relative position of the video file: 0 - start of the film, 1 - end of the film.
CAP_PROP_FRAME_WIDTH Width of the frames in the video stream.
CAP_PROP_FRAME_HEIGHT Height of the frames in the video stream.
CAP_PROP_FPS Frame rate.
CAP_PROP_FOURCC 4-character code of codec.
CAP_PROP_FRAME_COUNT Number of frames in the video file.
CAP_PROP_FORMAT Format of the Mat objects returned by retrieve() .
CAP_PROP_MODE Backend-specific value indicating the current capture mode.
CAP_PROP_BRIGHTNESS Brightness of the image (only for cameras).
CAP_PROP_CONTRAST Contrast of the image (only for cameras).
CAP_PROP_SATURATION Saturation of the image (only for cameras).
CAP_PROP_HUE Hue of the image (only for cameras).
CAP_PROP_GAIN Gain of the image (only for cameras).
CAP_PROP_EXPOSURE Exposure (only for cameras).
CAP_PROP_CONVERT_RGB Boolean flags indicating whether images should be converted to RGB.
CAP_PROP_WHITE_BALANCE Currently not supported
CAP_PROP_RECTIFICATION Rectification flag for stereo cameras (note: only supported by DC1394 v 2.x backend currently)