lib/opencl_ruby_ffi/Device.rb
def platform
      @_platform ||= begin
        ptr = MemoryPointer::new( OpenCL::Platform )
        error = OpenCL.clGetDeviceInfo(self, PLATFORM, OpenCL::Platform.size, ptr, nil)
        error_check(error)
        OpenCL::Platform::new(ptr.read_pointer)
      end
    end
# Returns the Platform the Device belongs to
Returns the Platform the Device belongs to
Returns the Platform the Device belongs to
def platform
      @_platform ||= begin
        ptr = MemoryPointer::new( OpenCL::Platform )
        error = OpenCL.clGetDeviceInfo(self, PLATFORM, OpenCL::Platform.size, ptr, nil)
        error_check(error)
        OpenCL::Platform::new(ptr.read_pointer)
      end
    end
def platform @_platform ||= begin ptr = MemoryPointer :: new ( OpenCL :: Platform ) error = OpenCL . clGetDeviceInfo ( self , PLATFORM , OpenCL :: Platform . size , ptr , nil ) error_check ( error ) OpenCL :: Platform :: new ( ptr . read_pointer ) end end
Returns the Platform the Device belongs to
Returns the Platform the Device belongs to