docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class Texture2DAtlas

    A generic Atlas texture of 2D textures. An atlas texture is a texture collection that collects multiple sub-textures into a single big texture. Sub-texture allocation for Texture2DAtlas is static and will not change after initial allocation. Does not add mipmap padding for sub-textures.

    Inheritance
    object
    Texture2DAtlas
    PowerOfTwoTextureAtlas
    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 Texture2DAtlas

    Constructors

    Name Description
    Texture2DAtlas(int, int, GraphicsFormat, FilterMode, bool, string, bool)

    Creates a new empty texture atlas.

    Properties

    Name Description
    AtlasTexture

    Handle to the texture of the atlas.

    maxMipLevelPadding

    Maximum mip padding (pow2) that can be applied to the textures in the atlas

    Methods

    Name Description
    AddTexture(CommandBuffer, ref Vector4, Texture)

    Add a texture into the atlas.

    AllocateTexture(CommandBuffer, ref Vector4, Texture, int, int, int)

    Allocate space from the atlas for a texture and copy texture contents into the atlas.

    AllocateTextureWithoutBlit(int, int, int, ref Vector4)

    Allocate space from the atlas for a texture.

    AllocateTextureWithoutBlit(Texture, int, int, ref Vector4)

    Allocate space from the atlas for a texture.

    BlitCubeTexture2D(CommandBuffer, Vector4, Texture, bool, int)

    Blit and project Cube texture into a 2D texture in the atlas.

    BlitOctahedralTexture(CommandBuffer, Vector4, Texture, Vector4, bool, int)

    Blit octahedral texture into the atlas.

    BlitTexture(CommandBuffer, Vector4, Texture, Vector4, bool, int)

    Blit 2D texture into the atlas.

    ClearTarget(CommandBuffer)

    Clear atlas texture.

    GetTextureID(Texture)

    Get sub-texture ID for the atlas.

    GetTextureID(Texture, Texture)

    Get sub-texture ID for the atlas.

    IsCached(out Vector4, int)

    Check if the atlas contains the texture.

    IsCached(out Vector4, Texture)

    Check if the atlas contains the textures.

    IsCached(out Vector4, Texture, Texture)

    Check if the atlas contains the textures.

    NeedsUpdate(Texture, bool)

    Check if contents of a texture needs to be updated in the atlas.

    NeedsUpdate(Texture, Texture, bool)

    Check if contents of a texture needs to be updated in the atlas.

    Release()

    Release atlas resources.

    ResetAllocator()

    Clear atlas sub-texture allocations.

    UpdateTexture(CommandBuffer, Texture, Texture, ref Vector4, Vector4, bool, bool)

    Update a texture in the atlas.

    UpdateTexture(CommandBuffer, Texture, ref Vector4, bool, bool)

    Update a texture in the atlas.

    Extension Methods

    AnalyticsUtils.ToNestedColumnWithDefault<T>(T, T, bool)
    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)