com.jsyn.unitgen
Class FourWayFade

java.lang.Object
  extended by com.jsyn.unitgen.UnitGenerator
      extended by com.jsyn.unitgen.FourWayFade

public class FourWayFade
extends UnitGenerator

FourWayFade unit.

Mix inputs 0-3 based on the value of two fade ports. You can think of the four inputs arranged clockwise as follows.

      input[0] ---- input[1]
        |             |
        |             |
        |             |
      input[3] ---- input[2]
 
The "fade" port has two parts. Fade[0] fades between the pair of inputs (0&3) and the pair of inputs (1&2). Fade[1] fades between the pair of inputs (0&1) and the pair of inputs (3&2).
    Fade[0]    Fade[1]    Output
      -1         -1       Input[3]
      -1         +1       Input[0]
      +1         -1       Input[2]
      +1         +1       Input[1]
 
 
      -----Fade[0]----->
 
         A
         |
         |
      Fade[1]
         |
         |
 


Field Summary
 UnitInputPort fade
           
 UnitInputPort input
           
 UnitOutputPort output
           
 
Fields inherited from class com.jsyn.unitgen.UnitGenerator
FALSE, TRUE
 
Constructor Summary
FourWayFade()
           
 
Method Summary
 void generate(int start, int limit)
          Perform essential synthesis function.
 
Methods inherited from class com.jsyn.unitgen.UnitGenerator
addPort, convertHalfLifeToMultiplier, flattenOutputs, generate, getFramePeriod, getFrameRate, getPortByName, getPorts, getSynthesisEngine, isEnabled, pullData, setCircuit, setFrameRate, setSynthesisEngine, start, stop
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

input

public UnitInputPort input

fade

public UnitInputPort fade

output

public UnitOutputPort output
Constructor Detail

FourWayFade

public FourWayFade()
Method Detail

generate

public void generate(int start,
                     int limit)
Description copied from class: UnitGenerator
Perform essential synthesis function.

Specified by:
generate in class UnitGenerator
Parameters:
start - offset into port buffers
limit - limit offset into port buffers for loop