---
name: "drm_rect_calc_vscale"
section: "9"
platform: "linux"
package: "linux-manual-3.16"
version: "3.16.56-1+deb8u1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/drm_rect_calc_vscale"
---

# drm\_rect\_calc\_vscale(9)

calculate the vertical scaling factor

## NAME

drm\_rect\_calc\_vscale - calculate the vertical scaling factor

## SYNOPSIS

**int drm\_rect\_calc\_vscale(const struct drm\_rect \*** *src***, const struct drm\_rect \*** *dst***, int** *min\_vscale***, int** *max\_vscale***);**

## ARGUMENTS

*src*

source window rectangle

*dst*

destination window rectangle

*min\_vscale*

minimum allowed vertical scaling factor

*max\_vscale*

maximum allowed vertical scaling factor

## DESCRIPTION

Calculate the vertical scaling factor as (*src* height) / (*dst* height).

## RETURNS

The vertical scaling factor, or errno of out of limits.

## AUTHORS

**Jesse Barnes** \<jesse.barnes@intel.com\>\
 Intel Corporation,

Initial version

**Laurent Pinchart** \<laurent.pinchart@ideasonboard.com\>\
 Ideas on board SPRL,

Driver internals

**Daniel Vetter** \<daniel.vetter@ffwll.ch\>\
 Intel Corporation,

Contributions all over the place

## COPYRIGHT
