Skip to content

Commit

Permalink
fixed right and left channel being switched
Browse files Browse the repository at this point in the history
  • Loading branch information
malte-linke committed Oct 29, 2021
1 parent 002a528 commit d8ee3ac
Show file tree
Hide file tree
Showing 18 changed files with 36 additions and 14 deletions.
Binary file added .vs/Audio Spectrum/v17/.suo
Binary file not shown.
3 changes: 3 additions & 0 deletions PSpectrum v2/PSpectrum v2.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@
<PropertyGroup>
<ApplicationIcon>app.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup>
<StartupObject>PSpectrum.Program</StartupObject>
</PropertyGroup>
<ItemGroup>
<Reference Include="Bass.Net">
<HintPath>..\Bass.Net.dll</HintPath>
Expand Down
4 changes: 2 additions & 2 deletions PSpectrum v2/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.0.0")]
[assembly: AssemblyFileVersion("2.0.0.0")]
[assembly: AssemblyVersion("2.1.0.0")]
[assembly: AssemblyFileVersion("2.1.0.0")]
18 changes: 18 additions & 0 deletions PSpectrum v2/Resources/Web/script.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
/*
* The MIT License (MIT)
*
* Copyright (c) 2021 malte-linke
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
* USE OR OTHER DEALINGS IN THE SOFTWARE.
*/


(() => {
// the rest of the code shouldn't be accessible from the outside (especially for the custom scripts)
document.body.addEventListener("click", () => {
Expand Down
8 changes: 4 additions & 4 deletions PSpectrum v2/Utils/BassGeneric.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,11 @@ public static float[] TranslateData(float[] buffer, int shift = 0, int bufferSiz
int leftMult = ushort.MaxValue / ((audioLeft == 0) ? 1 : audioLeft);
int rightMult = ushort.MaxValue / ((audioRight == 0) ? 1 : audioRight);

// channel left
data[i - shift] = dataTemp * leftMult;

// channel right
data[i - shift + bufferSize / 2] = dataTemp * rightMult;
data[i - shift] = dataTemp * rightMult;

// channel left
data[i - shift + bufferSize / 2] = dataTemp * leftMult;
}

return data;
Expand Down
Binary file modified PSpectrum v2/bin/Debug/PSpectrum.exe
Binary file not shown.
Binary file modified PSpectrum v2/bin/Debug/PSpectrum.pdb
Binary file not shown.
Binary file not shown.
Binary file modified PSpectrum v2/obj/Debug/PSpectrum v2.csproj.AssemblyReference.cache
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10d50c096b708d715043375c2a5c9021a57beddd
dcc3dbfb90a2d7347e3d7a73678774d687f5ba3c
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,11 @@ C:\Users\malte\Desktop\PSpectrum\PSpectrum v2\bin\Debug\PSpectrum.exe.config
C:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.exe.config
C:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.exe
C:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.pdb
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\bin\Debug\PSpectrum.exe.config
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum v2.csproj.AssemblyReference.cache
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum v2.csproj.SuggestedBindingRedirects.cache
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.Properties.Resources.resources
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum v2.csproj.GenerateResource.cache
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum v2.csproj.CoreCompileInputs.cache
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.exe
D:\Users\malte\Desktop\PSpectrum\PSpectrum v2\obj\Debug\PSpectrum.pdb
Binary file modified PSpectrum v2/obj/Debug/PSpectrum v2.csproj.GenerateResource.cache
Binary file not shown.
Empty file.
Binary file modified PSpectrum v2/obj/Debug/PSpectrum.exe
Binary file not shown.
7 changes: 0 additions & 7 deletions PSpectrum v2/obj/Debug/PSpectrum.ilmerge
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@
PSpectrum.exe
Bass.Net.dll
System.Text.Json.dll
System.Memory.dll
System.Text.Encodings.Web.dll
System.Numerics.Vectors.dll
System.Threading.Tasks.Extensions.dll
Microsoft.Bcl.AsyncInterfaces.dll
System.Buffers.dll
CommandLine.dll
Newtonsoft.Json.dll
Binary file modified PSpectrum v2/obj/Debug/PSpectrum.pdb
Binary file not shown.
Binary file not shown.
Binary file modified PSpectrum/obj/Debug/PSpectrum.csproj.AssemblyReference.cache
Binary file not shown.

0 comments on commit d8ee3ac

Please sign in to comment.