1. IMPORTANT:
    We launched a new online community and this space is now closed. This community will be available as a read-only resources until further notice.
    JOIN US HERE

Solved Compressor Gain Reduction Meter

Discussion in 'Scripting Workshop' started by 3001 Studios, Oct 26, 2021.

  1. 3001 Studios

    3001 Studios NI Product Owner

    Messages:
    9
    Can someone point me to a script to attach a meter to a compressor gain reduction data? Thanks

    KSP Manual - The level meters can be attached to the output of an instrument bus and the instrument main output. They can also be attached to compressor and limiter effects to display gain reduction data, with the ability to set min and max display values and inverting the display by using $CONTROL_PAR_RANGE_MIN and $CONTROL_PAR_RANGE_MAX.
     
  2. corbo-billy

    corbo-billy NI Product Owner

    Messages:
    652
    Examples are provided for various level meters on page 126/127 of this KSP Reference Manual _
     
  3. 3001 Studios

    3001 Studios NI Product Owner

    Messages:
    9
    Yes but none for gain reduction data (at least that I can decipher). Those all appear to be various output level meters.
     
  4. EvilDragon

    EvilDragon Well-Known Member

    Messages:
    19,938
  5. Studiowaves

    Studiowaves NI Product Owner

    Messages:
    711
    Use the standard built in module, panel, meter. It works fine, attach it to the line decreasing the volume, Just invert the colors to be off when on, when the amp line drops the colors appear. very simple. upload_2021-10-26_5-14-10.png
     
  6. EvilDragon

    EvilDragon Well-Known Member

    Messages:
    19,938
    Studiowaves This is Kontakt subforum, not Reaktor. :)
     
  7. 3001 Studios

    3001 Studios NI Product Owner

    Messages:
    9
    Page 118-119
    All the examples I see are for output levels not for compressor gain reduction:

    attach_level_meter(get_ui_id($inst_output_lvl),-1,-1,$channel,-1)
    attach_level_meter(get_ui_id($bus_output_lvl),-1,-1,$channel,$bus_idx)
    attach_level_meter(get_ui_id($mainfx_output_lvl),-1,$slot_idx,$channel,-2)
    attach_level_meter(get_ui_id($busfx_output_lvl),-1,$slot_idx,$channel,$bus_idx)
    attach_level_meter(get_ui_id($groupfx_output_lvl),$group_idx,$slot_idx,$channel,-1)
     
  8. Studiowaves

    Studiowaves NI Product Owner

    Messages:
    711
    Sorry, don't know how that happened.
     
  9. corbo-billy

    corbo-billy NI Product Owner

    Messages:
    652
    Yes, ok: but if you insert this compressor instead of the effect slot corresponding to the $ slot_idx you designated earlier, it may work.
     
  10. Reylon

    Reylon NI Product Owner

    Messages:
    124
    This should work. I used the Feedback Compressor on Insert Effects in the first slot (0 based)

    Code:
    on init
        declare ui_label $InstOutput (1,1)
        declare ui_level_meter $inst_output_lvl
        attach_level_meter(get_ui_id($inst_output_lvl),-1,0,0,$NI_LEVEL_METER_INSERT)
    end on