Documentation ¶
Index ¶
- Constants
- type ComputeGPU
- func (cp ComputeGPU) AddSourceFile(filename string) error
- func (cp ComputeGPU) AddSourceString(source string, key string) error
- func (cp ComputeGPU) BuildProgram(include_dir string) error
- func (cp ComputeGPU) Context() *OpenCL
- func (cp ComputeGPU) Descriptor() compute.Descriptor
- func (cp ComputeGPU) Get() compute.Descriptor
- func (cp ComputeGPU) HasDeviceContext() bool
- func (cp ComputeGPU) Log() string
- func (cp ComputeGPU) PassFloatBuffer(cpu_buffer []float32, name string) error
- func (cp ComputeGPU) PassIntBuffer(cpu_buffer []int, name string) error
- func (cp ComputeGPU) PassLayoutBuffer(data interface{}, bytes int, name string) error
- func (cp ComputeGPU) Queue(name string) error
- func (cp ComputeGPU) ReadFloatBuffer(cpu_buffer []float32, name string) error
- func (cp ComputeGPU) ReadIntBuffer(cpu_buffer []int, name string) error
- func (cp ComputeGPU) RegisterBuffer(bytes_size int, t int, name string) error
- func (cp ComputeGPU) RegisterGLBuffer(gl_buffer_id uint32, size int, name string) error
- func (cp ComputeGPU) RegisterKernel(name string) bool
- func (cp ComputeGPU) Set(d compute.Descriptor)
- func (cp ComputeGPU) SetArgs(name string, args ...interface{}) error
- func (p ComputeGPU) SetDescriptor(desc *compute.Descriptor)
- func (cp ComputeGPU) ValidState() bool
- type OpenCL
Constants ¶
View Source
const ( OK = 0 ACK = 1 WAIT = 2 RUN = 3 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ComputeGPU ¶
type ComputeGPU struct {
// contains filtered or unexported fields
}
func New_ComputeGPU ¶
func New_ComputeGPU(mCompute *ComputeGPU, descriptor *compute.Descriptor, context *OpenCL) *ComputeGPU
Go will release the referenced C pointer device objects so high level code
must retrieve the context and pass down contextually to the GPU class
func (ComputeGPU) AddSourceFile ¶
func (cp ComputeGPU) AddSourceFile(filename string) error
Creates source from file
func (ComputeGPU) AddSourceString ¶
func (cp ComputeGPU) AddSourceString(source string, key string) error
func (ComputeGPU) BuildProgram ¶
func (cp ComputeGPU) BuildProgram(include_dir string) error
func (ComputeGPU) Context ¶
func (cp ComputeGPU) Context() *OpenCL
func (ComputeGPU) Descriptor ¶
func (cp ComputeGPU) Descriptor() compute.Descriptor
func (ComputeGPU) Get ¶
func (cp ComputeGPU) Get() compute.Descriptor
func (ComputeGPU) Log ¶
func (cp ComputeGPU) Log() string
func (ComputeGPU) PassFloatBuffer ¶
func (cp ComputeGPU) PassFloatBuffer(cpu_buffer []float32, name string) error
func (ComputeGPU) PassIntBuffer ¶
func (cp ComputeGPU) PassIntBuffer(cpu_buffer []int, name string) error
func (ComputeGPU) PassLayoutBuffer ¶
func (cp ComputeGPU) PassLayoutBuffer(data interface{}, bytes int, name string) error
func (ComputeGPU) Queue ¶
func (cp ComputeGPU) Queue(name string) error
------------------------------------------- GPU Contextual Commands - Execution Path
-------------------------------------------
func (ComputeGPU) ReadFloatBuffer ¶
func (cp ComputeGPU) ReadFloatBuffer(cpu_buffer []float32, name string) error
func (ComputeGPU) ReadIntBuffer ¶
func (cp ComputeGPU) ReadIntBuffer(cpu_buffer []int, name string) error
func (ComputeGPU) RegisterBuffer ¶
func (cp ComputeGPU) RegisterBuffer(bytes_size int, t int, name string) error
Buffer Routines first argument is the GPU Mapped Buffer ID which also maps to a Buffer Address Copy Functions copy from GPU memory to CPU Memory. Pass copies from CPU
func (ComputeGPU) RegisterGLBuffer ¶
func (cp ComputeGPU) RegisterGLBuffer(gl_buffer_id uint32, size int, name string) error
func (ComputeGPU) RegisterKernel ¶
func (cp ComputeGPU) RegisterKernel(name string) bool
----------------------------------------
Kernels() - Maps a list of compiled Kernel functions to their referent integer IDs for recall and identification @return map[string]int the list of compiled kernel functions and their unique refrence IDs ----------------------------------------
func (ComputeGPU) Set ¶
func (cp ComputeGPU) Set(d compute.Descriptor)
func (ComputeGPU) SetArgs ¶
func (cp ComputeGPU) SetArgs(name string, args ...interface{}) error
func (ComputeGPU) SetDescriptor ¶
func (p ComputeGPU) SetDescriptor(desc *compute.Descriptor)
Click to show internal directories.
Click to hide internal directories.