Skip to content

Commit 7d99c5b

Browse files
committed
added generate config struct string
1 parent 1845a24 commit 7d99c5b

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

include/nbl/builtin/hlsl/workgroup2/arithmetic_config.hlsl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,8 @@ struct SItemsPerInvoc
181181
};
182182
}
183183

184+
#include <sstream>
185+
#include <string>
184186
struct SArithmeticConfiguration
185187
{
186188
void init(const uint16_t _WorkgroupSizeLog2, const uint16_t _SubgroupSizeLog2, const uint16_t _ItemsPerInvocation)
@@ -203,6 +205,13 @@ struct SArithmeticConfiguration
203205
#undef DEFINE_ASSIGN
204206
}
205207

208+
std::string getConfigTemplateStructString()
209+
{
210+
std::ostringstream os;
211+
os << "nbl::hlsl::workgroup2::ArithmeticConfiguration<" << WorkgroupSizeLog2 << "," << SubgroupSizeLog2 << "," << ItemsPerInvocation_0 << ">;";
212+
return os.str();
213+
}
214+
206215
#define DEFINE_ASSIGN(TYPE,ID,...) TYPE ID;
207216
#include "impl/arithmetic_config_def.hlsl"
208217
#undef DEFINE_ASSIGN

0 commit comments

Comments
 (0)