Divooka Reference

Coordinates

4 nodes

On this page 4

Circular Inversion

Function

Turns the plane inside out about a circle: a point near the centre goes far away and a far point comes close, while the circle itself stays where it is.

Signature
CircularInversion -> Vector 2D
    UV: Vector 2D
    radius: Number
    center: Vector 2D
Vector2D CircularInversion(
    Vector2D uv,
    double radius = 1,
    Vector2D center)

Parameters

nametypedefaultdescription
UVVector 2D—The point.
radiusNumber1The circle that stays in place.
centerVector 2D—The circle's centre, which goes to infinity.

Returns

UVVector 2D
Ships with
Divooka Compute
Graph kinds
Flows Function Events Routine Constructs StateMachineState
Declared by
Coordinates
Package
GPU Kernels

Grid

Function

Divides the plane into square cells and answers where in its cell a point is, so whatever reads the result repeats in every cell.

Signature
Grid -> (UV: Vector 2D, xIndex: Number, yIndex: Number, center: Vector 2D)
    UV: Vector 2D
    cells: Number
Vector2D Grid(
    Vector2D uv,
    double cells,
    out double xIndex,
    out double yIndex,
    out Vector2D center)

Parameters

nametypedefaultdescription
UVVector 2D—The point.
cellsNumber—How many cells span the shorter side of the picture; one cell is centred on the origin.

Returns

UVVector 2D
xIndexNumber
yIndexNumber
centerVector 2D
Ships with
Divooka Compute
Graph kinds
Flows Function Events Routine Constructs StateMachineState
Declared by
Coordinates
Package
GPU Kernels

Kaleidoscope

Function

Folds the plane into mirrored wedges around the origin, as a kaleidoscope's mirrors do: whatever is in one half-wedge appears in all of them.

Signature
Kaleidoscope -> Vector 2D
    UV: Vector 2D
    splits: Number
    angle: Number
Vector2D Kaleidoscope(
    Vector2D uv,
    double splits = 6,
    double angle = 0)

Parameters

nametypedefaultdescription
UVVector 2D—The point.
splitsNumber6How many wedges the circle is divided into.
angleNumber0Turns the wedges, in radians.

Returns

UVVector 2D
Ships with
Divooka Compute
Graph kinds
Flows Function Events Routine Constructs StateMachineState
Declared by
Coordinates
Package
GPU Kernels

Zoom

Function

Magnifies around a centre: a zoom of 2 shows everything twice as large.

Signature
Zoom -> Vector 2D
    UV: Vector 2D
    zoom: Number
    center: Vector 2D
Vector2D Zoom(Vector2D uv, double zoom = 1, Vector2D center)

Parameters

nametypedefaultdescription
UVVector 2D—The point.
zoomNumber1How much to magnify; above 1 enlarges, below 1 shrinks.
centerVector 2D—The point that stays where it is.

Returns

UVVector 2D
Ships with
Divooka Compute
Graph kinds
Flows Function Events Routine Constructs StateMachineState
Declared by
Coordinates
Package
GPU Kernels