forked from Dynamitos/Seele
Trying to fix invalid descriptorlayout
This commit is contained in:
1 parent
79388bf41a
commit
ceee96b462
69 files changed
+1087
-393
No files matched your search
@@ -1,4 +1,5 @@
|
||||
#include "MaterialAsset.h"
|
||||
#include "Graphics/WindowManager.h"
|
||||
|
||||
using namespace Seele;
|
||||
|
||||
@@ -19,3 +20,35 @@ MaterialAsset::MaterialAsset(const std::filesystem::path& fullPath)
|
||||
MaterialAsset::~MaterialAsset()
|
||||
{
|
||||
}
|
||||
|
||||
void MaterialAsset::beginFrame()
|
||||
{
|
||||
descriptorSet->beginFrame();
|
||||
}
|
||||
|
||||
void MaterialAsset::endFrame()
|
||||
{
|
||||
descriptorSet->endFrame();
|
||||
}
|
||||
|
||||
void MaterialAsset::updateDescriptorData()
|
||||
{
|
||||
BulkResourceData uniformUpdate;
|
||||
uniformUpdate.size = uniformDataSize;
|
||||
uniformUpdate.data = uniformData;
|
||||
for(auto param : parameters)
|
||||
{
|
||||
param->updateDescriptorSet(descriptorSet, uniformData);
|
||||
}
|
||||
if(uniformUpdate.size != 0)
|
||||
{
|
||||
uniformBuffer->updateContents(uniformUpdate);
|
||||
descriptorSet->updateBuffer(0, uniformBuffer);
|
||||
}
|
||||
descriptorSet->writeChanges();
|
||||
}
|
||||
|
||||
Gfx::PDescriptorSet MaterialAsset::getDescriptor() const
|
||||
{
|
||||
return descriptorSet;
|
||||
}
|
||||
Reference in new issue
Block a user