views:

122

answers:

1

Marshal.copy allows for signed data types only, but I have a giant array of uint16 to pass to IPP code. Any ideas ?

unsafe for looping on it seems wrong ...

A: 

You can use the good old mem copy API from kernel32 and declare the parameter types to fit your needs.

[DllImport("kernel32.dll", EntryPoint="RtlMoveMemory")]
static extern void CopyMemory(IntPtr dest, UInt16[] src, int length);
Mattias S