docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method AllocateTexture

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

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

    Declaration
    public virtual bool AllocateTexture(CommandBuffer cmd, ref Vector4 scaleOffset, Texture texture, int width, int height, int overrideInstanceID = -1)
    Parameters
    Type Name Description
    CommandBuffer cmd

    Target command buffer for graphics commands.

    Vector4 scaleOffset

    Destination scale (.xy) and offset (.zw)

    Texture texture

    Source Texture

    int width

    Request width in pixels.

    int height

    Request height in pixels.

    int overrideInstanceID

    Override texture instance ID.

    Returns
    Type Description
    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)