From 6dd021a943e73f08ae71644e8f6d7a788cd4a61c Mon Sep 17 00:00:00 2001 From: Chris Johnson Date: Mon, 22 Jul 2019 13:30:57 -0400 Subject: Bugfix for Mojo! Added dB markings to things and fixed a gain issue on all the VST versions --- plugins/LinuxVST/src/Mojo/Mojo.cpp | 2 +- plugins/LinuxVST/src/Mojo/MojoProc.cpp | 4 +- plugins/MacAU/Mojo/Mojo.cpp | 2 +- .../Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser | 48 ++++++++----- .../christopherjohnson.perspectivev3 | 79 ++++++++++++++++------ .../Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser | 55 ++++++++++++--- .../christopherjohnson.perspectivev3 | 48 +++++++------ plugins/MacVST/Mojo/Mojo.xcodeproj/project.pbxproj | 4 +- plugins/MacVST/Mojo/source/Mojo.cpp | 2 +- plugins/MacVST/Mojo/source/MojoProc.cpp | 4 +- plugins/WinVST/Mojo/Mojo.cpp | 2 +- plugins/WinVST/Mojo/MojoProc.cpp | 4 +- 12 files changed, 176 insertions(+), 78 deletions(-) diff --git a/plugins/LinuxVST/src/Mojo/Mojo.cpp b/plugins/LinuxVST/src/Mojo/Mojo.cpp index bef296a..7b34fba 100755 --- a/plugins/LinuxVST/src/Mojo/Mojo.cpp +++ b/plugins/LinuxVST/src/Mojo/Mojo.cpp @@ -95,7 +95,7 @@ void Mojo::getParameterDisplay(VstInt32 index, char *text) { void Mojo::getParameterLabel(VstInt32 index, char *text) { switch (index) { - case kParamA: vst_strncpy (text, "", kVstMaxParamStrLen); break; + case kParamA: vst_strncpy (text, "dB", kVstMaxParamStrLen); break; default: break; // unknown parameter, shouldn't happen! } } diff --git a/plugins/LinuxVST/src/Mojo/MojoProc.cpp b/plugins/LinuxVST/src/Mojo/MojoProc.cpp index 303de25..60f986d 100755 --- a/plugins/LinuxVST/src/Mojo/MojoProc.cpp +++ b/plugins/LinuxVST/src/Mojo/MojoProc.cpp @@ -14,7 +14,7 @@ void Mojo::processReplacing(float **inputs, float **outputs, VstInt32 sampleFram float* out1 = outputs[0]; float* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { @@ -61,7 +61,7 @@ void Mojo::processDoubleReplacing(double **inputs, double **outputs, VstInt32 sa double* out1 = outputs[0]; double* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { diff --git a/plugins/MacAU/Mojo/Mojo.cpp b/plugins/MacAU/Mojo/Mojo.cpp index 11e9044..19d9db2 100755 --- a/plugins/MacAU/Mojo/Mojo.cpp +++ b/plugins/MacAU/Mojo/Mojo.cpp @@ -98,7 +98,7 @@ ComponentResult Mojo::GetParameterInfo(AudioUnitScope inScope, { case kParam_One: AUBase::FillInParameterName (outParameterInfo, kParameterOneName, false); - outParameterInfo.unit = kAudioUnitParameterUnit_Generic; + outParameterInfo.unit = kAudioUnitParameterUnit_Decibels; outParameterInfo.minValue = -12.0; outParameterInfo.maxValue = 12.0; outParameterInfo.defaultValue = kDefaultValue_ParamOne; diff --git a/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser b/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser index 2676c54..9eb4a63 100755 --- a/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser +++ b/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser @@ -49,37 +49,53 @@ PBXFileDataSource_Warnings_ColumnID, ); }; - PBXPerProjectTemplateStateSaveDate = 584930184; - PBXWorkspaceStateSaveDate = 584930184; + PBXPerProjectTemplateStateSaveDate = 585505543; + PBXWorkspaceStateSaveDate = 585505543; }; perUserProjectItems = { - 8B52129922DD6151009B824C /* PBXTextBookmark */ = 8B52129922DD6151009B824C /* PBXTextBookmark */; - 8B52129A22DD6151009B824C /* PBXTextBookmark */ = 8B52129A22DD6151009B824C /* PBXTextBookmark */; + 8B52136522E61B30009B824C /* PBXBookmark */ = 8B52136522E61B30009B824C /* PBXBookmark */; + 8B52137222E61CAE009B824C /* PBXTextBookmark */ = 8B52137222E61CAE009B824C /* PBXTextBookmark */; + 8B52137922E61CEC009B824C /* PBXTextBookmark */ = 8B52137922E61CEC009B824C /* PBXTextBookmark */; + 8B52137F22E61CEC009B824C /* PBXTextBookmark */ = 8B52137F22E61CEC009B824C /* PBXTextBookmark */; 8B54218D22DD27A60048806E /* PlistBookmark */ = 8B54218D22DD27A60048806E /* PlistBookmark */; }; sourceControlManager = 8BD3CCB8148830B20062E48C /* Source Control */; userBuildSettings = { }; }; - 8B52129922DD6151009B824C /* PBXTextBookmark */ = { + 8B52136522E61B30009B824C /* PBXBookmark */ = { + isa = PBXBookmark; + fRef = 8BA05A660720730100365D66 /* Mojo.cpp */; + }; + 8B52137222E61CAE009B824C /* PBXTextBookmark */ = { isa = PBXTextBookmark; fRef = 8BA05A660720730100365D66 /* Mojo.cpp */; name = "Mojo.cpp: 188"; rLen = 0; - rLoc = 8223; + rLoc = 8224; rType = 0; - vrLen = 586; - vrLoc = 7984; + vrLen = 545; + vrLoc = 8029; }; - 8B52129A22DD6151009B824C /* PBXTextBookmark */ = { + 8B52137922E61CEC009B824C /* PBXTextBookmark */ = { isa = PBXTextBookmark; fRef = 8BA05A660720730100365D66 /* Mojo.cpp */; name = "Mojo.cpp: 188"; rLen = 0; - rLoc = 8223; + rLoc = 8224; + rType = 0; + vrLen = 545; + vrLoc = 8029; + }; + 8B52137F22E61CEC009B824C /* PBXTextBookmark */ = { + isa = PBXTextBookmark; + fRef = 8BA05A660720730100365D66 /* Mojo.cpp */; + name = "Mojo.cpp: 101"; + rLen = 0; + rLoc = 4811; rType = 0; - vrLen = 586; - vrLoc = 7984; + vrLen = 1923; + vrLoc = 3297; }; 8B54218D22DD27A60048806E /* PlistBookmark */ = { isa = PlistBookmark; @@ -95,10 +111,10 @@ }; 8BA05A660720730100365D66 /* Mojo.cpp */ = { uiCtxt = { - sepNavIntBoundsRect = "{{0, 0}, {698, 2717}}"; - sepNavSelRange = "{8223, 0}"; - sepNavVisRange = "{7984, 586}"; - sepNavWindowFrame = "{{661, 58}, {979, 820}}"; + sepNavIntBoundsRect = "{{0, 0}, {698, 2691}}"; + sepNavSelRange = "{8224, 0}"; + sepNavVisRange = "{8029, 545}"; + sepNavWindowFrame = "{{11, 58}, {979, 820}}"; }; }; 8BA05A690720730100365D66 /* MojoVersion.h */ = { diff --git a/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 b/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 index 57bcd3f..96ca876 100755 --- a/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 +++ b/plugins/MacAU/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 @@ -222,7 +222,48 @@ OpenEditors - + + + Content + + PBXProjectModuleGUID + 8B52137D22E61CEC009B824C + PBXProjectModuleLabel + Mojo.cpp + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 8B52137E22E61CEC009B824C + PBXProjectModuleLabel + Mojo.cpp + _historyCapacity + 0 + bookmark + 8B52137F22E61CEC009B824C + history + + 8B52136522E61B30009B824C + + + SplitCount + 1 + + StatusBarVisibility + + + Geometry + + Frame + {{0, 20}, {979, 723}} + PBXModuleWindowStatusBarHidden2 + + RubberWindowFrame + 11 114 979 764 0 0 1440 878 + + + PerspectiveWidths 841 @@ -256,8 +297,6 @@ Layout - BecomeActive - ContentConfiguration PBXBottomSmartGroupGIDs @@ -326,7 +365,7 @@ 288 RubberWindowFrame - 589 224 841 654 0 0 1440 878 + 65 212 841 654 0 0 1440 878 Module PBXSmartGroupTreeModule @@ -354,11 +393,11 @@ _historyCapacity 0 bookmark - 8B52129A22DD6151009B824C + 8B52137922E61CEC009B824C history 8B54218D22DD27A60048806E - 8B52129922DD6151009B824C + 8B52137222E61CAE009B824C SplitCount @@ -372,18 +411,18 @@ GeometryConfiguration Frame - {{0, 0}, {531, 216}} + {{0, 0}, {531, 202}} RubberWindowFrame - 589 224 841 654 0 0 1440 878 + 65 212 841 654 0 0 1440 878 Module PBXNavigatorGroup Proportion - 216pt + 202pt Proportion - 392pt + 406pt Tabs @@ -397,9 +436,7 @@ GeometryConfiguration Frame - {{10, 27}, {531, 365}} - RubberWindowFrame - 589 224 841 654 0 0 1440 878 + {{10, 27}, {531, 379}} Module XCDetailModule @@ -453,7 +490,9 @@ GeometryConfiguration Frame - {{10, 27}, {531, 339}} + {{10, 27}, {531, 379}} + RubberWindowFrame + 65 212 841 654 0 0 1440 878 Module PBXBuildResultsModule @@ -481,11 +520,11 @@ TableOfContents - 8B52129B22DD6151009B824C + 8B52137A22E61CEC009B824C 1CA23ED40692098700951B8B - 8B52129C22DD6151009B824C + 8B52137B22E61CEC009B824C 8BD7274A1D46E5A5000176F0 - 8B52129D22DD6151009B824C + 8B52137C22E61CEC009B824C 1CA23EDF0692099D00951B8B 1CA23EE00692099D00951B8B 1CA23EE10692099D00951B8B @@ -658,7 +697,7 @@ StatusbarIsVisible TimeStamp - 584933713.32986498 + 585506028.90447104 ToolbarConfigUserDefaultsMinorVersion 2 ToolbarDisplayMode @@ -675,11 +714,11 @@ 5 WindowOrderList - 8B52129E22DD6151009B824C + 8B52137D22E61CEC009B824C /Users/christopherjohnson/Desktop/Plugins/MacAU/Mojo/Mojo.xcodeproj WindowString - 589 224 841 654 0 0 1440 878 + 65 212 841 654 0 0 1440 878 WindowToolsV3 diff --git a/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser b/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser index 1ffe808..daa329e 100755 --- a/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser +++ b/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.pbxuser @@ -10,7 +10,7 @@ PBXFileTableDataSourceColumnSortingKey = PBXFileDataSource_Filename_ColumnID; PBXFileTableDataSourceColumnWidthsKey = ( 20, - 364, + 399, 20, 48, 43, @@ -49,8 +49,13 @@ PBXFileDataSource_Warnings_ColumnID, ); }; - PBXPerProjectTemplateStateSaveDate = 584928054; - PBXWorkspaceStateSaveDate = 584928054; + PBXPerProjectTemplateStateSaveDate = 585506370; + PBXWorkspaceStateSaveDate = 585506370; + }; + perUserProjectItems = { + 8B52134922E619E3009B824C /* PBXTextBookmark */ = 8B52134922E619E3009B824C /* PBXTextBookmark */; + 8B52134A22E619E3009B824C /* PBXTextBookmark */ = 8B52134A22E619E3009B824C /* PBXTextBookmark */; + 8B5213D022E61F6F009B824C /* PBXTextBookmark */ = 8B5213D022E61F6F009B824C /* PBXTextBookmark */; }; sourceControlManager = 8B02375E1D42B1C400E1E8C8 /* Source Control */; userBuildSettings = { @@ -59,8 +64,8 @@ 2407DEB6089929BA00EB68BF /* Mojo.cpp */ = { uiCtxt = { sepNavIntBoundsRect = "{{0, 0}, {848, 1547}}"; - sepNavSelRange = "{3234, 0}"; - sepNavVisRange = "{2331, 1844}"; + sepNavSelRange = "{3540, 0}"; + sepNavVisRange = "{2378, 1799}"; sepNavWindowFrame = "{{12, 57}, {895, 821}}"; }; }; @@ -74,17 +79,17 @@ }; 24A2FFDB0F90D1DD003BB5A7 /* audioeffectx.cpp */ = { uiCtxt = { - sepNavIntBoundsRect = "{{0, 0}, {859, 20267}}"; + sepNavIntBoundsRect = "{{0, 0}, {838, 19877}}"; sepNavSelRange = "{10616, 0}"; - sepNavVisRange = "{9653, 2414}"; + sepNavVisRange = "{10459, 280}"; sepNavWindowFrame = "{{15, 42}, {895, 831}}"; }; }; 24D8286F09A914000093AEF8 /* MojoProc.cpp */ = { uiCtxt = { - sepNavIntBoundsRect = "{{0, 0}, {848, 1339}}"; - sepNavSelRange = "{691, 514}"; - sepNavVisRange = "{207, 1780}"; + sepNavIntBoundsRect = "{{0, 0}, {712, 1287}}"; + sepNavSelRange = "{708, 514}"; + sepNavVisRange = "{0, 780}"; sepNavWindowFrame = "{{31, 57}, {895, 821}}"; }; }; @@ -102,6 +107,36 @@ isa = PBXCodeSenseManager; indexTemplatePath = ""; }; + 8B52134922E619E3009B824C /* PBXTextBookmark */ = { + isa = PBXTextBookmark; + fRef = 24A2FFDB0F90D1DD003BB5A7 /* audioeffectx.cpp */; + name = "audioeffectx.cpp: 307"; + rLen = 0; + rLoc = 10616; + rType = 0; + vrLen = 280; + vrLoc = 10459; + }; + 8B52134A22E619E3009B824C /* PBXTextBookmark */ = { + isa = PBXTextBookmark; + fRef = 24D8286F09A914000093AEF8 /* MojoProc.cpp */; + name = "MojoProc.cpp: 25"; + rLen = 514; + rLoc = 708; + rType = 0; + vrLen = 780; + vrLoc = 0; + }; + 8B5213D022E61F6F009B824C /* PBXTextBookmark */ = { + isa = PBXTextBookmark; + fRef = 24D8286F09A914000093AEF8 /* MojoProc.cpp */; + name = "MojoProc.cpp: 25"; + rLen = 514; + rLoc = 708; + rType = 0; + vrLen = 780; + vrLoc = 0; + }; 8D01CCC60486CAD60068D4B7 /* Mojo */ = { activeExec = 0; }; diff --git a/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 b/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 index ad52532..92c74c3 100755 --- a/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 +++ b/plugins/MacVST/Mojo/Mojo.xcodeproj/christopherjohnson.perspectivev3 @@ -300,13 +300,13 @@ PBXSmartGroupTreeModuleOutlineStateSelectionKey - 6 + 5 4 0 PBXSmartGroupTreeModuleOutlineStateVisibleRectKey - {{0, 0}, {185, 428}} + {{0, 0}, {185, 707}} PBXTopSmartGroupGIDs @@ -316,14 +316,14 @@ GeometryConfiguration Frame - {{0, 0}, {202, 446}} + {{0, 0}, {202, 725}} GroupTreeTableConfiguration MainColumn 185 RubberWindowFrame - 33 386 810 487 0 0 1440 878 + 33 107 845 766 0 0 1440 878 Module PBXSmartGroupTreeModule @@ -339,7 +339,7 @@ PBXProjectModuleGUID 8B0237581D42B1C400E1E8C8 PBXProjectModuleLabel - Gain.h + MojoProc.cpp PBXSplitModuleInNavigatorKey Split0 @@ -347,7 +347,16 @@ PBXProjectModuleGUID 8B0237591D42B1C400E1E8C8 PBXProjectModuleLabel - Gain.h + MojoProc.cpp + _historyCapacity + 0 + bookmark + 8B5213D022E61F6F009B824C + history + + 8B52134922E619E3009B824C + 8B52134A22E619E3009B824C + SplitCount 1 @@ -360,18 +369,18 @@ GeometryConfiguration Frame - {{0, 0}, {603, 0}} + {{0, 0}, {638, 387}} RubberWindowFrame - 33 386 810 487 0 0 1440 878 + 33 107 845 766 0 0 1440 878 Module PBXNavigatorGroup Proportion - 0pt + 387pt Proportion - 441pt + 333pt Tabs @@ -385,9 +394,9 @@ GeometryConfiguration Frame - {{10, 27}, {603, 414}} + {{10, 27}, {638, 306}} RubberWindowFrame - 33 386 810 487 0 0 1440 878 + 33 107 845 766 0 0 1440 878 Module XCDetailModule @@ -450,7 +459,7 @@ Proportion - 603pt + 638pt Name @@ -469,11 +478,11 @@ TableOfContents - 8B52126222DD4B37009B824C + 8B5213D122E61F6F009B824C 1CA23ED40692098700951B8B - 8B52126322DD4B37009B824C + 8B5213D222E61F6F009B824C 8B0237581D42B1C400E1E8C8 - 8B52126422DD4B37009B824C + 8B5213D322E61F6F009B824C 1CA23EDF0692099D00951B8B 1CA23EE00692099D00951B8B 1CA23EE10692099D00951B8B @@ -626,7 +635,7 @@ StatusbarIsVisible TimeStamp - 584934173.92230296 + 585506671.40982199 ToolbarConfigUserDefaultsMinorVersion 2 ToolbarDisplayMode @@ -643,11 +652,10 @@ 5 WindowOrderList - 8B5212A922DD631D009B824C - /Users/christopherjohnson/Desktop/Mojo/Mojo.xcodeproj + /Users/christopherjohnson/Desktop/Plugins/MacVST/Mojo/Mojo.xcodeproj WindowString - 33 386 810 487 0 0 1440 878 + 33 107 845 766 0 0 1440 878 WindowToolsV3 diff --git a/plugins/MacVST/Mojo/Mojo.xcodeproj/project.pbxproj b/plugins/MacVST/Mojo/Mojo.xcodeproj/project.pbxproj index 80a7d52..391f533 100755 --- a/plugins/MacVST/Mojo/Mojo.xcodeproj/project.pbxproj +++ b/plugins/MacVST/Mojo/Mojo.xcodeproj/project.pbxproj @@ -1894,7 +1894,7 @@ /* End PBXHeadersBuildPhase section */ /* Begin PBXNativeTarget section */ - 8D01CCC60486CAD60068D4B7 /* AudioUnit */ = { + 8D01CCC60486CAD60068D4B7 /* Mojo */ = { isa = PBXNativeTarget; buildConfigurationList = 24BEAAED08919AE700E695F9 /* Build configuration list for PBXNativeTarget "Mojo" */; buildPhases = ( @@ -1947,7 +1947,7 @@ ); projectRoot = ""; targets = ( - 8D01CCC60486CAD60068D4B7 /* AudioUnit */, + 8D01CCC60486CAD60068D4B7 /* Mojo */, ); }; /* End PBXProject section */ diff --git a/plugins/MacVST/Mojo/source/Mojo.cpp b/plugins/MacVST/Mojo/source/Mojo.cpp index bef296a..7b34fba 100755 --- a/plugins/MacVST/Mojo/source/Mojo.cpp +++ b/plugins/MacVST/Mojo/source/Mojo.cpp @@ -95,7 +95,7 @@ void Mojo::getParameterDisplay(VstInt32 index, char *text) { void Mojo::getParameterLabel(VstInt32 index, char *text) { switch (index) { - case kParamA: vst_strncpy (text, "", kVstMaxParamStrLen); break; + case kParamA: vst_strncpy (text, "dB", kVstMaxParamStrLen); break; default: break; // unknown parameter, shouldn't happen! } } diff --git a/plugins/MacVST/Mojo/source/MojoProc.cpp b/plugins/MacVST/Mojo/source/MojoProc.cpp index 303de25..60f986d 100755 --- a/plugins/MacVST/Mojo/source/MojoProc.cpp +++ b/plugins/MacVST/Mojo/source/MojoProc.cpp @@ -14,7 +14,7 @@ void Mojo::processReplacing(float **inputs, float **outputs, VstInt32 sampleFram float* out1 = outputs[0]; float* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { @@ -61,7 +61,7 @@ void Mojo::processDoubleReplacing(double **inputs, double **outputs, VstInt32 sa double* out1 = outputs[0]; double* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { diff --git a/plugins/WinVST/Mojo/Mojo.cpp b/plugins/WinVST/Mojo/Mojo.cpp index bef296a..7b34fba 100755 --- a/plugins/WinVST/Mojo/Mojo.cpp +++ b/plugins/WinVST/Mojo/Mojo.cpp @@ -95,7 +95,7 @@ void Mojo::getParameterDisplay(VstInt32 index, char *text) { void Mojo::getParameterLabel(VstInt32 index, char *text) { switch (index) { - case kParamA: vst_strncpy (text, "", kVstMaxParamStrLen); break; + case kParamA: vst_strncpy (text, "dB", kVstMaxParamStrLen); break; default: break; // unknown parameter, shouldn't happen! } } diff --git a/plugins/WinVST/Mojo/MojoProc.cpp b/plugins/WinVST/Mojo/MojoProc.cpp index 303de25..60f986d 100755 --- a/plugins/WinVST/Mojo/MojoProc.cpp +++ b/plugins/WinVST/Mojo/MojoProc.cpp @@ -14,7 +14,7 @@ void Mojo::processReplacing(float **inputs, float **outputs, VstInt32 sampleFram float* out1 = outputs[0]; float* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { @@ -61,7 +61,7 @@ void Mojo::processDoubleReplacing(double **inputs, double **outputs, VstInt32 sa double* out1 = outputs[0]; double* out2 = outputs[1]; - double gain = (A*24.0)-12.0; + double gain = pow(10.0,((A*24.0)-12.0)/20.0); while (--sampleFrames >= 0) { -- cgit v1.2.3