docs.unity3d.com
    目次を表示する/隠す

    Interface IBrushController

    An interface that represents a brush's controller.

    Namespace: UnityEditor.TerrainTools
    Syntax
    public interface IBrushController
    Remarks

    This interface is used for implementing custom controllers for handling brush properties.

    Properties

    isInUse

    Determines if the brush controller is in use.

    Declaration
    bool isInUse { get; }
    Property Value
    Type Description
    Boolean

    Methods

    AppendBrushInfo(Terrain, IOnSceneGUI, StringBuilder)

    Adds basic information to the selected brush.

    Declaration
    void AppendBrushInfo(Terrain terrain, IOnSceneGUI editContext, StringBuilder builder)
    Parameters
    Type Name Description
    Terrain terrain

    The Terrain in focus.

    IOnSceneGUI editContext

    The IOnSceneGUI to reference.

    StringBuilder builder

    The StringBuilder containing the brush information.

    OnEnterToolMode(BrushShortcutHandler<BrushShortcutType>)

    Defines data when the brush is selected.

    Declaration
    void OnEnterToolMode(BrushShortcutHandler<BrushShortcutType> shortcutHandler)
    Parameters
    Type Name Description
    BrushShortcutHandler<BrushShortcutType> shortcutHandler

    The shortcut handler used to add and refernce shortcuts.

    OnExitToolMode(BrushShortcutHandler<BrushShortcutType>)

    Defines data when the brush is deselected.

    Declaration
    void OnExitToolMode(BrushShortcutHandler<BrushShortcutType> shortcutHandler)
    Parameters
    Type Name Description
    BrushShortcutHandler<BrushShortcutType> shortcutHandler

    The shortcut handler used to add and refernce shortcuts.

    OnInspectorGUI(Terrain, IOnInspectorGUI)

    Triggers events to render objects and displays within Scene view.

    Declaration
    void OnInspectorGUI(Terrain terrain, IOnInspectorGUI editContext)
    Parameters
    Type Name Description
    Terrain terrain

    The terrain in focus.

    IOnInspectorGUI editContext

    The editcontext to reference.

    OnPaint(Terrain, IOnPaint)

    Triggers events when painting on a terrain.

    Declaration
    bool OnPaint(Terrain terrain, IOnPaint editContext)
    Parameters
    Type Name Description
    Terrain terrain

    The Terrain in focus.

    IOnPaint editContext

    The editcontext to reference.

    Returns
    Type Description
    Boolean

    Returns true if the paint operation is succesful. Otherwise, returns false.

    OnSceneGUI(Event, Int32, Terrain, IOnSceneGUI)

    Triggers events to render objects and displays within Scene view.

    Declaration
    void OnSceneGUI(Event currentEvent, int controlId, Terrain terrain, IOnSceneGUI editContext)
    Parameters
    Type Name Description
    Event currentEvent

    The event state within the OnSceneGUI call.

    Int32 controlId

    The control identification of the OnSceneGUI

    Terrain terrain

    The terrain in focus.

    IOnSceneGUI editContext

    The editcontext to reference.

    See Also

    IBrushStrengthController
    IBrushSizeController
    IBrushRotationController
    IBrushScatterController
    IBrushSpacingController
    IBrushSmoothController
    IBrushModifierKeyController
    トップに戻る
    Copyright © 2023 Unity Technologies — 商標と利用規約
    • 法律関連
    • プライバシーポリシー
    • クッキー
    • 私の個人情報を販売または共有しない
    • Your Privacy Choices (Cookie Settings)