Class TextureAsTensorData | Barracuda | 1.1.2-preview
docs.unity.cn
    Show / Hide Table of Contents

    Class TextureAsTensorData

    Inheritance
    Object
    TextureAsTensorData
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Barracuda
    Syntax
    public class TextureAsTensorData : ITensorData, IDisposable

    Constructors

    TextureAsTensorData(Texture, Int32, TextureAsTensorData.Flip, TextureAsTensorData.InterpretDepthAs, TextureAsTensorData.InterpretColorAs)

    Declaration
    public TextureAsTensorData(Texture texture, int interpretPixelAsChannels = -1, TextureAsTensorData.Flip flip = TextureAsTensorData.Flip.Y, TextureAsTensorData.InterpretDepthAs depthAs = TextureAsTensorData.InterpretDepthAs.Batch, TextureAsTensorData.InterpretColorAs colorAs = TextureAsTensorData.InterpretColorAs.AverageMultipleChannels)
    Parameters
    Type Name Description
    Texture texture
    Int32 interpretPixelAsChannels
    TextureAsTensorData.Flip flip
    TextureAsTensorData.InterpretDepthAs depthAs
    TextureAsTensorData.InterpretColorAs colorAs

    TextureAsTensorData(Texture[], Int32, TextureAsTensorData.Flip, TextureAsTensorData.InterpretDepthAs, TextureAsTensorData.InterpretColorAs)

    Declaration
    public TextureAsTensorData(Texture[] textures, int interpretPixelAsChannels = -1, TextureAsTensorData.Flip flip = TextureAsTensorData.Flip.Y, TextureAsTensorData.InterpretDepthAs depthAs = TextureAsTensorData.InterpretDepthAs.Batch, TextureAsTensorData.InterpretColorAs colorAs = TextureAsTensorData.InterpretColorAs.AverageMultipleChannels)
    Parameters
    Type Name Description
    Texture[] textures
    Int32 interpretPixelAsChannels
    TextureAsTensorData.Flip flip
    TextureAsTensorData.InterpretDepthAs depthAs
    TextureAsTensorData.InterpretColorAs colorAs

    Properties

    flip

    Declaration
    public TextureAsTensorData.Flip flip { get; }
    Property Value
    Type Description
    TextureAsTensorData.Flip

    interpretColorAs

    Declaration
    public TextureAsTensorData.InterpretColorAs interpretColorAs { get; }
    Property Value
    Type Description
    TextureAsTensorData.InterpretColorAs

    interpretDepthAs

    Declaration
    public TextureAsTensorData.InterpretDepthAs interpretDepthAs { get; }
    Property Value
    Type Description
    TextureAsTensorData.InterpretDepthAs

    interpretPixelAsChannels

    Declaration
    public int interpretPixelAsChannels { get; }
    Property Value
    Type Description
    Int32

    maxCapacity

    Declaration
    public virtual int maxCapacity { get; }
    Property Value
    Type Description
    Int32
    Implements
    ITensorData.maxCapacity

    shape

    Declaration
    public TensorShape shape { get; }
    Property Value
    Type Description
    TensorShape

    textures

    Declaration
    public Texture[] textures { get; }
    Property Value
    Type Description
    Texture[]

    Methods

    Dispose()

    Declaration
    public virtual void Dispose()
    Implements
    IDisposable.Dispose()

    Download(TensorShape)

    Declaration
    public virtual float[] Download(TensorShape shape)
    Parameters
    Type Name Description
    TensorShape shape
    Returns
    Type Description
    Single[]
    Implements
    ITensorData.Download(TensorShape)

    Reserve(Int32)

    Declaration
    public virtual void Reserve(int count)
    Parameters
    Type Name Description
    Int32 count
    Implements
    ITensorData.Reserve(Int32)

    ScheduleAsyncDownload(Int32)

    Declaration
    public virtual bool ScheduleAsyncDownload(int count)
    Parameters
    Type Name Description
    Int32 count
    Returns
    Type Description
    Boolean
    Implements
    ITensorData.ScheduleAsyncDownload(Int32)

    SharedAccess(out Int32)

    Declaration
    public virtual float[] SharedAccess(out int offset)
    Parameters
    Type Name Description
    Int32 offset
    Returns
    Type Description
    Single[]
    Implements
    ITensorData.SharedAccess(out Int32)

    Upload(Single[], TensorShape, Int32)

    Declaration
    public virtual void Upload(float[] data, TensorShape shape, int managedBufferStartIndex = 0)
    Parameters
    Type Name Description
    Single[] data
    TensorShape shape
    Int32 managedBufferStartIndex
    Implements
    ITensorData.Upload(Single[], TensorShape, Int32)

    Extension Methods

    DeprecatedTensorDataExtensions.GetMaxCount(ITensorData)
    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX
    on 15 October 2020