@@ -290,22 +290,25 @@ enum DeinterlaceMode
290290
291291/* * @brief Struct providing information about video file format. :
292292 */
293- struct FormatInfo
293+ struct CV_EXPORTS_W_SIMPLE FormatInfo
294294{
295- Codec codec;
296- ChromaFormat chromaFormat;
297- int nBitDepthMinus8 = -1 ;
298- int ulWidth = 0 ;// !< Coded sequence width in pixels.
299- int ulHeight = 0 ;// !< Coded sequence height in pixels.
300- int width = 0 ;// !< Width of the decoded frame returned by nextFrame(frame).
301- int height = 0 ;// !< Height of the decoded frame returned by nextFrame(frame).
302- int ulMaxWidth = 0 ;
303- int ulMaxHeight = 0 ;
304- Rect displayArea;// !< ROI inside the decoded frame returned by nextFrame(frame), containing the useable video frame.
305- bool valid = false ;
306- double fps = 0 ;
307- int ulNumDecodeSurfaces = 0 ;// !< Maximum number of internal decode surfaces.
308- DeinterlaceMode deinterlaceMode;
295+ CV_WRAP FormatInfo () : nBitDepthMinus8(-1 ), ulWidth(0 ), ulHeight(0 ), width(0 ), height(0 ), ulMaxWidth(0 ), ulMaxHeight(0 ), valid(false ),
296+ fps(0 ), ulNumDecodeSurfaces(0 ) {};
297+
298+ CV_PROP_RW Codec codec;
299+ CV_PROP_RW ChromaFormat chromaFormat;
300+ CV_PROP_RW int nBitDepthMinus8;
301+ CV_PROP_RW int ulWidth;// !< Coded sequence width in pixels.
302+ CV_PROP_RW int ulHeight;// !< Coded sequence height in pixels.
303+ CV_PROP_RW int width;// !< Width of the decoded frame returned by nextFrame(frame).
304+ CV_PROP_RW int height;// !< Height of the decoded frame returned by nextFrame(frame).
305+ int ulMaxWidth;
306+ int ulMaxHeight;
307+ CV_PROP_RW Rect displayArea;// !< ROI inside the decoded frame returned by nextFrame(frame), containing the useable video frame.
308+ CV_PROP_RW bool valid;
309+ CV_PROP_RW double fps;
310+ CV_PROP_RW int ulNumDecodeSurfaces;// !< Maximum number of internal decode surfaces.
311+ CV_PROP_RW DeinterlaceMode deinterlaceMode;
309312};
310313
311314/* * @brief cv::cudacodec::VideoReader generic properties identifier.
@@ -342,7 +345,7 @@ class CV_EXPORTS_W VideoReader
342345
343346 /* * @brief Returns information about video file format.
344347 */
345- virtual FormatInfo format () const = 0;
348+ CV_WRAP virtual FormatInfo format () const = 0;
346349
347350 /* * @brief Grabs the next frame from the video source.
348351
0 commit comments