Skip to content
API referenceDevelopmentEngine APIEngine ccf7d03f
Synced

GamePresentationSettings.CalculateViewport

Section titled “GamePresentationSettings.CalculateViewport”
  • Calculates the centered content region for an available presentation surface.

API: engine
Project: Inno.Runtime

public Inno.Runtime.GamePresentationViewport Inno.Runtime.GamePresentationSettings.CalculateViewport(int availableWidth, int availableHeight)

Parameter availableWidth: Positive available surface width in pixels or logical preview units.

Parameter availableHeight: Positive available surface height in pixels or logical preview units.

A positive region that fills the surface or fits the configured reference aspect ratio.

Exception T:System.ArgumentOutOfRangeException: Thrown when an available or reference dimension is not positive.