First working effects with new pipeline

This commit is contained in:
Simon Lübeß
2024-08-22 00:34:20 +02:00
parent 7b7a3dc645
commit 66e62f42ec
20 changed files with 652 additions and 43 deletions
+11 -3
View File
@@ -65,7 +65,7 @@ public class Effect : Asset
}
}
Dictionary<String, TextureEntry> _textures ~ delete _;
Dictionary<String, TextureEntry> _textures ~ DeleteDictionaryAndKeys!(_);
public Dictionary<String, TextureEntry> Textures => _textures;
@@ -99,7 +99,8 @@ public class Effect : Asset
MergeResources();
}
[Obsolete("", false)]
public this(Stream data, StringView assetIdentifier, IContentManager contentManager)
{
Debug.Profiler.ProfileResourceFunction!();
@@ -115,6 +116,13 @@ public class Effect : Asset
MergeResources();
}
public this()
{
_bufferCollection = new BufferCollection();
_variables = new BufferVariableCollection(false);
_textures = new Dictionary<String, TextureEntry>();
}
public ~this()
{
Debug.Profiler.ProfileResourceFunction!();
@@ -668,7 +676,7 @@ public class Effect : Asset
}
// save entry
_textures[shaderEntry.Name] = entry;
_textures[new String(shaderEntry.Name)] = entry;
}
}
}