Add WorldPosition to postfx material scene textures for world-space position sampling at uv

This commit is contained in:
Wojtek Figat
2022-11-21 23:45:13 +01:00
parent 99c296ff3a
commit c55d38534d
7 changed files with 38 additions and 1 deletions

View File

@@ -439,6 +439,7 @@ void MaterialParameter::Bind(BindMeta& meta) const
switch (type)
{
case MaterialSceneTextures::SceneDepth:
case MaterialSceneTextures::WorldPosition:
view = meta.CanSampleDepth
? meta.Buffers->DepthBuffer->GetDescription().Flags & GPUTextureFlags::ReadOnlyDepthView
? meta.Buffers->DepthBuffer->ViewReadOnlyDepth()