i tried this
float arrB = new float;
IntPtr arrayPtr = Marshal.UnsafeAddrOfPinnedArrayElement(arrB, 0);
ComputeBuffer<float> b = new ComputeBuffer<float>(context, ComputeMemoryFlags.ReadOnly | ComputeMemoryFlags.CopyHostPointer, count1*count* sizeof(float), arrayPtr);
but it doesn't work
it errors at line
Handle = CL10.CreateBuffer(context.Handle, flags, new IntPtr(Marshal.SizeOf(typeof(T)) * count), dataPtr, out error);
I need your help,bro!
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.