Function ffmpeg_sys::av_image_check_sar [−][src]
pub unsafe extern "C" fn av_image_check_sar(
w: c_uint,
h: c_uint,
sar: AVRational
) -> c_int
Expand description
Check if the given sample aspect ratio of an image is valid.
It is considered invalid if the denominator is 0 or if applying the ratio to the image size would make the smaller dimension less than 1. If the sar numerator is 0, it is considered unknown and will return as valid.
@param w width of the image @param h height of the image @param sar sample aspect ratio of the image @return 0 if valid, a negative AVERROR code otherwise