Skip to content

Commit

Permalink
Update I forgot what
Browse files Browse the repository at this point in the history
  • Loading branch information
angelocarly committed Feb 19, 2024
1 parent 4b17557 commit 14f3034
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
5 changes: 3 additions & 2 deletions burst/ShaderEditor.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ namespace burst
class ShaderEditor
{
public:
ShaderEditor( vkt::Device const & inDevice );
ShaderEditor( vkt::Device const & inDevice, std::string inPath );
~ShaderEditor();

void Update();
void Display();
void BindShader();
std::string GetPath() const;

vkt::ComputePipelinePtr GetShader() const;
void CompileShader();

private:

Expand All @@ -38,7 +40,6 @@ namespace burst
*/
void Save();

void CompileShader();

void Init( std::string inPath );

Expand Down
10 changes: 8 additions & 2 deletions burst/Source/ShaderEditor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
#include <array>
#include <spdlog/spdlog.h>

burst::ShaderEditor::ShaderEditor( vkt::Device const & inDevice )
burst::ShaderEditor::ShaderEditor( vkt::Device const & inDevice, std::string inPath )
:
mDevice( inDevice ),
mPath( "test.comp.glsl" )
mPath( inPath )
{
Init( mPath );
}
Expand Down Expand Up @@ -178,3 +178,9 @@ burst::ShaderEditor::GetShader() const
{
return mCompute;
}

std::string
burst::ShaderEditor::GetPath() const
{
return mPath;
}
1 change: 1 addition & 0 deletions resources/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ function( compile_shaders PROJECT INPUT_DIRECTORY OUTPUT_DIRECTORY GLSL_SOURCE_F
foreach( GLSL ${GLSL_SOURCE_FILES} )

get_filename_component( FILE_NAME ${GLSL} NAME )

set(
SPIRV
"${OUTPUT_DIRECTORY}/${FILE_NAME}.spv"
Expand Down

0 comments on commit 14f3034

Please sign in to comment.