Class NativeSliceUnsafeUtility | DOTS Runtime | 0.28.0-preview.40
docs.unity3d.com
    Show / Hide Table of Contents

    Class NativeSliceUnsafeUtility

    Inheritance
    Object
    NativeSliceUnsafeUtility
    Namespace: Unity.Collections.LowLevel.Unsafe
    Syntax
    public static class NativeSliceUnsafeUtility

    Methods

    ConvertExistingDataToNativeSlice<T>(Void*, Int32, Int32)

    Declaration
    public static NativeSlice<T> ConvertExistingDataToNativeSlice<T>(void *dataPointer, int stride, int length)
        where T : struct
    Parameters
    Type Name Description
    Void* dataPointer
    Int32 stride
    Int32 length
    Returns
    Type Description
    NativeSlice<T>
    Type Parameters
    Name Description
    T

    GetUnsafePtr<T>(NativeSlice<T>)

    Declaration
    public static void *GetUnsafePtr<T>(this NativeSlice<T> nativeSlice)
        where T : struct
    Parameters
    Type Name Description
    NativeSlice<T> nativeSlice
    Returns
    Type Description
    Void*
    Type Parameters
    Name Description
    T

    GetUnsafeReadOnlyPtr<T>(NativeSlice<T>)

    Declaration
    public static void *GetUnsafeReadOnlyPtr<T>(this NativeSlice<T> nativeSlice)
        where T : struct
    Parameters
    Type Name Description
    NativeSlice<T> nativeSlice
    Returns
    Type Description
    Void*
    Type Parameters
    Name Description
    T
    In This Article
    • Methods
      • ConvertExistingDataToNativeSlice<T>(Void*, Int32, Int32)
      • GetUnsafePtr<T>(NativeSlice<T>)
      • GetUnsafeReadOnlyPtr<T>(NativeSlice<T>)
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023