Subversion Repositories AndroidProjects

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1452 chris 1
#region License
2
//
3
// The Open Toolkit Library License
4
//
5
// Copyright (c) 2006 - 2009 the Open Toolkit library.
6
//
7
// Permission is hereby granted, free of charge, to any person obtaining a copy
8
// of this software and associated documentation files (the "Software"), to deal
9
// in the Software without restriction, including without limitation the rights to 
10
// use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
11
// the Software, and to permit persons to whom the Software is furnished to do
12
// so, subject to the following conditions:
13
//
14
// The above copyright notice and this permission notice shall be included in all
15
// copies or substantial portions of the Software.
16
//
17
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
19
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
20
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
21
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
22
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
24
// OTHER DEALINGS IN THE SOFTWARE.
25
//
26
#endregion
27
 
28
#if EXPERIMENTAL
29
 
30
namespace OpenTK.Compute.CL10
31
{
32
    using System;
33
    using System.Text;
34
    using System.Runtime.InteropServices;
35
    #pragma warning disable 0649
36
    #pragma warning disable 3019
37
    #pragma warning disable 1591
38
 
39
    partial class CL
40
    {
41
        internal static partial class Delegates
42
        {
43
            [System.Security.SuppressUnmanagedCodeSecurity()]
44
            internal unsafe delegate int BuildProgram(IntPtr program, uint num_devices, IntPtr* device_list, String options, IntPtr pfn_notify, IntPtr user_data);
45
            internal unsafe static BuildProgram clBuildProgram;
46
            [System.Security.SuppressUnmanagedCodeSecurity()]
47
            internal unsafe delegate IntPtr CreateBuffer(IntPtr context, MemFlags flags, IntPtr size, IntPtr host_ptr, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
48
            internal unsafe static CreateBuffer clCreateBuffer;
49
            [System.Security.SuppressUnmanagedCodeSecurity()]
50
            internal unsafe delegate IntPtr CreateCommandQueue(IntPtr context, IntPtr device, CommandQueueFlags properties, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
51
            internal unsafe static CreateCommandQueue clCreateCommandQueue;
52
            [System.Security.SuppressUnmanagedCodeSecurity()]
53
            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);
54
            internal unsafe static CreateContext clCreateContext;
55
            [System.Security.SuppressUnmanagedCodeSecurity()]
56
            internal unsafe delegate IntPtr CreateContextFromType(IntPtr* properties, DeviceTypeFlags device_type, IntPtr pfn_notify, IntPtr user_data, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
57
            internal unsafe static CreateContextFromType clCreateContextFromType;
58
            [System.Security.SuppressUnmanagedCodeSecurity()]
59
            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);
60
            internal unsafe static CreateImage2D clCreateImage2D;
61
            [System.Security.SuppressUnmanagedCodeSecurity()]
62
            internal unsafe delegate IntPtr CreateImage3D(IntPtr context, MemFlags flags, ImageFormat* image_format, IntPtr image_width, IntPtr image_height, IntPtr image_depth, IntPtr image_row_pitch, IntPtr image_slice_pitch, IntPtr host_ptr, [OutAttribute] int* errcode_ret);
63
            internal unsafe static CreateImage3D clCreateImage3D;
64
            [System.Security.SuppressUnmanagedCodeSecurity()]
65
            internal unsafe delegate IntPtr CreateKernel(IntPtr program, String kernel_name, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
66
            internal unsafe static CreateKernel clCreateKernel;
67
            [System.Security.SuppressUnmanagedCodeSecurity()]
68
            internal unsafe delegate int CreateKernelsInProgram(IntPtr program, uint num_kernels, IntPtr* kernels, [OutAttribute] uint* num_kernels_ret);
69
            internal unsafe static CreateKernelsInProgram clCreateKernelsInProgram;
70
            [System.Security.SuppressUnmanagedCodeSecurity()]
71
            internal unsafe delegate IntPtr CreateProgramWithBinary(IntPtr context, uint num_devices, IntPtr* device_list, IntPtr* lengths, byte** binaries, int* binary_status, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
72
            internal unsafe static CreateProgramWithBinary clCreateProgramWithBinary;
73
            [System.Security.SuppressUnmanagedCodeSecurity()]
74
            internal unsafe delegate IntPtr CreateProgramWithSource(IntPtr context, uint count, String[] strings, IntPtr* lengths, [OutAttribute] OpenTK.Compute.CL10.ErrorCode* errcode_ret);
75
            internal unsafe static CreateProgramWithSource clCreateProgramWithSource;
76
            [System.Security.SuppressUnmanagedCodeSecurity()]
77
            internal unsafe delegate IntPtr CreateSampler(IntPtr context, bool normalized_coords, AddressingMode addressing_mode, FilterMode filter_mode, [OutAttribute] int* errcode_ret);
78
            internal unsafe static CreateSampler clCreateSampler;
79
            [System.Security.SuppressUnmanagedCodeSecurity()]
80
            internal delegate int EnqueueBarrier(IntPtr command_queue);
81
            internal static EnqueueBarrier clEnqueueBarrier;
82
            [System.Security.SuppressUnmanagedCodeSecurity()]
83
            internal unsafe delegate int EnqueueCopyBuffer(IntPtr command_queue, IntPtr src_buffer, IntPtr dst_buffer, IntPtr src_offset, IntPtr dst_offset, IntPtr cb, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
84
            internal unsafe static EnqueueCopyBuffer clEnqueueCopyBuffer;
85
            [System.Security.SuppressUnmanagedCodeSecurity()]
86
            internal unsafe delegate int EnqueueCopyBufferToImage(IntPtr command_queue, IntPtr src_buffer, IntPtr dst_image, IntPtr src_offset, IntPtr** dst_origin, IntPtr** region, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
87
            internal unsafe static EnqueueCopyBufferToImage clEnqueueCopyBufferToImage;
88
            [System.Security.SuppressUnmanagedCodeSecurity()]
89
            internal unsafe delegate int EnqueueCopyImage(IntPtr command_queue, IntPtr src_image, IntPtr dst_image, IntPtr** src_origin, IntPtr** dst_origin, IntPtr** region, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
90
            internal unsafe static EnqueueCopyImage clEnqueueCopyImage;
91
            [System.Security.SuppressUnmanagedCodeSecurity()]
92
            internal unsafe delegate int EnqueueCopyImageToBuffer(IntPtr command_queue, IntPtr src_image, IntPtr dst_buffer, IntPtr** src_origin, IntPtr** region, IntPtr dst_offset, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
93
            internal unsafe static EnqueueCopyImageToBuffer clEnqueueCopyImageToBuffer;
94
            [System.Security.SuppressUnmanagedCodeSecurity()]
95
            internal unsafe delegate System.IntPtr EnqueueMapBuffer(IntPtr command_queue, IntPtr buffer, bool blocking_map, MapFlags map_flags, IntPtr offset, IntPtr cb, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event, [OutAttribute] int* errcode_ret);
96
            internal unsafe static EnqueueMapBuffer clEnqueueMapBuffer;
97
            [System.Security.SuppressUnmanagedCodeSecurity()]
98
            internal unsafe delegate System.IntPtr EnqueueMapImage(IntPtr command_queue, IntPtr image, bool blocking_map, MapFlags map_flags, IntPtr** origin, IntPtr** region, IntPtr* image_row_pitch, IntPtr* image_slice_pitch, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event, [OutAttribute] int* errcode_ret);
99
            internal unsafe static EnqueueMapImage clEnqueueMapImage;
100
            [System.Security.SuppressUnmanagedCodeSecurity()]
101
            internal unsafe delegate int EnqueueMarker(IntPtr command_queue, IntPtr* @event);
102
            internal unsafe static EnqueueMarker clEnqueueMarker;
103
            [System.Security.SuppressUnmanagedCodeSecurity()]
104
            internal unsafe delegate int EnqueueNativeKernel(IntPtr command_queue, IntPtr user_func, IntPtr args, IntPtr cb_args, uint num_mem_objects, IntPtr* mem_list, IntPtr args_mem_loc, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
105
            internal unsafe static EnqueueNativeKernel clEnqueueNativeKernel;
106
            [System.Security.SuppressUnmanagedCodeSecurity()]
107
            internal unsafe delegate int EnqueueNDRangeKernel(IntPtr command_queue, IntPtr kernel, uint work_dim, IntPtr* global_work_offset, IntPtr* global_work_size, IntPtr* local_work_size, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
108
            internal unsafe static EnqueueNDRangeKernel clEnqueueNDRangeKernel;
109
            [System.Security.SuppressUnmanagedCodeSecurity()]
110
            internal unsafe delegate int EnqueueReadBuffer(IntPtr command_queue, IntPtr buffer, bool blocking_read, IntPtr offset, IntPtr cb, IntPtr ptr, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
111
            internal unsafe static EnqueueReadBuffer clEnqueueReadBuffer;
112
            [System.Security.SuppressUnmanagedCodeSecurity()]
113
            internal unsafe delegate int EnqueueReadImage(IntPtr command_queue, IntPtr image, bool blocking_read, IntPtr** origin, IntPtr** region, IntPtr row_pitch, IntPtr slice_pitch, IntPtr ptr, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
114
            internal unsafe static EnqueueReadImage clEnqueueReadImage;
115
            [System.Security.SuppressUnmanagedCodeSecurity()]
116
            internal unsafe delegate int EnqueueTask(IntPtr command_queue, IntPtr kernel, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
117
            internal unsafe static EnqueueTask clEnqueueTask;
118
            [System.Security.SuppressUnmanagedCodeSecurity()]
119
            internal unsafe delegate int EnqueueUnmapMemObject(IntPtr command_queue, IntPtr memobj, IntPtr mapped_ptr, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
120
            internal unsafe static EnqueueUnmapMemObject clEnqueueUnmapMemObject;
121
            [System.Security.SuppressUnmanagedCodeSecurity()]
122
            internal unsafe delegate int EnqueueWaitForEvents(IntPtr command_queue, uint num_events, IntPtr* event_list);
123
            internal unsafe static EnqueueWaitForEvents clEnqueueWaitForEvents;
124
            [System.Security.SuppressUnmanagedCodeSecurity()]
125
            internal unsafe delegate int EnqueueWriteBuffer(IntPtr command_queue, IntPtr buffer, bool blocking_write, IntPtr offset, IntPtr cb, IntPtr ptr, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
126
            internal unsafe static EnqueueWriteBuffer clEnqueueWriteBuffer;
127
            [System.Security.SuppressUnmanagedCodeSecurity()]
128
            internal unsafe delegate int EnqueueWriteImage(IntPtr command_queue, IntPtr image, bool blocking_write, IntPtr** origin, IntPtr** region, IntPtr input_row_pitch, IntPtr input_slice_pitch, IntPtr ptr, uint num_events_in_wait_list, IntPtr* event_wait_list, IntPtr* @event);
129
            internal unsafe static EnqueueWriteImage clEnqueueWriteImage;
130
            [System.Security.SuppressUnmanagedCodeSecurity()]
131
            internal delegate int Finish(IntPtr command_queue);
132
            internal static Finish clFinish;
133
            [System.Security.SuppressUnmanagedCodeSecurity()]
134
            internal delegate int Flush(IntPtr command_queue);
135
            internal static Flush clFlush;
136
            [System.Security.SuppressUnmanagedCodeSecurity()]
137
            internal unsafe delegate int GetCommandQueueInfo(IntPtr command_queue, CommandQueueInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
138
            internal unsafe static GetCommandQueueInfo clGetCommandQueueInfo;
139
            [System.Security.SuppressUnmanagedCodeSecurity()]
140
            internal unsafe delegate int GetContextInfo(IntPtr context, ContextInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
141
            internal unsafe static GetContextInfo clGetContextInfo;
142
            [System.Security.SuppressUnmanagedCodeSecurity()]
143
            internal unsafe delegate int GetDeviceIDs(IntPtr platform, DeviceTypeFlags device_type, uint num_entries, IntPtr* devices, uint* num_devices);
144
            internal unsafe static GetDeviceIDs clGetDeviceIDs;
145
            [System.Security.SuppressUnmanagedCodeSecurity()]
146
            internal unsafe delegate int GetDeviceInfo(IntPtr device, DeviceInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
147
            internal unsafe static GetDeviceInfo clGetDeviceInfo;
148
            [System.Security.SuppressUnmanagedCodeSecurity()]
149
            internal unsafe delegate int GetEventInfo(IntPtr @event, EventInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
150
            internal unsafe static GetEventInfo clGetEventInfo;
151
            [System.Security.SuppressUnmanagedCodeSecurity()]
152
            internal unsafe delegate int GetEventProfilingInfo(IntPtr @event, ProfilingInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
153
            internal unsafe static GetEventProfilingInfo clGetEventProfilingInfo;
154
            [System.Security.SuppressUnmanagedCodeSecurity()]
155
            internal unsafe delegate int GetImageInfo(IntPtr image, ImageInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
156
            internal unsafe static GetImageInfo clGetImageInfo;
157
            [System.Security.SuppressUnmanagedCodeSecurity()]
158
            internal unsafe delegate int GetKernelInfo(IntPtr kernel, KernelInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
159
            internal unsafe static GetKernelInfo clGetKernelInfo;
160
            [System.Security.SuppressUnmanagedCodeSecurity()]
161
            internal unsafe delegate int GetKernelWorkGroupInfo(IntPtr kernel, IntPtr device, KernelWorkGroupInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
162
            internal unsafe static GetKernelWorkGroupInfo clGetKernelWorkGroupInfo;
163
            [System.Security.SuppressUnmanagedCodeSecurity()]
164
            internal unsafe delegate int GetMemObjectInfo(IntPtr memobj, MemInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
165
            internal unsafe static GetMemObjectInfo clGetMemObjectInfo;
166
            [System.Security.SuppressUnmanagedCodeSecurity()]
167
            internal unsafe delegate int GetPlatformIDs(uint num_entries, IntPtr* platforms, uint* num_platforms);
168
            internal unsafe static GetPlatformIDs clGetPlatformIDs;
169
            [System.Security.SuppressUnmanagedCodeSecurity()]
170
            internal unsafe delegate int GetPlatformInfo(IntPtr platform, PlatformInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
171
            internal unsafe static GetPlatformInfo clGetPlatformInfo;
172
            [System.Security.SuppressUnmanagedCodeSecurity()]
173
            internal unsafe delegate int GetProgramBuildInfo(IntPtr program, IntPtr device, ProgramBuildInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
174
            internal unsafe static GetProgramBuildInfo clGetProgramBuildInfo;
175
            [System.Security.SuppressUnmanagedCodeSecurity()]
176
            internal unsafe delegate int GetProgramInfo(IntPtr program, ProgramInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
177
            internal unsafe static GetProgramInfo clGetProgramInfo;
178
            [System.Security.SuppressUnmanagedCodeSecurity()]
179
            internal unsafe delegate int GetSamplerInfo(IntPtr sampler, SamplerInfo param_name, IntPtr param_value_size, IntPtr param_value, [OutAttribute] IntPtr* param_value_size_ret);
180
            internal unsafe static GetSamplerInfo clGetSamplerInfo;
181
            [System.Security.SuppressUnmanagedCodeSecurity()]
182
            internal unsafe delegate int GetSupportedImageFormats(IntPtr context, MemFlags flags, MemObjectType image_type, uint num_entries, ImageFormat* image_formats, uint* num_image_formats);
183
            internal unsafe static GetSupportedImageFormats clGetSupportedImageFormats;
184
            [System.Security.SuppressUnmanagedCodeSecurity()]
185
            internal delegate int ReleaseCommandQueue(IntPtr command_queue);
186
            internal static ReleaseCommandQueue clReleaseCommandQueue;
187
            [System.Security.SuppressUnmanagedCodeSecurity()]
188
            internal delegate int ReleaseContext(IntPtr context);
189
            internal static ReleaseContext clReleaseContext;
190
            [System.Security.SuppressUnmanagedCodeSecurity()]
191
            internal delegate int ReleaseEvent(IntPtr @event);
192
            internal static ReleaseEvent clReleaseEvent;
193
            [System.Security.SuppressUnmanagedCodeSecurity()]
194
            internal delegate int ReleaseKernel(IntPtr kernel);
195
            internal static ReleaseKernel clReleaseKernel;
196
            [System.Security.SuppressUnmanagedCodeSecurity()]
197
            internal delegate int ReleaseMemObject(IntPtr memobj);
198
            internal static ReleaseMemObject clReleaseMemObject;
199
            [System.Security.SuppressUnmanagedCodeSecurity()]
200
            internal delegate int ReleaseProgram(IntPtr program);
201
            internal static ReleaseProgram clReleaseProgram;
202
            [System.Security.SuppressUnmanagedCodeSecurity()]
203
            internal delegate int ReleaseSampler(IntPtr sampler);
204
            internal static ReleaseSampler clReleaseSampler;
205
            [System.Security.SuppressUnmanagedCodeSecurity()]
206
            internal delegate int RetainCommandQueue(IntPtr command_queue);
207
            internal static RetainCommandQueue clRetainCommandQueue;
208
            [System.Security.SuppressUnmanagedCodeSecurity()]
209
            internal delegate int RetainContext(IntPtr context);
210
            internal static RetainContext clRetainContext;
211
            [System.Security.SuppressUnmanagedCodeSecurity()]
212
            internal delegate int RetainEvent(IntPtr @event);
213
            internal static RetainEvent clRetainEvent;
214
            [System.Security.SuppressUnmanagedCodeSecurity()]
215
            internal delegate int RetainKernel(IntPtr kernel);
216
            internal static RetainKernel clRetainKernel;
217
            [System.Security.SuppressUnmanagedCodeSecurity()]
218
            internal delegate int RetainMemObject(IntPtr memobj);
219
            internal static RetainMemObject clRetainMemObject;
220
            [System.Security.SuppressUnmanagedCodeSecurity()]
221
            internal delegate int RetainProgram(IntPtr program);
222
            internal static RetainProgram clRetainProgram;
223
            [System.Security.SuppressUnmanagedCodeSecurity()]
224
            internal delegate int RetainSampler(IntPtr sampler);
225
            internal static RetainSampler clRetainSampler;
226
            [System.Security.SuppressUnmanagedCodeSecurity()]
227
            internal unsafe delegate int SetCommandQueueProperty(IntPtr command_queue, CommandQueueFlags properties, bool enable, CommandQueueFlags* old_properties);
228
            internal unsafe static SetCommandQueueProperty clSetCommandQueueProperty;
229
            [System.Security.SuppressUnmanagedCodeSecurity()]
230
            internal delegate int SetKernelArg(IntPtr kernel, uint arg_index, IntPtr arg_size, IntPtr arg_value);
231
            internal static SetKernelArg clSetKernelArg;
232
            [System.Security.SuppressUnmanagedCodeSecurity()]
233
            internal delegate int UnloadCompiler();
234
            internal static UnloadCompiler clUnloadCompiler;
235
            [System.Security.SuppressUnmanagedCodeSecurity()]
236
            internal unsafe delegate int WaitForEvents(uint num_events, IntPtr* event_list);
237
            internal unsafe static WaitForEvents clWaitForEvents;
238
        }
239
    }
240
}
241
 
242
#endif