* Source/OpenTK/Compute/CL10/CL.cs:
* Source/OpenTK/Compute/CL10/Core.cs: * Source/Bind/Specifications/csharp.tm: * Source/OpenTK/Compute/CL10/Delegates.cs: cl_context_properties should be mapped to IntPtr, not int. Modified CreateContext signature to return ErrorCode rather than plain int. * Source/OpenTK/Compute/CL10/CLHelper.cs: Added helper overloads that convert ContextProperties enums into IntPtr internally.
This commit is contained in:
parent
e8e1c82582
commit
6d6ad9646a
5 changed files with 232 additions and 146 deletions
|
@ -118,7 +118,7 @@ cl_addressing_mode, AddressingMode
|
|||
cl_command_queue_info, CommandQueueInfo
|
||||
cl_command_queue_properties, CommandQueueProperties
|
||||
cl_context_info, ContextInfo
|
||||
cl_context_properties, ContextProperties
|
||||
cl_context_properties, IntPtr # ContextProperties
|
||||
cl_device_info, DeviceInfo
|
||||
cl_device_type, DeviceType
|
||||
cl_event_info, EventInfo
|
||||
|
|
|
@ -947,34 +947,34 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext(ContextProperties[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext(IntPtr[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -986,19 +986,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1010,19 +1010,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1034,19 +1034,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, Int32 num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1061,15 +1061,15 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext(IntPtr[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1077,19 +1077,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1102,19 +1102,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1127,19 +1127,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1152,19 +1152,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] int[] errcode_ret)
|
||||
IntPtr CreateContext<T4>(IntPtr[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (IntPtr* devices_ptr = devices)
|
||||
fixed (int* errcode_ret_ptr = errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1178,15 +1178,15 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext(ref ContextProperties properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext(ref IntPtr properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1195,19 +1195,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1221,19 +1221,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1247,19 +1247,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1273,19 +1273,19 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, Int32 num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
|
@ -1301,15 +1301,15 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext(ref IntPtr properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1319,19 +1319,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1346,19 +1346,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1373,19 +1373,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1400,19 +1400,19 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
IntPtr CreateContext<T4>(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] out int errcode_ret)
|
||||
IntPtr CreateContext<T4>(ref IntPtr properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (IntPtr* devices_ptr = &devices)
|
||||
fixed (int* errcode_ret_ptr = &errcode_ret)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties_ptr, (uint)num_devices, (IntPtr*)devices_ptr, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
|
@ -1428,21 +1428,21 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext(ContextProperties* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext(IntPtr* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
|
||||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1453,13 +1453,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1470,13 +1470,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1487,13 +1487,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, Int32 num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1506,21 +1506,21 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data, (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
|
||||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1531,13 +1531,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1548,13 +1548,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] T4[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
return Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1565,13 +1565,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContext")]
|
||||
public static
|
||||
unsafe IntPtr CreateContext<T4>(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] int* errcode_ret)
|
||||
unsafe IntPtr CreateContext<T4>(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T4 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContext((ContextProperties*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (int*)errcode_ret);
|
||||
IntPtr retval = Delegates.clCreateContext((IntPtr*)properties, (uint)num_devices, (IntPtr*)devices, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
user_data = (T4)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1583,32 +1583,32 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
IntPtr CreateContextFromType(IntPtr[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(IntPtr[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1620,18 +1620,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(IntPtr[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1643,18 +1643,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(IntPtr[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1666,18 +1666,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(IntPtr[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = properties)
|
||||
fixed (IntPtr* properties_ptr = properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T3)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1691,14 +1691,14 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
IntPtr CreateContextFromType(ref IntPtr properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1707,18 +1707,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(ref IntPtr properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1732,18 +1732,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(ref IntPtr properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1757,18 +1757,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(ref IntPtr properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
}
|
||||
|
@ -1782,18 +1782,18 @@ namespace OpenTK.Compute.CL10
|
|||
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
IntPtr CreateContextFromType<T3>(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
IntPtr CreateContextFromType<T3>(ref IntPtr properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
unsafe
|
||||
{
|
||||
fixed (ContextProperties* properties_ptr = &properties)
|
||||
fixed (IntPtr* properties_ptr = &properties)
|
||||
fixed (OpenTK.Compute.CL10.ErrorCode* errcode_ret_ptr = &errcode_ret)
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties_ptr, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret_ptr);
|
||||
user_data = (T3)user_data_ptr.Target;
|
||||
errcode_ret = *errcode_ret_ptr;
|
||||
return retval;
|
||||
|
@ -1809,21 +1809,21 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
unsafe IntPtr CreateContextFromType(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
unsafe IntPtr CreateContextFromType(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data, (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
|
||||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
unsafe IntPtr CreateContextFromType<T3>(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
unsafe IntPtr CreateContextFromType<T3>(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1834,13 +1834,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
unsafe IntPtr CreateContextFromType<T3>(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
unsafe IntPtr CreateContextFromType<T3>(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1851,13 +1851,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
unsafe IntPtr CreateContextFromType<T3>(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
unsafe IntPtr CreateContextFromType<T3>(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] T3[,,] user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
return Delegates.clCreateContextFromType((ContextProperties*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
return Delegates.clCreateContextFromType((IntPtr*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -1868,13 +1868,13 @@ namespace OpenTK.Compute.CL10
|
|||
[System.CLSCompliant(false)]
|
||||
[AutoGenerated(Category = "1.0", Version = "1.0", EntryPoint = "clCreateContextFromType")]
|
||||
public static
|
||||
unsafe IntPtr CreateContextFromType<T3>(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
unsafe IntPtr CreateContextFromType<T3>(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, [InAttribute, OutAttribute] ref T3 user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T3 : struct
|
||||
{
|
||||
GCHandle user_data_ptr = GCHandle.Alloc(user_data, GCHandleType.Pinned);
|
||||
try
|
||||
{
|
||||
IntPtr retval = Delegates.clCreateContextFromType((ContextProperties*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
IntPtr retval = Delegates.clCreateContextFromType((IntPtr*)properties, (DeviceTypeFlags)device_type, (IntPtr)pfn_notify, (IntPtr)user_data_ptr.AddrOfPinnedObject(), (OpenTK.Compute.CL10.ErrorCode*)errcode_ret);
|
||||
user_data = (T3)user_data_ptr.Target;
|
||||
return retval;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#region License
|
||||
#region License
|
||||
//
|
||||
// The Open Toolkit Library License
|
||||
//
|
||||
|
@ -92,5 +92,91 @@ namespace OpenTK.Compute.CL10
|
|||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Helper Overrides
|
||||
|
||||
public static unsafe IntPtr CreateContext(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
{
|
||||
return CreateContext((IntPtr*)properties, num_devices, devices, pfn_notify, user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContext(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, IntPtr user_data, OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
{
|
||||
IntPtr[] properties_correct = properties != null ? new IntPtr[properties.Length] : null;
|
||||
for (int i = 0; i < properties_correct.Length; i++)
|
||||
properties_correct[i] = new IntPtr((int)properties[i]);
|
||||
return CreateContext(properties_correct, num_devices, devices, pfn_notify, user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContext(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, IntPtr user_data, out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
{
|
||||
IntPtr properties_correct = new IntPtr((int)properties);
|
||||
return CreateContext(ref properties_correct, num_devices, ref devices, pfn_notify, user_data, out errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContext<T4>(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, ref T4 user_data, OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
return CreateContext((IntPtr*)properties, num_devices, devices, pfn_notify, ref user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContext<T4>(ContextProperties[] properties, uint num_devices, IntPtr[] devices, IntPtr pfn_notify, ref T4 user_data, OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
IntPtr[] properties_correct = properties != null ? new IntPtr[properties.Length] : null;
|
||||
for (int i = 0; i < properties_correct.Length; i++)
|
||||
properties_correct[i] = new IntPtr((int)properties[i]);
|
||||
return CreateContext(properties_correct, num_devices, devices, pfn_notify, ref user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContext<T4>(ref ContextProperties properties, uint num_devices, ref IntPtr devices, IntPtr pfn_notify, ref T4 user_data, out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
IntPtr properties_correct = new IntPtr((int)properties);
|
||||
return CreateContext(ref properties_correct, num_devices, ref devices, pfn_notify, ref user_data, out errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
{
|
||||
return CreateContextFromType((IntPtr*)properties, device_type, pfn_notify, user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
{
|
||||
IntPtr[] properties_correct = properties != null ? new IntPtr[properties.Length] : null;
|
||||
for (int i = 0; i < properties_correct.Length; i++)
|
||||
properties_correct[i] = new IntPtr((int)properties[i]);
|
||||
return CreateContextFromType(properties_correct, device_type, pfn_notify, user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
{
|
||||
IntPtr properties_correct = new IntPtr((int)properties);
|
||||
return CreateContextFromType(ref properties_correct, device_type, pfn_notify, user_data, out errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType<T4>(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, ref T4 user_data, OpenTK.Compute.CL10.ErrorCode* errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
return CreateContextFromType((IntPtr*)properties, device_type, pfn_notify, ref user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType<T4>(ContextProperties[] properties, DeviceTypeFlags device_type, IntPtr pfn_notify, ref T4 user_data, OpenTK.Compute.CL10.ErrorCode[] errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
IntPtr[] properties_correct = properties != null ? new IntPtr[properties.Length] : null;
|
||||
for (int i = 0; i < properties_correct.Length; i++)
|
||||
properties_correct[i] = new IntPtr((int)properties[i]);
|
||||
return CreateContextFromType(properties_correct, device_type, pfn_notify, ref user_data, errcode_ret);
|
||||
}
|
||||
|
||||
public static unsafe IntPtr CreateContextFromType<T4>(ref ContextProperties properties, DeviceTypeFlags device_type, IntPtr pfn_notify, ref T4 user_data, out OpenTK.Compute.CL10.ErrorCode errcode_ret)
|
||||
where T4 : struct
|
||||
{
|
||||
IntPtr properties_correct = new IntPtr((int)properties);
|
||||
return CreateContextFromType(ref properties_correct, device_type, pfn_notify, ref user_data, out errcode_ret);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
|
@ -50,10 +50,10 @@ namespace OpenTK.Compute.CL10
|
|||
internal extern static unsafe IntPtr CreateCommandQueue(IntPtr context, IntPtr device, CommandQueueFlags properties, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
[System.Runtime.InteropServices.DllImport(CL.Library, EntryPoint = "clCreateContext", ExactSpelling = true)]
|
||||
internal extern static unsafe IntPtr CreateContext(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int* errcode_ret);
|
||||
internal extern static unsafe IntPtr CreateContext(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
[System.Runtime.InteropServices.DllImport(CL.Library, EntryPoint = "clCreateContextFromType", ExactSpelling = true)]
|
||||
internal extern static unsafe IntPtr CreateContextFromType(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
internal extern static unsafe IntPtr CreateContextFromType(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
[System.Runtime.InteropServices.DllImport(CL.Library, EntryPoint = "clCreateImage2D", ExactSpelling = true)]
|
||||
internal extern static unsafe IntPtr CreateImage2D(IntPtr context, MemFlags flags, ImageFormat* image_format, IntPtr image_width, IntPtr image_height, IntPtr image_row_pitch, IntPtr host_ptr, [OutAttribute] int* errcode_ret);
|
||||
|
|
|
@ -48,10 +48,10 @@ namespace OpenTK.Compute.CL10
|
|||
internal unsafe delegate IntPtr CreateCommandQueue(IntPtr context, IntPtr device, CommandQueueFlags properties, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
internal unsafe static CreateCommandQueue clCreateCommandQueue;
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
internal unsafe delegate IntPtr CreateContext(ContextProperties* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] int* errcode_ret);
|
||||
internal unsafe delegate IntPtr CreateContext(IntPtr* properties, uint num_devices, IntPtr* devices, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
internal unsafe static CreateContext clCreateContext;
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
internal unsafe delegate IntPtr CreateContextFromType(ContextProperties* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
internal unsafe delegate IntPtr CreateContextFromType(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
|
||||
internal unsafe static CreateContextFromType clCreateContextFromType;
|
||||
[System.Security.SuppressUnmanagedCodeSecurity()]
|
||||
internal unsafe delegate IntPtr CreateImage2D(IntPtr context, MemFlags flags, ImageFormat* image_format, IntPtr image_width, IntPtr image_height, IntPtr image_row_pitch, IntPtr host_ptr, [OutAttribute] int* errcode_ret);
|
||||
|
|
Loading…
Reference in a new issue