Class MarkerEditor | Timeline | 1.2.18
docs.unity3d.com
    Show / Hide Table of Contents

    Class MarkerEditor

    Use this class to customize marker types in the TimelineEditor.

    Inheritance
    Object
    MarkerEditor
    Namespace: UnityEditor.Timeline
    Syntax
    public class MarkerEditor

    Constructors

    MarkerEditor()

    Default constructor

    Declaration
    public MarkerEditor()

    Methods

    DrawOverlay(IMarker, MarkerUIStates, MarkerOverlayRegion)

    Draws additional overlays for a marker.

    Declaration
    public virtual void DrawOverlay(IMarker marker, MarkerUIStates uiState, MarkerOverlayRegion region)
    Parameters
    Type Name Description
    IMarker marker

    The marker to draw.

    MarkerUIStates uiState

    The visual state of the marker.

    MarkerOverlayRegion region

    The on-screen area where the marker is being drawn.

    Remarks

    Notes:

    • It is only called during TimelineWindow's Repaint step.
    • If there are multiple markers on top of each other, only the topmost marker receives the DrawOverlay call.

    GetMarkerOptions(IMarker)

    Implement this method to override the default options for drawing a marker.

    Declaration
    public virtual MarkerDrawOptions GetMarkerOptions(IMarker marker)
    Parameters
    Type Name Description
    IMarker marker

    The marker to draw.

    Returns
    Type Description
    MarkerDrawOptions

    OnCreate(IMarker, IMarker)

    Called when a marker is created.

    Declaration
    public virtual void OnCreate(IMarker marker, IMarker clonedFrom)
    Parameters
    Type Name Description
    IMarker marker

    The marker that is created.

    IMarker clonedFrom

    TThe source that the marker was copied from. This can be set to null if the marker is not a copy.

    Remarks

    The callback occurs before the marker is assigned to the track.

    Back to top
    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