videoCalculateDisplayRatio

Given the Pixel Aspect Ratio and size of an input video frame, and the pixel aspect ratio of the intended display device, calculates the actual display ratio the video will be rendered with.

bool
videoCalculateDisplayRatio
(
out uint darN
,
out uint darD
,,,,,,)

Parameters

darN uint

Numerator of the calculated display_ratio

darD uint

Denominator of the calculated display_ratio

videoWidth uint

Width of the video frame in pixels

videoHeight uint

Height of the video frame in pixels

videoParN uint

Numerator of the pixel aspect ratio of the input video.

videoParD uint

Denominator of the pixel aspect ratio of the input video.

displayParN uint

Numerator of the pixel aspect ratio of the display device

displayParD uint

Denominator of the pixel aspect ratio of the display device

Return Value

Type: bool

A boolean indicating success and a calculated Display Ratio in the dar_n and dar_d parameters. The return value is FALSE in the case of integer overflow or other error.