Method: Ray::PixelBus#resize

Defined in:
ext/pixel_bus.c

#resize(new_size) ⇒ Object

Changes the capacity of the buffer

This method needs to copy the buffers content onto client memory, and is thus signinficantly slower than #resize!. It should not be called if the current content of the buffer doesn’t need to be read anymore.

Parameters:

  • new_size (Integer)

    New capacity of the buffer

See Also:



84
85
86
87
88
# File 'ext/pixel_bus.c', line 84

static
VALUE ray_pixel_bus_resize(VALUE self, VALUE size) {
  say_pixel_bus_resize(ray_rb2pixel_bus(self), NUM2ULONG(size));
  return self;
}