Skip to content

Commit

Permalink
add integrated fft textures to default shader
Browse files Browse the repository at this point in the history
  • Loading branch information
Gargaj committed Apr 8, 2017
1 parent 8dc5612 commit 3c4c7f2
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/platform_glfw/Renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ namespace Renderer
"\n"
"uniform sampler1D texFFT; // towards 0.0 is bass / lower freq, towards 1.0 is higher / treble freq\n"
"uniform sampler1D texFFTSmoothed; // this one has longer falloff and less harsh transients\n"
"uniform sampler1D texFFTIntegrated; // this is continually increasing\n"
"{%textures:begin%}" // leave off \n here
"uniform sampler2D {%textures:name%};\n"
"{%textures:end%}" // leave off \n here
Expand Down
1 change: 1 addition & 0 deletions src/platform_w32_dx11/Renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ namespace Renderer
"{%textures:end%}" // leave off \n here
"Texture1D texFFT; // towards 0.0 is bass / lower freq, towards 1.0 is higher / treble freq\n"
"Texture1D texFFTSmoothed; // this one has longer falloff and less harsh transients\n"
"Texture1D texFFTIntegrated; // this is continually increasing\n"
"SamplerState smp;\n"
"\n"
"cbuffer constants\n"
Expand Down
2 changes: 2 additions & 0 deletions src/platform_w32_dx9/Renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ namespace Renderer
"// towards 0.0 is bass / lower freq, towards 1.0 is higher / treble freq\n"
"texture texFFTSmoothedT; sampler1D texFFTSmoothed = sampler_state { Texture = <texFFTSmoothedT>; }; \n"
"// this one has longer falloff and less harsh transients\n"
"texture texFFTIntegratedT; sampler1D texFFTIntegrated = sampler_state { Texture = <texFFTIntegratedT>; }; \n"
"// this is continually increasing\n"
"\n"
"{%textures:begin%}" // leave off \n here
"texture raw{%textures:name%}; sampler2D {%textures:name%} = sampler_state { Texture = <raw{%textures:name%}>; };\n"
Expand Down

0 comments on commit 3c4c7f2

Please sign in to comment.