Skip to main content

VideoInfo

A video stream's geometry, timing and codec identity, read from its header: total_num_frames (0 where the container does not state it; the index calls then refuse a frame past the end by name), fps (the average frame rate), duration_seconds, width and height (the native frame size), codec (for example 'h264') and pixel_format (for example 'yuv420p'). peek_video returns one with no frame decoded; load_video and VideoReader.info report the same fields.

codec (property)​

The codec name, for example 'h264'.

duration_seconds (property)​

The stream duration in seconds.

fps (property)​

The average frame rate.

height (property)​

The native frame height in pixels.

pixel_format (property)​

The native pixel format, for example 'yuv420p'.

total_num_frames (property)​

The frame count, or 0 where the container does not state it.

width (property)​

The native frame width in pixels.

__init__​

__init__(self, /, *args, **kwargs)

Initialize self. See help(type(self)) for accurate signature.