HilbertCurve

class Object
trait Matchable
class Any

Type members

Classlikes

final case class From2D(n: I, x: I, y: I) extends SingleOut[Int]

Encodes two dimensional coordinates as one dimensional indices or positions of a Hilbert curve.

Encodes two dimensional coordinates as one dimensional indices or positions of a Hilbert curve.

The output positions are integers between zero (inclusive) and n-times-n (exclusive). The UGen ends when either x or y ends.

Value parameters:
n

the square matrix size, which must be a power of two

x

the integer horizontal coordinate in the n-by-n matrix

y

the integer vertical coordinate in the n-by-n matrix

Companion:
object
object From2D extends ProductReader[From2D]
Companion:
class
final case class To2D(n: I, pos: I) extends MultiOut[Int]

Decodes one dimensional indices or positions of a Hilbert curve to two dimensional coordinates.

Decodes one dimensional indices or positions of a Hilbert curve to two dimensional coordinates.

The output coordinates are integers between zero (inclusive) and n (exclusive). The UGen ends when pos ends.

Value parameters:
n

the square matrix size, which must be a power of two

pos

the integer position on the hilbert curve from zero (inclusive) to n-times-n (exclusive).

Companion:
object
object To2D extends ProductReader[To2D]
Companion:
class