-- | Mixer Opcodes
module CsoundExpr.Opcodes.MixerOpcodes.MixerOpcodes
    (mixerSend,
     mixerReceive,
     mixerSetLevel,
     mixerSetLevel_i,
     mixerGetLevel,
     mixerClear)
where



import CsoundExpr.Base.Types
import CsoundExpr.Base.MultiOut
import CsoundExpr.Base.SideEffect
import CsoundExpr.Base.UserDefined



-- | * opcode : MixerSend
--  
--  
-- * syntax : 
--  
--  >   MixerSend asignal, isend, ibuss, ichannel
--  
--  
-- * description : 
--  
--  Mixes an arate signal into a channel of a buss.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerSend.html>
 
mixerSend :: Arate -> Irate -> Irate -> Irate -> SignalOut
mixerSend a0signal i1send i2buss i3channel
  = outOpcode "MixerSend" args
  where args = [to a0signal, to i1send, to i2buss, to i3channel]


-- | * opcode : MixerReceive
--  
--  
-- * syntax : 
--  
--  >   asignal MixerReceive ibuss, ichannel
--  
--  
-- * description : 
--  
--  Receives an arate signal that has been mixed onto a channel of a
-- buss.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerReceive.html>
 
mixerReceive :: Irate -> Irate -> Arate
mixerReceive i0buss i1channel = opcode "MixerReceive" args
  where args = [to i0buss, to i1channel]


-- | * opcode : MixerSetLevel
--  
--  
-- * syntax : 
--  
--  >   MixerSetLevel isend, ibuss, kgain
--  
--  
-- * description : 
--  
--  Sets the level at which signals from the send are added to the
-- buss. The actual sending of the signal to the buss is performed
-- by the MixerSend opcode.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerSetLevel.html>
 
mixerSetLevel :: (K k0) => Irate -> Irate -> k0 -> SignalOut
mixerSetLevel i0send i1buss k2gain = outOpcode "MixerSetLevel" args
  where args = [to i0send, to i1buss, to k2gain]


-- | * opcode : MixerSetLevel_i
--  
--  
-- * syntax : 
--  
--  >   MixerSetLevel_i isend, ibuss, igain
--  
--  
-- * description : 
--  
--  Sets the level at which signals from the send are added to the
-- buss. This opcode, because all parameters are irate, may be used
-- in the orchestra header. The actual sending of the signal to the
-- buss is performed by the MixerSend opcode.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerSetLevel_i.html>
 
mixerSetLevel_i :: Irate -> Irate -> Irate -> SignalOut
mixerSetLevel_i i0send i1buss i2gain
  = outOpcode "MixerSetLevel_i" args
  where args = [to i0send, to i1buss, to i2gain]


-- | * opcode : MixerGetLevel
--  
--  
-- * syntax : 
--  
--  >   kgain MixerGetLevel isend, ibuss
--  
--  
-- * description : 
--  
--  Gets the level at which signals from the send are being added to
-- the buss. The actual sending of the signal to the buss is
-- performed by the MixerSend opcode.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerGetLevel.html>
 
mixerGetLevel :: Irate -> Irate -> Krate
mixerGetLevel i0send i1buss = opcode "MixerGetLevel" args
  where args = [to i0send, to i1buss]


-- | * opcode : MixerClear
--  
--  
-- * syntax : 
--  
--  >   MixerClear
--  
--  
-- * description : 
--  
--  Resets all channels of a buss to 0.
--  
--  
-- * url : <http://www.csounds.com/manual/html/MixerClear.html>
 
mixerClear :: SignalOut
mixerClear = outOpcode "MixerClear" args
  where args = []