docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class RenderPipelineGlobalSettingsUtils

    Set of utilities for RenderPipelineGlobalSettings

    Inheritance
    object
    RenderPipelineGlobalSettingsUtils
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.Rendering
    Assembly: Unity.RenderPipelines.Core.Runtime.dll
    Syntax
    public class RenderPipelineGlobalSettingsUtils

    Methods

    Create(Type, string, RenderPipelineGlobalSettings)

    Creates a RenderPipelineGlobalSettings asset

    Declaration
    public static RenderPipelineGlobalSettings Create(Type renderPipelineGlobalSettingsType, string path, RenderPipelineGlobalSettings dataSource = null)
    Parameters
    Type Name Description
    Type renderPipelineGlobalSettingsType
    string path

    The path where Unity generates the asset.

    RenderPipelineGlobalSettings dataSource

    Another RenderPipelineGlobalSettings that Unity uses as a data source.

    Returns
    Type Description
    RenderPipelineGlobalSettings

    Returns the asset created.

    Create<TGlobalSetting>(string, TGlobalSetting)

    Creates a RenderPipelineGlobalSettings asset

    Declaration
    public static TGlobalSetting Create<TGlobalSetting>(string path, TGlobalSetting dataSource = null) where TGlobalSetting : RenderPipelineGlobalSettings
    Parameters
    Type Name Description
    string path

    The path where Unity generates the asset.

    TGlobalSetting dataSource

    Another RenderPipelineGlobalSettings that Unity uses as a data source.

    Returns
    Type Description
    TGlobalSetting

    Returns the asset created.

    Type Parameters
    Name Description
    TGlobalSetting

    RenderPipelineGlobalSettings

    TryEnsure<TGlobalSetting, TRenderPipeline>(ref TGlobalSetting, string, bool)

    Checks that a RenderPipelineGlobalSettings asset exists. If the asset isn't valid, Unity tries the following in order:

    1. Loads the asset at the default path.
    2. Finds any asset in the project with the same type.
    3. If canCreateNewAsset is true, creates a new asset in the default path. If Unity finds or creates a valid asset, Unity updates the GraphicsSettings with it. Otherwise Unity will unregister the settings for the given pipeline.
    Declaration
    public static bool TryEnsure<TGlobalSetting, TRenderPipeline>(ref TGlobalSetting instance, string defaultPath = "", bool canCreateNewAsset = true) where TGlobalSetting : RenderPipelineGlobalSettings<TGlobalSetting, TRenderPipeline> where TRenderPipeline : RenderPipeline
    Parameters
    Type Name Description
    TGlobalSetting instance

    The current instance of the asset.

    string defaultPath

    The default path.

    bool canCreateNewAsset

    If set to true, Unity creates a new asset if it can't find an existing asset in the project.

    Returns
    Type Description
    bool

    The asset that Unity found or created, or null if Unity can't find or create a valid asset.

    Type Parameters
    Name Description
    TGlobalSetting

    The type of global settings asset to check.

    TRenderPipeline

    The type of RenderPipeline that this asset belongs to.

    Extension Methods

    ReflectionUtils.GetField(object, string)
    ReflectionUtils.GetFields(object)
    ReflectionUtils.Invoke(object, string, params object[])
    ReflectionUtils.SetField(object, string, object)
    AnalyticsUtils.ToNestedColumnWithDefault<T>(T, T, bool)
    AnalyticsUtils.ToNestedColumn<T>(T, bool)
    AnalyticsUtils.ToNestedColumn<T>(T, T)
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)