A procedurally generated infinite surface.
Can be clipped to create a surface.
Attributes
- Companion
- object
- Graph
-
- Supertypes
- Self type
Members list
Value members
Concrete methods
Returns the color at position (x, y).
Returns the color at position (x, y).
Attributes
Clips this plane to a chosen rectangle
Clips this plane to a chosen rectangle
Value parameters
- ch
-
clip height
- cw
-
clip width
- cx
-
leftmost pixel on the surface
- cy
-
topmost pixel on the surface
Attributes
Coflatmaps this plane with a Plane => Color function. Effectively, each pixel of the new plane is computed from a translated plane, which can be used to implement convolutions.
Coflatmaps this plane with a Plane => Color function. Effectively, each pixel of the new plane is computed from a translated plane, which can be used to implement convolutions.
Attributes
Contramaps the positions from this plane.
Contramaps the positions from this plane.
Attributes
Contramaps this plane using a matrix instead of a function.
Contramaps this plane using a matrix instead of a function.
This method can be chained multiple times efficiently.
Note that this is contramaping. The operation is applied as [a b c] [dx] = [sx] [d e f] [dy] [sy] [0 0 1] [ 1] [ 1]
Where (sx,sy) are the positions in the original plane and (dx, dy) are the positions in the new plane.
This means that you need to invert the transformations to use the common transformation matrices.
For example, the matrix:
[2 0 0] [dx] = [sx] [0 2 0] [dy] [sy] [0 0 1] [ 1] [ 1]
Will scale down the image, not scale up.
Attributes
Inverts a plane color.
Inverts a plane color.
Attributes
Maps the colors from this plane.
Maps the colors from this plane.
Attributes
Overlays a surface on top of this plane.
Overlays a surface on top of this plane.
Similar to MutableSurface#blit, but for surface views and planes.
Value parameters
- blendMode
-
blend strategy to use
- that
-
surface to overlay
- x
-
leftmost pixel on the destination plane
- y
-
topmost pixel on the destination plane
Attributes
Rotates a plane by a certain angle (clockwise).
Rotates a plane by a certain angle (clockwise).
Attributes
Converts this plane to a RAM surface, assuming (0, 0) as the top-left corner.
Converts this plane to a RAM surface, assuming (0, 0) as the top-left corner.
Value parameters
- height
-
surface height
- width
-
surface width
Attributes
Converts this plane to a surface view, assuming (0, 0) as the top-left corner.
Converts this plane to a surface view, assuming (0, 0) as the top-left corner.
Value parameters
- height
-
surface view height
- width
-
surface view width
Attributes
Translates a plane.
Translates a plane.
Attributes
Transposes a plane (switches the x and y coordinates).
Transposes a plane (switches the x and y coordinates).
Attributes
Combines this plane with another by combining their colors with the given function.
Combines this plane with another by combining their colors with the given function.
Attributes
Inherited methods
Returns a string representation of the object.
Returns a string representation of the object.
The default representation is platform dependent.
Attributes
- Returns
-
a string representation of the object.
- Definition Classes
-
Function2 -> Any
- Inherited from:
- Function2