Core/AppFilesystemComponent: Add support for default resource parameters

This commit is contained in:
SirLynix
2023-01-28 11:27:49 +01:00
parent 60c00068ca
commit d27ca55943
24 changed files with 364 additions and 85 deletions

View File

@@ -3,6 +3,7 @@
// For conditions of distribution and use, see copyright notice in Config.hpp
#include <Nazara/Graphics/Graphics.hpp>
#include <Nazara/Core/AppFilesystemComponent.hpp>
#include <Nazara/Graphics/GuillotineTextureAtlas.hpp>
#include <Nazara/Graphics/MaterialInstance.hpp>
#include <Nazara/Graphics/MaterialPipeline.hpp>
@@ -174,6 +175,14 @@ namespace Nz
m_defaultTextures = DefaultTextures{};
}
void Graphics::RegisterComponent(AppFilesystemComponent& component)
{
TextureParams defaultTexParams;
defaultTexParams.renderDevice = m_renderDevice;
component.SetDefaultResourceParameters<Texture>(defaultTexParams);
}
void Graphics::BuildBlitPipeline()
{
RenderPipelineLayoutInfo layoutInfo;