From 412e4955af8684ed82d3d97a670ca55f92b0b74e Mon Sep 17 00:00:00 2001 From: Paul Licameli Date: Sun, 18 Sep 2016 11:19:22 -0400 Subject: [PATCH] Put braces around sub-object initializers --- src/effects/Distortion.cpp | 40 ++++++++++++++++---------------- src/effects/Reverb.cpp | 18 +++++++------- src/effects/VST/VSTControlOSX.mm | 10 ++++++-- 3 files changed, 37 insertions(+), 31 deletions(-) diff --git a/src/effects/Distortion.cpp b/src/effects/Distortion.cpp index 1452b0365..61b6ec772 100644 --- a/src/effects/Distortion.cpp +++ b/src/effects/Distortion.cpp @@ -98,26 +98,26 @@ FactoryPresets[] = // Table DCBlock threshold floor Param1 Param2 Repeats // Defaults: 0 false -6.0 -70.0(off) 50.0 50.0 1 // - XO("Hard clip -12dB, 80% make-up gain"), { 0, 0, -12.0, -70.0, 0.0, 80.0, 0 }, - XO("Soft clip -12dB, 80% make-up gain"), { 1, 0, -12.0, -70.0, 50.0, 80.0, 0 }, - XO("Fuzz Box"), { 1, 0, -30.0, -70.0, 80.0, 80.0, 0 }, - XO("Walkie-talkie"), { 1, 0, -50.0, -70.0, 60.0, 80.0, 0 }, - XO("Blues drive sustain"), { 2, 0, -6.0, -70.0, 30.0, 80.0, 0 }, - XO("Light Crunch Overdrive"), { 3, 0, -6.0, -70.0, 20.0, 80.0, 0 }, - XO("Heavy Overdrive"), { 4, 0, -6.0, -70.0, 90.0, 80.0, 0 }, - XO("3rd Harmonic (Perfect Fifth)"), { 5, 0, -6.0, -70.0, 100.0, 60.0, 0 }, - XO("Valve Overdrive"), { 6, 1, -6.0, -70.0, 30.0, 40.0, 0 }, - XO("2nd Harmonic (Octave)"), { 6, 1, -6.0, -70.0, 50.0, 0.0, 0 }, - XO("Gated Expansion Distortion"), { 7, 0, -6.0, -70.0, 30.0, 80.0, 0 }, - XO("Leveller, Light, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 1 }, - XO("Leveller, Moderate, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 2 }, - XO("Leveller, Heavy, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 3 }, - XO("Leveller, Heavier, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 4 }, - XO("Leveller, Heaviest, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 5 }, - XO("Half-wave Rectifier"), { 9, 0, -6.0, -70.0, 50.0, 50.0, 0 }, - XO("Full-wave Rectifier"), { 9, 0, -6.0, -70.0, 100.0, 50.0, 0 }, - XO("Full-wave Rectifier (DC blocked)"), { 9, 1, -6.0, -70.0, 100.0, 50.0, 0 }, - XO("Percussion Limiter"), {10, 0, -12.0, -70.0, 100.0, 30.0, 0 }, + { XO("Hard clip -12dB, 80% make-up gain"), { 0, 0, -12.0, -70.0, 0.0, 80.0, 0 } }, + { XO("Soft clip -12dB, 80% make-up gain"), { 1, 0, -12.0, -70.0, 50.0, 80.0, 0 } }, + { XO("Fuzz Box"), { 1, 0, -30.0, -70.0, 80.0, 80.0, 0 } }, + { XO("Walkie-talkie"), { 1, 0, -50.0, -70.0, 60.0, 80.0, 0 } }, + { XO("Blues drive sustain"), { 2, 0, -6.0, -70.0, 30.0, 80.0, 0 } }, + { XO("Light Crunch Overdrive"), { 3, 0, -6.0, -70.0, 20.0, 80.0, 0 } }, + { XO("Heavy Overdrive"), { 4, 0, -6.0, -70.0, 90.0, 80.0, 0 } }, + { XO("3rd Harmonic (Perfect Fifth)"), { 5, 0, -6.0, -70.0, 100.0, 60.0, 0 } }, + { XO("Valve Overdrive"), { 6, 1, -6.0, -70.0, 30.0, 40.0, 0 } }, + { XO("2nd Harmonic (Octave)"), { 6, 1, -6.0, -70.0, 50.0, 0.0, 0 } }, + { XO("Gated Expansion Distortion"), { 7, 0, -6.0, -70.0, 30.0, 80.0, 0 } }, + { XO("Leveller, Light, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 1 } }, + { XO("Leveller, Moderate, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 2 } }, + { XO("Leveller, Heavy, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 3 } }, + { XO("Leveller, Heavier, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 4 } }, + { XO("Leveller, Heaviest, -70dB noise floor"), { 8, 0, -6.0, -70.0, 0.0, 50.0, 5 } }, + { XO("Half-wave Rectifier"), { 9, 0, -6.0, -70.0, 50.0, 50.0, 0 } }, + { XO("Full-wave Rectifier"), { 9, 0, -6.0, -70.0, 100.0, 50.0, 0 } }, + { XO("Full-wave Rectifier (DC blocked)"), { 9, 1, -6.0, -70.0, 100.0, 50.0, 0 } }, + { XO("Percussion Limiter"), {10, 0, -12.0, -70.0, 100.0, 30.0, 0 } }, }; const wxString defaultLabel[5] = diff --git a/src/effects/Reverb.cpp b/src/effects/Reverb.cpp index d11e7b55b..5deafd34a 100644 --- a/src/effects/Reverb.cpp +++ b/src/effects/Reverb.cpp @@ -64,15 +64,15 @@ FactoryPresets[] = { // Room Pre Hf Tone Tone Wet Dry Stereo Wet // Name Size, Delay, Reverb, Damping, Low, High, Gain, Gain, Width, Only - XO("Vocal I" ), { 70, 20, 40, 99, 100, 50, -12, 0, 70, false }, - XO("Vocal II"), { 50, 0, 50, 99, 50, 100, -1, -1, 70, false }, - XO("Bathroom"), { 16, 8, 80, 0, 0, 100, -6, 0, 100, false }, - XO("Small Room Bright"), { 30, 10, 50, 50, 50, 100, -1, -1, 100, false }, - XO("Small Room Dark"), { 30, 10, 50, 50, 100, 0, -1, -1, 100, false }, - XO("Medium Room"), { 75, 10, 40, 50, 100, 70, -1, -1, 70, false }, - XO("Large Room"), { 85, 10, 40, 50, 100, 80, 0, -6, 90, false }, - XO("Church Hall"), { 90, 32, 60, 50, 100, 50, 0, -12, 100, false }, - XO("Cathedral"), { 90, 16, 90, 50, 100, 0, 0, -20, 100, false }, + { XO("Vocal I" ), { 70, 20, 40, 99, 100, 50, -12, 0, 70, false } }, + { XO("Vocal II"), { 50, 0, 50, 99, 50, 100, -1, -1, 70, false } }, + { XO("Bathroom"), { 16, 8, 80, 0, 0, 100, -6, 0, 100, false } }, + { XO("Small Room Bright"), { 30, 10, 50, 50, 50, 100, -1, -1, 100, false } }, + { XO("Small Room Dark"), { 30, 10, 50, 50, 100, 0, -1, -1, 100, false } }, + { XO("Medium Room"), { 75, 10, 40, 50, 100, 70, -1, -1, 70, false } }, + { XO("Large Room"), { 85, 10, 40, 50, 100, 80, 0, -6, 90, false } }, + { XO("Church Hall"), { 90, 32, 60, 50, 100, 50, 0, -12, 100, false } }, + { XO("Cathedral"), { 90, 16, 90, 50, 100, 0, 0, -20, 100, false } }, }; struct Reverb_priv_t diff --git a/src/effects/VST/VSTControlOSX.mm b/src/effects/VST/VSTControlOSX.mm index 19c0c5bef..17eeac3c1 100644 --- a/src/effects/VST/VSTControlOSX.mm +++ b/src/effects/VST/VSTControlOSX.mm @@ -143,7 +143,10 @@ void VSTControl::CreateCocoa() // Get the final bounds of the effect GUI mLink->callDispatcher(effEditGetRect, 0, 0, &rect, 0.0); - NSRect frame = { 0, 0, (CGFloat) rect->right - rect->left, (CGFloat) rect->bottom - rect->top }; + NSRect frame = { + { 0, 0 }, + { (CGFloat) rect->right - rect->left, (CGFloat) rect->bottom - rect->top } + }; [mView setFrame:frame]; @@ -245,7 +248,10 @@ void VSTControl::CreateCarbon() mLink->callDispatcher(effEditGetRect, 0, 0, &rect, 0.0); // Set the size of the scrollview to match - HIRect r = { 0, 0, (CGFloat) rect->right - rect->left, (CGFloat) rect->bottom - rect->top }; + HIRect r = { + { 0, 0 }, + { (CGFloat) rect->right - rect->left, (CGFloat) rect->bottom - rect->top } + }; // One effect, mutagene lipredemuco, doesn't return a valid rect so // try to detect it and use the created view dimensions instead.