final case class Mix(elem: GE) extends SingleOut with Product with Serializable
A graph element that mixes the channels of a signal together. It works like the sclang counterpart.
The Mix
companion object contains various useful mixing idioms:
- Mix.tabulate(n: Int)(fun: Int => GE)
: corresponds to Seq.tabulate
and to Array.fill
in sclang.
- Mix.fill(n: Int)(thunk: => GE)
: corresponds to Seq.fill
.
- Mix.seq(elems: GE*)
: A shortcut for Mix(GESeq(elems: _*))
.
A separate graph element is Mix.mono
.
Mix.mono(elem: GE)
flattens all channels of
the input element before summing them, guaranteeing that the result is monophonic.
Finally, Mix.fold
is an idiom that not actually adds elements,
but recursively folds them. Thus,
Mix.fold(elem: GE, n: Int)(fun: GE => GE)
is equivalent to
(1 to n).foldLeft(elem) { (res, _) => fun(res) }
Mix.fold
is often used in the SuperCollider examples to apply a filtering
process such as reverberation several times. For cases where the iteration
index is needed, the full form as shown above can be used instead.
- elem
the graph element whose channels to mix together
- See also
- Alphabetic
- By Inheritance
- Mix
- Serializable
- SingleOut
- SomeOut
- Lazy
- GE
- UGenSource
- Expander
- Lazy
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
- val elem: GE
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- lazy val hashCode: Int
- Definition Classes
- UGenSource → AnyRef → Any
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def makeUGen(args: Vec[UGenIn]): UGenInLike
- Attributes
- protected
- Definition Classes
- Mix → UGenSource
- def makeUGens: UGenInLike
Abstract method which must be implemented by creating the actual
UGen
s during expansion. - final def name: String
- Definition Classes
- UGenSource
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- def rate: MaybeRate
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- Mix → AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated