Surface

trait Surface

A Surface is an object that contains a set of pixels.

class Object
trait Matchable
class Any

Value members

Abstract methods

def getPixel(x: Int, y: Int): Option[Color]

Gets the color from the this surface. This operation can be perfomance intensive, so it might be worthwile to either use getPixels to fetch multiple pixels at the same time or to implement this operation on the application code.

Gets the color from the this surface. This operation can be perfomance intensive, so it might be worthwile to either use getPixels to fetch multiple pixels at the same time or to implement this operation on the application code.

Value parameters:
x

pixel x position

y

pixel y position

Returns:

pixel color

Returns the pixels from this surface. This operation can be perfomance intensive, so it might be worthwile to implement this operation on the application code.

Returns the pixels from this surface. This operation can be perfomance intensive, so it might be worthwile to implement this operation on the application code.

Returns:

color matrix

def height: Int

The surface height

The surface height

def width: Int

The surface width

The surface width

Concrete methods

Copies this surface into a new surface stored in RAM

Copies this surface into a new surface stored in RAM

Returns a view over this surface.

Returns a view over this surface.

Operations performed on a view are executed in a defered fashion.