<effect>
  <name>Compressor-X</name>
  <enabled>true</enabled>
  <numIns>2</numIns>
  <numOuts>2</numOuts>
  <code>krms1	rms ain1
arms1	upsamp krms1

aout1 init 0
aout2 init 0

if &lt;CompType&gt; == 0 then
	aout1	compress ain1, ain1, &lt;Threshhold&gt;, &lt;LowKnee&gt;, &lt;HighKnee&gt;, &lt;Ratio&gt;, &lt;Attack&gt;, &lt;Release&gt;, .05
else
	aout1	compress ain1, arms1, &lt;Threshhold&gt;, &lt;LowKnee&gt;, &lt;HighKnee&gt;, &lt;Ratio&gt;, &lt;Attack&gt;, &lt;Release&gt;, .05
endif
	
krms2	rms ain2
arms2	upsamp krms2

if &lt;CompType&gt; == 0 then
	aout2	compress ain2, ain2, &lt;Threshhold&gt;, &lt;LowKnee&gt;, &lt;HighKnee&gt;, &lt;Ratio&gt;, &lt;Attack&gt;, &lt;Release&gt;, .05
else
	aout2	compress ain2, arms2, &lt;Threshhold&gt;, &lt;LowKnee&gt;, &lt;HighKnee&gt;, &lt;Ratio&gt;, &lt;Attack&gt;, &lt;Release&gt;, .05
endif

aout1	= aout1 * &lt;MakeUp&gt;
aout2	= aout2 * &lt;MakeUp&gt;

;aout1 compress ain1, ain2, </code>
  <comments>This compressor introduces a look-ahead delay of 0.05s which you should compensate for with an artificially added delay to all the tracks that dont have compression on. Based around compress opcode. Switchable peak/RMS compression (if you can tell the difference).</comments>
  <opcodeList/>
  <graphicInterface editEnabled='true'>
    <uniqueNameManager nameIndex='-1' defaultPrefix='bsbObj'/>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>Threshhold</objectName>
      <x>0</x>
      <y>0</y>
      <automationAllowed>true</automationAllowed>
      <minimum>-90.0</minimum>
      <maximum>90.0</maximum>
      <resolution>0.1</resolution>
      <value>0.0</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>256</x>
      <y>8</y>
      <label>Threshhold</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>LowKnee</objectName>
      <x>0</x>
      <y>36</y>
      <automationAllowed>true</automationAllowed>
      <minimum>0.0</minimum>
      <maximum>90.0</maximum>
      <resolution>0.1</resolution>
      <value>48.0</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>258</x>
      <y>42</y>
      <label>LowKnee</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>HighKnee</objectName>
      <x>0</x>
      <y>72</y>
      <automationAllowed>true</automationAllowed>
      <minimum>0.0</minimum>
      <maximum>90.0</maximum>
      <resolution>0.1</resolution>
      <value>60.0</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>257</x>
      <y>78</y>
      <label>HighKnee</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>Ratio</objectName>
      <x>0</x>
      <y>108</y>
      <automationAllowed>true</automationAllowed>
      <minimum>1.0</minimum>
      <maximum>10.0</maximum>
      <resolution>0.1</resolution>
      <value>1.5</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>257</x>
      <y>115</y>
      <label>Ratio</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>Attack</objectName>
      <x>0</x>
      <y>145</y>
      <automationAllowed>true</automationAllowed>
      <minimum>0.0</minimum>
      <maximum>0.1</maximum>
      <resolution>0.0010</resolution>
      <value>0.010000001</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>257</x>
      <y>150</y>
      <label>Attack</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>Release</objectName>
      <x>0</x>
      <y>181</y>
      <automationAllowed>true</automationAllowed>
      <minimum>0.0</minimum>
      <maximum>0.2</maximum>
      <resolution>0.0010</resolution>
      <value>0.080000006</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>257</x>
      <y>185</y>
      <label>Release</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>256</x>
      <y>223</y>
      <label>MakeUp</label>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBHSlider'>
      <objectName>MakeUp</objectName>
      <x>0</x>
      <y>216</y>
      <automationAllowed>true</automationAllowed>
      <minimum>0.0</minimum>
      <maximum>5.0</maximum>
      <resolution>0.1</resolution>
      <value>1.0</value>
      <sliderWidth>200</sliderWidth>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBDropdown'>
      <objectName>CompType</objectName>
      <x>198</x>
      <y>253</y>
      <bsbDropdownItemList>
        <bsbDropdownItem>
          <name>Peak</name>
          <value>0</value>
        </bsbDropdownItem>
        <bsbDropdownItem>
          <name>RMS</name>
          <value>1</value>
        </bsbDropdownItem>
      </bsbDropdownItemList>
      <selectedIndex>1</selectedIndex>
    </bsbObject>
    <bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel'>
      <objectName></objectName>
      <x>8</x>
      <y>258</y>
      <label>Select compression type:</label>
    </bsbObject>
  </graphicInterface>
  <bsbParameterList>
    <parameter uniqueId='-1246492883' name='Attack' label='' min='0.0' max='0.1' resolution='0.0010' automationEnabled='false'>
      <line name='' version='2' max='0.1' min='0.0' resolution='0.0010' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='0.010000001'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492887' name='HighKnee' label='' min='0.0' max='90.0' resolution='0.1' automationEnabled='false'>
      <line name='' version='2' max='90.0' min='0.0' resolution='0.1' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='60.0'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492889' name='LowKnee' label='' min='0.0' max='90.0' resolution='0.1' automationEnabled='false'>
      <line name='' version='2' max='90.0' min='0.0' resolution='0.1' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='48.0'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492879' name='MakeUp' label='' min='0.0' max='5.0' resolution='0.1' automationEnabled='false'>
      <line name='' version='2' max='5.0' min='0.0' resolution='0.1' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='1.0'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492885' name='Ratio' label='' min='1.0' max='10.0' resolution='0.1' automationEnabled='false'>
      <line name='' version='2' max='10.0' min='1.0' resolution='0.1' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='1.5'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492881' name='Release' label='' min='0.0' max='0.2' resolution='0.0010' automationEnabled='false'>
      <line name='' version='2' max='0.2' min='0.0' resolution='0.0010' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='0.080000006'/>
      </line>
    </parameter>
    <parameter uniqueId='-1246492891' name='Threshhold' label='' min='-90.0' max='90.0' resolution='0.1' automationEnabled='false'>
      <line name='' version='2' max='90.0' min='-90.0' resolution='0.1' color='-8355712' rightBound='false'>
        <linePoint x='0.0' y='0.0'/>
      </line>
    </parameter>
  </bsbParameterList>
</effect>