2D Toolkit Forum

2D Toolkit => Support => Topic started by: asdasd on November 22, 2013, 02:12:40 pm

Title: Camera ResolutionOverride AutoscaleMode option
Post by: asdasd on November 22, 2013, 02:12:40 pm
Could you please add the following option to Autoscale modes? Thanks.

Fill the camera view, but retain scale proportions.
The name is up to you. Possible names: Fill, FillVisible, CropToFill...

Code:
Code: [Select]
case tk2dCameraResolutionOverride.AutoScaleMode.Fill:
s = Mathf.Max(width / settings.nativeResolutionWidth,height / settings.nativeResolutionHeight);
scale.Set(s, s);
break;
Title: Re: Camera ResolutionOverride AutoscaleMode option
Post by: unikronsoftware on November 22, 2013, 10:51:38 pm
Added to the list. thanks.