Developer Documentation
Our new developer documentation is now available. Please check it out!

CustomEffect<T>.Serialize

public static byte[] Serialize(T value)
public static IntPtr Serialize(T value, bool destroy = true)

Serialize structure to pointer for arbitary data T

Info

copy data for Marshal.StructureToPtr

Parameters

NameTypeDescription
value<T>data structure
destroyBooleanfree value

Returns

TypeDescription
Byte[]byte array representation of data structure
IntPtrpointer of data structure

Variants

Serialize(value)

public static byte[] Serialize(T value)

Serialize structure to pointer for arbitary data T

Warning

copy data for Marshal.StructureToPtr

Parameters

NameTypeDescription
value<T>data structure

Returns

TypeDescription
Byte[]byte array representation of data structure

Serialize(value, destroy)

public static IntPtr Serialize(T value, bool destroy = true)

Serialize structure to pointer for arbitary data T

Parameters

NameTypeDescription
value<T>data structure
destroyBooleanfree value

Returns

TypeDescription
IntPtrpointer of data structure