Class: OpenCL::Mem::Flags
- Defined in:
- lib/opencl_ruby_ffi/opencl_ruby_ffi_base_gen.rb
Overview
Bitfield that maps the :cl_mem_flags type
Constant Summary collapse
- READ_WRITE =
(1 << 0)
- WRITE_ONLY =
(1 << 1)
- READ_ONLY =
(1 << 2)
- USE_HOST_PTR =
(1 << 3)
- ALLOC_HOST_PTR =
(1 << 4)
- COPY_HOST_PTR =
(1 << 5)
- HOST_WRITE_ONLY =
(1 << 7)
- HOST_READ_ONLY =
(1 << 8)
- HOST_NO_ACCESS =
(1 << 9)
- SVM_FINE_GRAIN_BUFFER =
(1 << 10)
- SVM_ATOMICS =
(1 << 11)
- KERNEL_READ_AND_WRITE =
(1 << 12)
Instance Method Summary collapse
-
#names ⇒ Object
Returns an Array of String representing the different flags set.
Methods inherited from Bitfield
#&, #^, #coerce, #flags, #flags=, #include?, #initialize, #inspect, #to_i, #to_int, #to_s, #|
Constructor Details
This class inherits a constructor from OpenCL::Bitfield
Instance Method Details
#names ⇒ Object
Returns an Array of String representing the different flags set
1304 1305 1306 1307 1308 1309 1310 |
# File 'lib/opencl_ruby_ffi/opencl_ruby_ffi_base_gen.rb', line 1304 def names fs = [] %w( READ_WRITE WRITE_ONLY READ_ONLY USE_HOST_PTR ALLOC_HOST_PTR COPY_HOST_PTR HOST_WRITE_ONLY HOST_READ_ONLY HOST_NO_ACCESS ).each { |f| fs.push(f) if self.include?( self.class.const_get(f) ) } return fs end |