Multi-thread shaders generation when compiling materials (#3464)
* Stop using members as globals between methods * Multi-thread shaders generation with JobSystem * Pass JobSystem to MaterialBuilder::build() * Fix MeshAssimp to use the new API * Allow the Java API to pass a job system via Engine * Update docs * Apply suggestions from code review Co-authored-by: Philip Rideout <philiprideout@gmail.com>
This commit is contained in:
@@ -299,7 +299,7 @@ static void setup(Engine* engine, View*, Scene* scene) {
|
||||
.parameter(MaterialBuilder::SamplerType::SAMPLER_2D, "baseColorMap");
|
||||
}
|
||||
|
||||
Package pkg = builder.build();
|
||||
Package pkg = builder.build(engine->getJobSystem());
|
||||
|
||||
g_material = Material::Builder().package(pkg.getData(), pkg.getSize())
|
||||
.build(*engine);
|
||||
|
||||
Reference in New Issue
Block a user