v4l2_detect_gtf(9) detect if the given timings follow the GTF standard

SYNOPSIS

bool v4l2_detect_gtf(unsigned frame_height, unsigned hfreq, unsigned vsync, u32 polarities, bool interlaced, struct v4l2_fract aspect, struct v4l2_dv_timings * fmt);

ARGUMENTS

frame_height

the total height of the frame (including blanking) in lines.

hfreq

the horizontal frequency in Hz.

vsync

the height of the vertical sync in lines.

polarities

the horizontal and vertical polarities (same as struct v4l2_bt_timings polarities).

interlaced

if this flag is true, it indicates interlaced format

aspect

preferred aspect ratio. GTF has no method of determining the aspect ratio in order to derive the image width from the image height, so it has to be passed explicitly. Usually the native screen aspect ratio is used for this. If it is not filled in correctly, then 16:9 will be assumed.

fmt

the resulting timings.

DESCRIPTION

This function will attempt to detect if the given values correspond to a valid GTF format. If so, then it will return true, and fmt will be filled in with the found GTF timings.

COPYRIGHT