class ChunkyPNG::Canvas
def [](x, y)
- See: #get_pixel -
Raises:
-
(ChunkyPNG::OutOfBounds)
- when the coordinates are outside of the
Returns:
-
(Integer)
- The current color value at the provided coordinates.
Parameters:
-
y
(Integer
) -- The y-coordinate of the pixel (row) -
x
(Integer
) -- The x-coordinate of the pixel (column)
def [](x, y) assert_xy!(x, y) @pixels[y * width + x] end