docs.unity3d.com
    Show / Hide Table of Contents

    Class CinemachineScreenComposerGuides

    Use an instance of this class to draw screen composer guides in the game view. This is an internal class, and is not meant to be called outside of Cinemachine.

    Inheritance
    Object
    CinemachineScreenComposerGuides
    Namespace: Cinemachine.Editor
    Syntax
    public class CinemachineScreenComposerGuides

    Fields

    GetHardGuide

    Get the Hard Guide. Client must implement this

    Declaration
    public CinemachineScreenComposerGuides.RectGetter GetHardGuide
    Field Value
    Type Description
    CinemachineScreenComposerGuides.RectGetter

    GetSoftGuide

    Get the Soft Guide. Client must implement this

    Declaration
    public CinemachineScreenComposerGuides.RectGetter GetSoftGuide
    Field Value
    Type Description
    CinemachineScreenComposerGuides.RectGetter

    kGuideBarWidthPx

    Width of the draggable guide bar in the game view

    Declaration
    public const float kGuideBarWidthPx = 3F
    Field Value
    Type Description
    Single

    sDraggableGameWindowGuides

    If true, then allows game window guides to be edited in play mode.

    Declaration
    public static bool sDraggableGameWindowGuides
    Field Value
    Type Description
    Boolean

    SetHardGuide

    Set the Hard Guide. Client must implement this

    Declaration
    public CinemachineScreenComposerGuides.RectSetter SetHardGuide
    Field Value
    Type Description
    CinemachineScreenComposerGuides.RectSetter

    SetSoftGuide

    Get the Soft Guide. Client must implement this

    Declaration
    public CinemachineScreenComposerGuides.RectSetter SetSoftGuide
    Field Value
    Type Description
    CinemachineScreenComposerGuides.RectSetter

    Target

    Get the target object whose guides are being drawn. Client must implement this

    Declaration
    public CinemachineScreenComposerGuides.ObjectGetter Target
    Field Value
    Type Description
    CinemachineScreenComposerGuides.ObjectGetter

    Methods

    OnGUI_DrawGuides(Boolean, Camera, LensSettings, Boolean)

    Call this from the inspector's OnGUI. Draws the guides and manages dragging.

    Declaration
    public void OnGUI_DrawGuides(bool isLive, Camera outputCamera, LensSettings lens, bool showHardGuides)
    Parameters
    Type Name Description
    Boolean isLive

    Is the target live

    Camera outputCamera

    Destination camera

    LensSettings lens

    Current lens settings

    Boolean showHardGuides

    True if hard guides should be shown

    SetNewBounds(Rect, Rect, Rect, Rect)

    Helper to set the appropriate new rects in the target object, is something changed.

    Declaration
    public void SetNewBounds(Rect oldHard, Rect oldSoft, Rect newHard, Rect newSoft)
    Parameters
    Type Name Description
    Rect oldHard

    Current hard guide

    Rect oldSoft

    Current soft guide

    Rect newHard

    New hard guide

    Rect newSoft

    New soft guide

    Back to top
    Terms of use
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023