Nez.Portable/ECS/Scene.cs
/// <summary>
/// sets the design size and resolution policy then updates the render textures
/// </summary>
/// <param name="width">Width.</param>
/// <param name="height">Height.</param>
/// <param name="sceneResolutionPolicy">Scene resolution policy.</param>
/// <param name="horizontalBleed">Horizontal bleed size. Used only if resolution policy is set to <see cref="SceneResolutionPolicy.BestFit"/>.</param>
/// <param name="verticalBleed">Horizontal bleed size. Used only if resolution policy is set to <see cref="SceneResolutionPolicy.BestFit"/>.</param>
sets the design size and resolution policy then updates the render textures
sets the design size and resolution policy then updates the render textures
public void SetDesignResolution(
            int width,
            int height,
            SceneResolutionPolicy sceneResolutionPolicy,
            int horizontalBleed = 0,
            int verticalBleed = 0)
        {
            _designResolutionSize = new Point(width, height);
            _resolutionPolicy = sceneResolutionPolicy;
            if (_resolutionPolicy == SceneResolutionPolicy.BestFit)
                _designBleedSize = new Point(horizontalBleed, verticalBleed);
            updateResolutionScaler();
        }
public void SetDesignResolution ( int width , int height , SceneResolutionPolicy sceneResolutionPolicy , int horizontalBleed = 0 , int verticalBleed = 0 ) { _designResolutionSize = new Point ( width , height ) ; _resolutionPolicy = sceneResolutionPolicy ; if ( _resolutionPolicy == SceneResolutionPolicy . BestFit ) _designBleedSize = new Point ( horizontalBleed , verticalBleed ) ; updateResolutionScaler ( ) ; }
sets the design size and resolution policy then updates the render textures
sets the design size and resolution policy then updates the render textures
width
int
None
height
int
None
sceneResolutionPolicy
SceneResolutionPolicy
Scene resolution policy.
Scene resolution policy .
horizontalBleed
int
Horizontal bleed size. Used only if resolution policy is set to .
Horizontal bleed size . Used only if resolution policy is set to .
verticalBleed
int
Horizontal bleed size. Used only if resolution policy is set to .
Horizontal bleed size . Used only if resolution policy is set to .