**File:** modules/videoio/include/opencv2/videoio.hpp
**Change Type:** modified
**Context:** PR #25874: `videoio`: fix `cv::VideoWriter` with FFmpeg encapsulation timestamps

**Code Changes:**
```diff
@@ -211,6 +211,8 @@ enum VideoCaptureProperties {
        CAP_PROP_CODEC_EXTRADATA_INDEX = 68, //!< Positive index indicates that returning extra data is supported by the video back end.  This can be retrieved as cap.retrieve(data, <returned index>).  E.g. When reading from a h264 encoded RTSP stream, the FFmpeg backend could return the SPS and/or PPS if available (if sent in reply to a DESCRIBE request), from calls to cap.retrieve(data, <returned index>).
        CAP_PROP_FRAME_TYPE = 69, //!< (read-only) FFmpeg back-end only - Frame type ascii code (73 = 'I', 80 = 'P', 66 = 'B' or 63 = '?' if unknown) of the most recently read frame.
        CAP_PROP_N_THREADS = 70, //!< (**open-only**) Set the maximum number of threads to use. Use 0 to use as many threads as CPU cores (applicable for FFmpeg back-end only).
+       CAP_PROP_PTS = 71, //!<  (read-only) FFmpeg back-end only - presentation timestamp of the most recently read frame using the FPS time base.  e.g. fps = 25, VideoCapture::get(\ref CAP_PROP_PTS) = 3, presentation time = 3/25 seconds.
+       CAP_PROP_DTS_DELAY = 72, //!<  (read-only) FFmpeg back-end only - maximum difference between presentation (pts) and decompression timestamps (dts) using FPS time base.  e.g. delay is maximum when frame_num = 0, if true, VideoCapture::get(\ref CAP_PROP_PTS) = 0 and VideoCapture::get(\ref CAP_PROP_DTS_DELAY) = 2, dts = -2.  Non zero values usually imply the stream is encoded using B-frames which are not decoded in presentation order.
 #ifndef CV_DOXYGEN
        CV__CAP_PROP_LATEST
 #endif
@@ -230,8 +232,10 @@ enum VideoWriterProperties {
```

Review comment:
The properties should be provided by or calculated from the parameters provided to the external encoder. Is this clearer in the below? ``` VIDEOWRITER_PROP_PTS_INDEX = 12, //!< Specifies the frame presentation index for each frame when encapsulating raw video (\ref VIDEOWRITER_PROP_RAW_VIDEO != 0). 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 is equivalent to dividing the current position of the video file (\ref CAP_PROP_POS_MSEC) by the duration (i.e. 1000.0/VideoCapture::get(\ref CAP_PROP_FPS) if the frame rate is fixed) of each frame. FFmpeg back-end only. VIDEOWRITER_PROP_B_FRAME_PRESENTATION_DELAY = 13, //!< Maximum delay (in frames) between a B-frame's decoding and presentation. For example, in a GOP with presentation order IBP and decoding order IPB, this value would be 1, as the B-frame is decoded third but presented second. 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 calculated based on the specific GOP pattern you used while encoding. FFmpeg back-end only. ```