docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct AutoUnwrapSettings

    A collection of settings describing how to project UV coordinates for a Face.

    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    object.Equals(object, object)
    object.GetType()
    object.ReferenceEquals(object, object)
    Namespace: UnityEngine.ProBuilder
    Assembly: Unity.ProBuilder.dll
    Syntax
    [Serializable]
    public struct AutoUnwrapSettings

    Constructors

    AutoUnwrapSettings(AutoUnwrapSettings)

    Creates a new set of AutoUnwrapSettings from the specified source object.

    Declaration
    public AutoUnwrapSettings(AutoUnwrapSettings unwrapSettings)
    Parameters
    Type Name Description
    AutoUnwrapSettings unwrapSettings

    The settings to copy to the new instance.

    Properties

    anchor

    Gets or sets the starting point to use for UV transform operations.

    Declaration
    public AutoUnwrapSettings.Anchor anchor { get; set; }
    Property Value
    Type Description
    AutoUnwrapSettings.Anchor

    defaultAutoUnwrapSettings

    Creates and returns the default set of AutoUnwrapSettings.

    Declaration
    public static AutoUnwrapSettings defaultAutoUnwrapSettings { get; }
    Property Value
    Type Description
    AutoUnwrapSettings

    fill

    Gets or sets the AutoUnwrapSettings.Fill mode.

    Declaration
    public AutoUnwrapSettings.Fill fill { get; set; }
    Property Value
    Type Description
    AutoUnwrapSettings.Fill

    fit

    Gets a set of unwrap parameters that strectches the face texture to fill a normalized coordinate space, maintaining the aspect ratio.

    Declaration
    public static AutoUnwrapSettings fit { get; }
    Property Value
    Type Description
    AutoUnwrapSettings

    flipU

    Gets or sets whether to invert UV coordinates horizontally.

    Declaration
    public bool flipU { get; set; }
    Property Value
    Type Description
    bool

    flipV

    Gets or sets whether to invert UV coordinates vertically.

    Declaration
    public bool flipV { get; set; }
    Property Value
    Type Description
    bool

    offset

    Gets or sets the value to add to UV coordinates after applying projection and anchor settings.

    Declaration
    public Vector2 offset { get; set; }
    Property Value
    Type Description
    Vector2

    rotation

    Gets or sets the amount in degrees to rotate UV coordinates clockwise.

    Declaration
    public float rotation { get; set; }
    Property Value
    Type Description
    float

    scale

    Gets or sets the scaling value to apply to coordinates after applying projection and anchor settings.

    Declaration
    public Vector2 scale { get; set; }
    Property Value
    Type Description
    Vector2

    stretch

    Gets a set of unwrap parameters that stretches the face texture to fill a normalized coordinate space, disregarding the aspect ratio.

    Declaration
    public static AutoUnwrapSettings stretch { get; }
    Property Value
    Type Description
    AutoUnwrapSettings

    swapUV

    Gets or sets whether to exchange the U and V coordinate parameters.

    Declaration
    public bool swapUV { get; set; }
    Property Value
    Type Description
    bool
    Examples

    {U, V} becomes {V, U}

    tile

    Gets a set of unwrap parameters that tiles UVs.

    Declaration
    public static AutoUnwrapSettings tile { get; }
    Property Value
    Type Description
    AutoUnwrapSettings

    useWorldSpace

    Gets or sets whether to transform vertex positions into world space for UV projection. By default, ProBuilder projects UVs in local (or model) coordinates.

    Declaration
    public bool useWorldSpace { get; set; }
    Property Value
    Type Description
    bool

    Methods

    Reset()

    Resets all parameters to their default values.

    Declaration
    public void Reset()

    ToString()

    Returns a string representation of the AutoUnwrapSettings.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    A multi-line string containing the values for each setting.

    Overrides
    ValueType.ToString()
    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)