mirror of
https://github.com/opencv/opencv.git
synced 2025-06-12 20:42:53 +08:00
videoio: preserve conflict with common properties
Usage: writer.set(cv::CAP_PROP_IMAGES_BASE + cv::IMWRITE_JPEG_QUALITY, 80);
This commit is contained in:
parent
c560ff23ad
commit
e547bbbc3f
@ -556,6 +556,20 @@ enum { CAP_PROP_GPHOTO2_PREVIEW = 17001, //!< Capture only preview fro
|
|||||||
|
|
||||||
//! @} gPhoto2
|
//! @} gPhoto2
|
||||||
|
|
||||||
|
|
||||||
|
/** @name Images backend
|
||||||
|
@{
|
||||||
|
*/
|
||||||
|
|
||||||
|
/** @brief Images backend properties
|
||||||
|
|
||||||
|
*/
|
||||||
|
enum { CAP_PROP_IMAGES_BASE = 18000,
|
||||||
|
CAP_PROP_IMAGES_LAST = 19000 // excluding
|
||||||
|
};
|
||||||
|
|
||||||
|
//! @} Images
|
||||||
|
|
||||||
//! @} videoio_flags_others
|
//! @} videoio_flags_others
|
||||||
|
|
||||||
|
|
||||||
|
@ -393,9 +393,13 @@ bool CvVideoWriter_Images::open( const char* _filename )
|
|||||||
|
|
||||||
bool CvVideoWriter_Images::setProperty( int id, double value )
|
bool CvVideoWriter_Images::setProperty( int id, double value )
|
||||||
{
|
{
|
||||||
params.push_back( id );
|
if (id >= cv::CAP_PROP_IMAGES_BASE && id < cv::CAP_PROP_IMAGES_LAST)
|
||||||
params.push_back( static_cast<int>( value ) );
|
{
|
||||||
return true;
|
params.push_back( id - cv::CAP_PROP_IMAGES_BASE );
|
||||||
|
params.push_back( static_cast<int>( value ) );
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false; // not supported
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user