Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Bronco 40 amps, cabinets and effects #21

Open
wants to merge 2 commits into
base: 20-bronco
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 49 additions & 1 deletion include/com/IdLookup.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ namespace plug
case 0x6d:
return amps::METAL_2000;

// Bronco amps
// Bronco 40 amps
case 0x96:
return amps::RUMBLE;
case 0x97:
Expand Down Expand Up @@ -159,6 +159,17 @@ namespace plug
return effects::FENDER_63_SPRING_REVERB;
case 0x0b:
return effects::FENDER_65_SPRING_REVERB;

// Bronco 40 effects
case 0xc6:
return effects::MODERN_BASS_OVERDRIVE;
case 0xc3:
return effects::OVERDRIVE_BASS;
case 0xc7:
return effects::FUZZ_BASS;
case 0xba:
return effects::GREENBOX;

default:
throw std::invalid_argument{"Invalid effect id: " + std::to_string(id)};
}
Expand All @@ -167,6 +178,7 @@ namespace plug

constexpr cabinets lookupCabinetById(std::uint8_t id)
{
/*
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do not comment out code, but add those values below (as with the amps).

switch (id)
{
case 0x00:
Expand Down Expand Up @@ -197,6 +209,42 @@ namespace plug
return cabinets::cabSS112;
default:
throw std::invalid_argument{"Invalid cabinet id: " + std::to_string(id)};
}
*/

// Bronco 40 cabinets
switch (id)
{
case 0x00:
return cabinets::OFF;
case 0x01:
return cabinets::cab1x10M;
case 0x02:
return cabinets::cab2x10M;
case 0x03:
return cabinets::cab4x10M;
case 0x04:
return cabinets::cab4x10H;
case 0x05:
return cabinets::cab8x10M;
case 0x06:
return cabinets::cab8x10V;
case 0x07:
return cabinets::cab1x12M;
case 0x08:
return cabinets::cab2x15V;
case 0x09:
return cabinets::cab4x12M;
case 0x0a:
return cabinets::cab1x15V;
case 0x0b:
return cabinets::cab1x15M;
case 0x0c:
return cabinets::cab1x18V;
case 0x0d:
return cabinets::cab4x10V;
default:
throw std::invalid_argument{"Invalid cabinet id: " + std::to_string(id)};
}
}

Expand Down
54 changes: 41 additions & 13 deletions include/effects_enum.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,19 @@ namespace plug
// list of all amplifiers
enum class amps
{
FENDER_57_DELUXE,
// Bronco 40 amps
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do not change the existing listing, but append to it's end.

RUMBLE,
FENDER_59_BASSMAN,
BASSMAN_TV,
BASSMAN_300,
KGB_800,
ROCKIN_PEG,
SWR_REDHEAD,
MONSTER,

// Mustang amps
FENDER_57_DELUXE,
// FENDER_59_BASSMAN,
FENDER_57_CHAMP,
FENDER_65_DELUXE_REVERB,
FENDER_65_PRINCETON,
Expand All @@ -40,29 +51,29 @@ namespace plug
BRITISH_70S,
BRITISH_80S,
AMERICAN_90S,
METAL_2000,

// Bronco amps
RUMBLE,
BASSMAN_TV,
BASSMAN_300,
KGB_800,
ROCKIN_PEG,
SWR_REDHEAD,
MONSTER
METAL_2000
};


// list of all effects
enum class effects
{
// Bronco 40 effects
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above, please append and do not disable.

EMPTY,
MODERN_BASS_OVERDRIVE,
OVERDRIVE_BASS,
FUZZ_BASS,
GREENBOX,
SIMPLE_COMP,

// Mustang effects
// EMPTY,
OVERDRIVE,
WAH,
TOUCH_WAH,
FUZZ,
FUZZ_TOUCH_WAH,
SIMPLE_COMP,
// SIMPLE_COMP,
COMPRESSOR,

SINE_CHORUS,
Expand Down Expand Up @@ -102,6 +113,7 @@ namespace plug
// list of all cabinets
enum class cabinets
{
/*
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

OFF,
cab57DLX,
cabBSSMN,
Expand All @@ -114,7 +126,23 @@ namespace plug
cab65TWN,
cab4x12V,
cabSS212,
cabSS112
cabSS112,
*/
// Bronco 40 cabinets
OFF,
cab1x10M,
cab2x10M,
cab4x10M,
cab4x10H,
cab4x10V,
cab8x10M,
cab8x10V,
cab1x12M,
cab4x12M,
cab1x15V,
cab1x15M,
cab2x15V,
cab1x18V
};


Expand Down
43 changes: 26 additions & 17 deletions src/ui/amplifier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ namespace plug
: QMainWindow(parent),
ui(std::make_unique<Ui::Amplifier>()),
advanced(std::make_unique<Amp_Advanced>(this)),
amp_num(amps::FENDER_57_DELUXE),
amp_num(amps::FENDER_59_BASSMAN),
gain(0),
volume(0),
treble(0),
Expand Down Expand Up @@ -183,6 +183,8 @@ namespace plug
// set properties
switch (static_cast<amps>(ampValue))
{

/*
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As above.

case amps::FENDER_57_DELUXE:
advanced->change_cabinet(value(cabinets::cab57DLX));
advanced->change_noise_gate(0);
Expand Down Expand Up @@ -266,49 +268,56 @@ namespace plug
setWindowTitle("Amplifier: Metal 2000");
setAccessibleName("Amplifier: Metal 2000");
break;
*/

// TODO: Bronco amps
// TODO: Bronco 40 amps
case amps::RUMBLE:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Btw. do we have to figure out this noise gate setting?

setWindowTitle("Amplifier: Fender Rumble");
setAccessibleName("Amplifier: Fender Rumble");
break;
case amps::FENDER_59_BASSMAN:
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender '59 Bassman");
setAccessibleName("Amplifier: Fender '59 Bassman");
break;
case amps::BASSMAN_TV:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender Bassman TV");
setAccessibleName("Amplifier: Fender Bassman TV");
break;
case amps::BASSMAN_300:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender Bassman 300");
setAccessibleName("Amplifier: Fender Bassman 300");
break;
case amps::KGB_800:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender KGB 800");
setAccessibleName("Amplifier: Fender KGB 800");
setWindowTitle("Amplifier: KGB 800");
setAccessibleName("Amplifier: KGB 800");
break;
case amps::ROCKIN_PEG:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender Rockin' PEG");
setAccessibleName("Amplifier: Fender Rockin' PEG");
setWindowTitle("Amplifier: Rockin' PEG");
setAccessibleName("Amplifier: Rockin' PEG");
break;
case amps::SWR_REDHEAD:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender SWR Redhead");
setAccessibleName("Amplifier: Fender SWR Redhead");
setWindowTitle("Amplifier: SWR Redhead");
setAccessibleName("Amplifier: SWR Redhead");
break;
case amps::MONSTER:
advanced->change_cabinet(value(cabinets::cab65PRN));
advanced->change_cabinet(value(cabinets::OFF));
advanced->change_noise_gate(0);
setWindowTitle("Amplifier: Fender Monster");
setAccessibleName("Amplifier: Fender Monster");
setWindowTitle("Amplifier: Monster");
setAccessibleName("Amplifier: Monster");
break;
default:
break;
Expand Down
47 changes: 47 additions & 0 deletions src/ui/amplifier.ui
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@
<property name="accessibleDescription">
<string>Allows you to choose amplifier to emulate</string>
</property>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As above.


<!--
<property name="maxVisibleItems">
<number>12</number>
</property>
Expand Down Expand Up @@ -116,6 +118,51 @@
<string>Metal 2000</string>
</property>
</item>
-->

<property name="maxVisibleItems">
<number>8</number>
</property>
<item>
<property name="text">
<string>Rumble</string>
</property>
</item>
<item>
<property name="text">
<string>'59 Bassman</string>
</property>
</item>
<item>
<property name="text">
<string>Bassman TV</string>
</property>
</item>
<item>
<property name="text">
<string>Bassman 300</string>
</property>
</item>
<item>
<property name="text">
<string>KGB 800</string>
</property>
</item>
<item>
<property name="text">
<string>Rockin' Peg</string>
</property>
</item>
<item>
<property name="text">
<string>SWR Redhead</string>
</property>
</item>
<item>
<property name="text">
<string>Monster</string>
</property>
</item>
</widget>
</item>
<item>
Expand Down
4 changes: 4 additions & 0 deletions src/ui/defaulteffects.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,10 @@ namespace plug
tr("When you choose an effect you can set precise value of a parameter here")});
break;
case effects::OVERDRIVE:
case effects::MODERN_BASS_OVERDRIVE:
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a Bronce comment to those so we can determine later.

case effects::OVERDRIVE_BASS:
case effects::FUZZ_BASS:
case effects::GREENBOX:
setTexts(ui.get(),
UIText{
tr("&Level"),
Expand Down
32 changes: 31 additions & 1 deletion src/ui/defaulteffects.ui
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,40 @@
<string>None</string>
</property>
</item>

<!-- Bronco 40 effects -->
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remark: The .ui files are created by Qt Designer (usually) , so comments wont last long here. Having the comments in the source files is enough.

<item>
<property name="text">
<string>[1] Modern Bass Overdrive</string>
</property>
</item>
<item>
<property name="text">
<string>[1] Overdrive</string>
</property>
</item>
<item>
<property name="text">
<string>[1] Fuzz</string>
</property>
</item>
<item>
<property name="text">
<string>[1] Greenbox</string>
</property>
</item>
<item>
<property name="text">
<string>[1] Simple Compressor</string>
</property>
</item>

<!--
<item>
<property name="text">
<string>[1] Overdrive</string>
</property>
</item>
<item>
<property name="text">
<string>[1] Fixed Wah</string>
Expand Down Expand Up @@ -86,7 +115,8 @@
<string>[1] Compressor</string>
</property>
</item>
<item>
-->
<item>
<property name="text">
<string>[2] Sine Chorus</string>
</property>
Expand Down
Loading