opencl_ruby_ffi 0.98 → 0.99

Sign up to get free protection for your applications and to get access to all the features.
@@ -65,7 +65,7 @@ module OpenCL
65
65
  flags = OpenCL.get_flags( options )
66
66
  host_ptr = options[:host_ptr]
67
67
  error = FFI::MemoryPointer::new( :cl_int )
68
- img_ptr = OpenCL.clCreateImage2D( context, flags, format, width, heigh, row_pitch, host_ptr, error )
68
+ img_ptr = OpenCL.clCreateImage2D( context, flags, format, width, height, row_pitch, host_ptr, error )
69
69
  OpenCL.error_check(error.read_cl_int)
70
70
  return OpenCL::Image::new(img_ptr, false)
71
71
  end
@@ -96,7 +96,7 @@ module OpenCL
96
96
  flags = OpenCL.get_flags( options )
97
97
  host_ptr = options[:host_ptr]
98
98
  error = FFI::MemoryPointer::new( :cl_int )
99
- img_ptr = OpenCL.clCreateImage3D( context, fs, format, width, heigh, depth, row_pitch, slice_pitch, d, error )
99
+ img_ptr = OpenCL.clCreateImage3D( context, fs, format, width, height, depth, row_pitch, slice_pitch, d, error )
100
100
  OpenCL.error_check(error.read_cl_int)
101
101
  return OpenCL::Image::new(img_ptr, false)
102
102
  end
@@ -227,12 +227,12 @@ module OpenCL
227
227
  if image.type == OpenCL::Mem::IMAGE1D_ARRAY then
228
228
  region[1].write_size_t( image.array_size - origin[1].read_size_t )
229
229
  else
230
- region[1].write_size_t( image.height ? image.height - origin[1].read_size_t : 1 )
230
+ region[1].write_size_t( image.height != 0 ? image.height - origin[1].read_size_t : 1 )
231
231
  end
232
232
  if image.type == OpenCL::Mem::IMAGE2D_ARRAY then
233
233
  region[2].write_size_t( image.array_size - origin[2].read_size_t )
234
234
  else
235
- region[2].write_size_t( image.depth ? image.depth - origin[2].read_size_t : 1 )
235
+ region[2].write_size_t( image.depth != 0 ? image.depth - origin[2].read_size_t : 1 )
236
236
  end
237
237
  end
238
238
  return [origin, region]
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'opencl_ruby_ffi'
3
- s.version = "0.98"
3
+ s.version = "0.99"
4
4
  s.author = "Brice Videau"
5
5
  s.email = "brice.videau@imag.fr"
6
6
  s.homepage = "https://forge.imag.fr/projects/opencl-ruby/"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opencl_ruby_ffi
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.98'
4
+ version: '0.99'
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-06-05 00:00:00.000000000 Z
12
+ date: 2014-06-30 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: narray