… | |
… | |
28 | specific device ("compiling and linking"), also binary programs. For each |
28 | specific device ("compiling and linking"), also binary programs. For each |
29 | kernel function in a program you can then create an OpenCL::Kernel object |
29 | kernel function in a program you can then create an OpenCL::Kernel object |
30 | which represents basically a function call with argument values. |
30 | which represents basically a function call with argument values. |
31 | |
31 | |
32 | OpenCL::Memory objects of various flavours: OpenCL::Buffers objects (flat |
32 | OpenCL::Memory objects of various flavours: OpenCL::Buffers objects (flat |
33 | memory areas, think array) and OpenCL::Image objects (think 2d or 3d |
33 | memory areas, think arrays or structs) and OpenCL::Image objects (think 2d |
34 | array) for bulk data and input and output for kernels. |
34 | or 3d array) for bulk data and input and output for kernels. |
35 | |
35 | |
36 | OpenCL::Sampler objects, which are kind of like texture filter modes in |
36 | OpenCL::Sampler objects, which are kind of like texture filter modes in |
37 | OpenGL. |
37 | OpenGL. |
38 | |
38 | |
39 | OpenCL::Queue objects - command queues, which allow you to submit memory |
39 | OpenCL::Queue objects - command queues, which allow you to submit memory |
… | |
… | |
51 | http://www.khronos.org/registry/cl/specs/opencl-1.1.pdf |
51 | http://www.khronos.org/registry/cl/specs/opencl-1.1.pdf |
52 | |
52 | |
53 | OpenCL manpages: |
53 | OpenCL manpages: |
54 | |
54 | |
55 | http://www.khronos.org/registry/cl/sdk/1.1/docs/man/xhtml/ |
55 | http://www.khronos.org/registry/cl/sdk/1.1/docs/man/xhtml/ |
|
|
56 | |
|
|
57 | Here's a tutorial from AMD (very AMD-centric, too), not sure how useful it |
|
|
58 | is, but at least it's free of charge: |
|
|
59 | |
|
|
60 | http://developer.amd.com/zones/OpenCLZone/courses/Documents/Introduction_to_OpenCL_Programming%20Training_Guide%20%28201005%29.pdf |
|
|
61 | |
|
|
62 | If you are into UML class diagrams, the following diagram might help - if |
|
|
63 | not, it will be mildly cofusing: |
|
|
64 | |
|
|
65 | http://www.khronos.org/registry/cl/sdk/1.1/docs/man/xhtml/classDiagram.html |
56 | |
66 | |
57 | =head1 BASIC WORKFLOW |
67 | =head1 BASIC WORKFLOW |
58 | |
68 | |
59 | To get something done, you basically have to do this once (refer to the |
69 | To get something done, you basically have to do this once (refer to the |
60 | examples below for actual code, this is just a high-level description): |
70 | examples below for actual code, this is just a high-level description): |