#[repr(i32)]pub enum VideoWriterProperties {
Show 14 variants
VIDEOWRITER_PROP_QUALITY = 1,
VIDEOWRITER_PROP_FRAMEBYTES = 2,
VIDEOWRITER_PROP_NSTRIPES = 3,
VIDEOWRITER_PROP_IS_COLOR = 4,
VIDEOWRITER_PROP_DEPTH = 5,
VIDEOWRITER_PROP_HW_ACCELERATION = 6,
VIDEOWRITER_PROP_HW_DEVICE = 7,
VIDEOWRITER_PROP_HW_ACCELERATION_USE_OPENCL = 8,
VIDEOWRITER_PROP_RAW_VIDEO = 9,
VIDEOWRITER_PROP_KEY_INTERVAL = 10,
VIDEOWRITER_PROP_KEY_FLAG = 11,
VIDEOWRITER_PROP_PTS = 12,
VIDEOWRITER_PROP_DTS_DELAY = 13,
CV__VIDEOWRITER_PROP_LATEST = 14,
}Expand description
Variants§
VIDEOWRITER_PROP_QUALITY = 1
Current quality (0..100%) of the encoded videostream. Can be adjusted dynamically in some codecs.
VIDEOWRITER_PROP_FRAMEBYTES = 2
(Read-only): Size of just encoded video frame. Note that the encoding order may be different from representation order.
VIDEOWRITER_PROP_NSTRIPES = 3
Number of stripes for parallel encoding. -1 for auto detection.
VIDEOWRITER_PROP_IS_COLOR = 4
If it is not zero, the encoder will expect and encode color frames, otherwise it will work with grayscale frames.
VIDEOWRITER_PROP_DEPTH = 5
Defaults to \ref CV_8U.
VIDEOWRITER_PROP_HW_ACCELERATION = 6
(open-only) Hardware acceleration type (see #VideoAccelerationType). Setting supported only via params parameter in VideoWriter constructor / .open() method. Default value is backend-specific.
VIDEOWRITER_PROP_HW_DEVICE = 7
(open-only) Hardware device index (select GPU if multiple available). Device enumeration is acceleration type specific.
VIDEOWRITER_PROP_HW_ACCELERATION_USE_OPENCL = 8
(open-only) If non-zero, create new OpenCL context and bind it to current thread. The OpenCL context created with Video Acceleration context attached it (if not attached yet) for optimized GPU data copy between cv::UMat and HW accelerated encoder.
VIDEOWRITER_PROP_RAW_VIDEO = 9
(open-only) Set to non-zero to enable encapsulation of an encoded raw video stream. Each raw encoded video frame should be passed to VideoWriter::write() as single row or column of a \ref CV_8UC1 Mat. \note If the key frame interval is not 1 then it must be manually specified by the user. This can either be performed during initialization passing \ref VIDEOWRITER_PROP_KEY_INTERVAL as one of the extra encoder params to \ref VideoWriter::VideoWriter(const String &, int, double, const Size &, const std::vector< int > ¶ms) or afterwards by setting the \ref VIDEOWRITER_PROP_KEY_FLAG with \ref VideoWriter::set() before writing each frame. FFMpeg backend only.
VIDEOWRITER_PROP_KEY_INTERVAL = 10
(open-only) Set the key frame interval using raw video encapsulation (\ref VIDEOWRITER_PROP_RAW_VIDEO != 0). Defaults to 1 when not set. FFmpeg back-end only.
VIDEOWRITER_PROP_KEY_FLAG = 11
Set to non-zero to signal that the following frames are key frames or zero if not, when encapsulating raw video (\ref VIDEOWRITER_PROP_RAW_VIDEO != 0). FFmpeg back-end only.
VIDEOWRITER_PROP_PTS = 12
Specifies the frame presentation timestamp for each frame using the FPS time base. This property is only necessary when encapsulating externally encoded video where the decoding order differs from the presentation order, such as in GOP patterns with bi-directional B-frames. The value should be provided by your external encoder and for video sources with fixed frame rates it is equivalent to dividing the current frame’s presentation time (\ref CAP_PROP_POS_MSEC) by the frame duration (1000.0 / VideoCapture::get(\ref CAP_PROP_FPS)). It can be queried from the resulting encapsulated video file using VideoCapture::get(\ref CAP_PROP_PTS). FFmpeg back-end only.
VIDEOWRITER_PROP_DTS_DELAY = 13
Specifies the maximum difference between presentation (pts) and decompression timestamps (dts) using the FPS time base. This property is necessary only when encapsulating externally encoded video where the decoding order differs from the presentation order, such as in GOP patterns with bi-directional B-frames. The value should be calculated based on the specific GOP pattern used during encoding. For example, in a GOP with presentation order IBP and decoding order IPB, this value would be 1, as the B-frame is the second frame presented but the third to be decoded. It can be queried from the resulting encapsulated video file using VideoCapture::get(\ref CAP_PROP_DTS_DELAY). Non-zero values usually imply the stream is encoded using B-frames. FFmpeg back-end only.
CV__VIDEOWRITER_PROP_LATEST = 14
Trait Implementations§
Source§impl Clone for VideoWriterProperties
impl Clone for VideoWriterProperties
Source§fn clone(&self) -> VideoWriterProperties
fn clone(&self) -> VideoWriterProperties
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more