diff options
Diffstat (limited to 'plugins/MacAU/Bite')
-rwxr-xr-x | plugins/MacAU/Bite/Bite.cpp | 27 | ||||
-rwxr-xr-x | plugins/MacAU/Bite/Bite.h | 5 | ||||
-rwxr-xr-x | plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.pbxuser | 42 | ||||
-rwxr-xr-x | plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.perspectivev3 | 39 |
4 files changed, 47 insertions, 66 deletions
diff --git a/plugins/MacAU/Bite/Bite.cpp b/plugins/MacAU/Bite/Bite.cpp index 99d3134..c34bb3d 100755 --- a/plugins/MacAU/Bite/Bite.cpp +++ b/plugins/MacAU/Bite/Bite.cpp @@ -175,10 +175,7 @@ void Bite::BiteKernel::Reset() sampleG = 0.0; sampleH = 0.0; sampleI = 0.0; - - fpNShapeA = 0.0; - fpNShapeB = 0.0; - fpFlip = true; + fpNShape = 0.0; } //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -203,10 +200,7 @@ void Bite::BiteKernel::Process( const Float32 *inSourceP, Float64 midC; Float64 midD; Float64 trigger; - Float64 result; - Float64 fpOld = 0.618033988749894848204586; //golden ratio! - Float64 fpNew = 1.0 - fpOld; - Float32 fpTemp; + long double result; while (nSampleFrames-- > 0) { sampleI = sampleH; @@ -273,18 +267,11 @@ void Bite::BiteKernel::Process( const Float32 *inSourceP, if (outputgain != 1.0) result *= outputgain; - if (fpFlip) { - fpTemp = result; - fpNShapeA = (fpNShapeA*fpOld)+((result-fpTemp)*fpNew); - result += fpNShapeA; - } - else { - fpTemp = result; - fpNShapeB = (fpNShapeB*fpOld)+((result-fpTemp)*fpNew); - result += fpNShapeB; - } - fpFlip = not fpFlip; - //end noise shaping on 32 bit output + //32 bit dither, made small and tidy. + int expon; frexpf((Float32)result, &expon); + long double dither = (rand()/(RAND_MAX*7.737125245533627e+25))*pow(2,expon+62); + result += (dither-fpNShape); fpNShape = dither; + //end 32 bit dither *destP = result; //output. diff --git a/plugins/MacAU/Bite/Bite.h b/plugins/MacAU/Bite/Bite.h index c7a5b06..b36870b 100755 --- a/plugins/MacAU/Bite/Bite.h +++ b/plugins/MacAU/Bite/Bite.h @@ -138,10 +138,7 @@ public: Float64 sampleG; Float64 sampleH; Float64 sampleI; - Float64 fpNShapeA; - Float64 fpNShapeB; - bool fpFlip; - + Float64 fpNShape; }; }; diff --git a/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.pbxuser b/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.pbxuser index f9c81c4..b8ac588 100755 --- a/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.pbxuser +++ b/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.pbxuser @@ -49,43 +49,43 @@ PBXFileDataSource_Warnings_ColumnID, ); }; - PBXPerProjectTemplateStateSaveDate = 528421171; - PBXWorkspaceStateSaveDate = 528421171; + PBXPerProjectTemplateStateSaveDate = 569589737; + PBXWorkspaceStateSaveDate = 569589737; }; perUserProjectItems = { - 8B9D63401F7C8264007AB60F /* PBXTextBookmark */ = 8B9D63401F7C8264007AB60F /* PBXTextBookmark */; - 8B9D72D41F7F114A007AB60F /* PBXTextBookmark */ = 8B9D72D41F7F114A007AB60F /* PBXTextBookmark */; + 8B79281021F3405A006E9731 /* PBXTextBookmark */ = 8B79281021F3405A006E9731 /* PBXTextBookmark */; + 8B79281521F34076006E9731 /* PBXTextBookmark */ = 8B79281521F34076006E9731 /* PBXTextBookmark */; }; sourceControlManager = 8BD3CCB8148830B20062E48C /* Source Control */; userBuildSettings = { }; }; - 8B9D63401F7C8264007AB60F /* PBXTextBookmark */ = { + 8B79281021F3405A006E9731 /* PBXTextBookmark */ = { isa = PBXTextBookmark; fRef = 8BA05A660720730100365D66 /* Bite.cpp */; - name = "Bite.cpp: 289"; + name = "Bite.cpp: 276"; rLen = 0; - rLoc = 11935; + rLoc = 11735; rType = 0; - vrLen = 433; - vrLoc = 10004; + vrLen = 155; + vrLoc = 10210; }; - 8B9D72D41F7F114A007AB60F /* PBXTextBookmark */ = { + 8B79281521F34076006E9731 /* PBXTextBookmark */ = { isa = PBXTextBookmark; fRef = 8BA05A660720730100365D66 /* Bite.cpp */; - name = "Bite.cpp: 289"; + name = "Bite.cpp: 276"; rLen = 0; - rLoc = 11935; + rLoc = 11735; rType = 0; - vrLen = 402; - vrLoc = 10035; + vrLen = 155; + vrLoc = 10210; }; 8BA05A660720730100365D66 /* Bite.cpp */ = { uiCtxt = { - sepNavIntBoundsRect = "{{0, 0}, {677, 3913}}"; - sepNavSelRange = "{11935, 0}"; - sepNavVisRange = "{10035, 402}"; - sepNavWindowFrame = "{{295, 66}, {1145, 812}}"; + sepNavIntBoundsRect = "{{0, 0}, {677, 3887}}"; + sepNavSelRange = "{11735, 0}"; + sepNavVisRange = "{10210, 155}"; + sepNavWindowFrame = "{{170, 66}, {1145, 812}}"; }; }; 8BA05A670720730100365D66 /* Bite.exp */ = { @@ -106,9 +106,9 @@ }; 8BC6025B073B072D006C4272 /* Bite.h */ = { uiCtxt = { - sepNavIntBoundsRect = "{{0, 0}, {1062, 1963}}"; - sepNavSelRange = "{5170, 171}"; - sepNavVisRange = "{3327, 1862}"; + sepNavIntBoundsRect = "{{0, 0}, {1062, 1898}}"; + sepNavSelRange = "{5360, 0}"; + sepNavVisRange = "{3983, 1489}"; sepNavWindowFrame = "{{382, 39}, {1053, 839}}"; }; }; diff --git a/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.perspectivev3 b/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.perspectivev3 index 87e6588..4e2e4c6 100755 --- a/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.perspectivev3 +++ b/plugins/MacAU/Bite/Bite.xcodeproj/christopherjohnson.perspectivev3 @@ -225,8 +225,8 @@ <array/> <key>PerspectiveWidths</key> <array> - <integer>-1</integer> - <integer>-1</integer> + <integer>810</integer> + <integer>810</integer> </array> <key>Perspectives</key> <array> @@ -256,8 +256,6 @@ <key>Layout</key> <array> <dict> - <key>BecomeActive</key> - <true/> <key>ContentConfiguration</key> <dict> <key>PBXBottomSmartGroupGIDs</key> @@ -324,7 +322,7 @@ <real>185</real> </array> <key>RubberWindowFrame</key> - <string>612 285 810 487 0 0 1440 878 </string> + <string>476 284 810 487 0 0 1440 878 </string> </dict> <key>Module</key> <string>PBXSmartGroupTreeModule</string> @@ -352,10 +350,10 @@ <key>_historyCapacity</key> <integer>0</integer> <key>bookmark</key> - <string>8B9D72D41F7F114A007AB60F</string> + <string>8B79281521F34076006E9731</string> <key>history</key> <array> - <string>8B9D63401F7C8264007AB60F</string> + <string>8B79281021F3405A006E9731</string> </array> </dict> <key>SplitCount</key> @@ -369,18 +367,18 @@ <key>GeometryConfiguration</key> <dict> <key>Frame</key> - <string>{{0, 0}, {603, 102}}</string> + <string>{{0, 0}, {603, 86}}</string> <key>RubberWindowFrame</key> - <string>612 285 810 487 0 0 1440 878 </string> + <string>476 284 810 487 0 0 1440 878 </string> </dict> <key>Module</key> <string>PBXNavigatorGroup</string> <key>Proportion</key> - <string>102pt</string> + <string>86pt</string> </dict> <dict> <key>Proportion</key> - <string>339pt</string> + <string>355pt</string> <key>Tabs</key> <array> <dict> @@ -394,9 +392,7 @@ <key>GeometryConfiguration</key> <dict> <key>Frame</key> - <string>{{10, 27}, {603, 312}}</string> - <key>RubberWindowFrame</key> - <string>612 285 810 487 0 0 1440 878 </string> + <string>{{10, 27}, {603, 328}}</string> </dict> <key>Module</key> <string>XCDetailModule</string> @@ -450,7 +446,9 @@ <key>GeometryConfiguration</key> <dict> <key>Frame</key> - <string>{{10, 27}, {603, 414}}</string> + <string>{{10, 27}, {603, 328}}</string> + <key>RubberWindowFrame</key> + <string>476 284 810 487 0 0 1440 878 </string> </dict> <key>Module</key> <string>PBXBuildResultsModule</string> @@ -478,11 +476,11 @@ </array> <key>TableOfContents</key> <array> - <string>8B9D72D51F7F114A007AB60F</string> + <string>8B79281621F34076006E9731</string> <string>1CA23ED40692098700951B8B</string> - <string>8B9D72D61F7F114A007AB60F</string> + <string>8B79281721F34076006E9731</string> <string>8BDB25E81EAA6D6E001F42B2</string> - <string>8B9D72D71F7F114A007AB60F</string> + <string>8B79281821F34076006E9731</string> <string>1CA23EDF0692099D00951B8B</string> <string>1CA23EE00692099D00951B8B</string> <string>1CA23EE10692099D00951B8B</string> @@ -635,7 +633,7 @@ <key>StatusbarIsVisible</key> <true/> <key>TimeStamp</key> - <real>528421194.64885902</real> + <real>569589878.38768005</real> <key>ToolbarConfigUserDefaultsMinorVersion</key> <string>2</string> <key>ToolbarDisplayMode</key> @@ -652,11 +650,10 @@ <integer>5</integer> <key>WindowOrderList</key> <array> - <string>8B9D72D81F7F114A007AB60F</string> <string>/Users/christopherjohnson/Desktop/MacAU/Bite/Bite.xcodeproj</string> </array> <key>WindowString</key> - <string>612 285 810 487 0 0 1440 878 </string> + <string>476 284 810 487 0 0 1440 878 </string> <key>WindowToolsV3</key> <array> <dict> |