]> git.tdb.fi Git - libs/gl.git/commitdiff
Add SplatMaterial to Resources
authorMikko Rasa <tdb@tdb.fi>
Tue, 11 Oct 2022 08:48:49 +0000 (11:48 +0300)
committerMikko Rasa <tdb@tdb.fi>
Tue, 11 Oct 2022 08:51:18 +0000 (11:51 +0300)
source/resources/resources.cpp

index ab4b0a8dd52d560282ef7ca11d1afcd41c1c6cda..1a580552f878ff846bbc7b80f42de1ab8ab67747 100644 (file)
@@ -24,6 +24,7 @@
 #include "resources.h"
 #include "sampler.h"
 #include "simplescene.h"
+#include "splatmaterial.h"
 #include "technique.h"
 #include "texture1d.h"
 #include "texture2d.h"
@@ -84,6 +85,9 @@ Resources::Resources(bool set_as_global):
                .notify(&set_debug_name<Sampler>);
        add_type<SimpleScene>().base<Scene>().base<Renderable>().suffix(".scene")
                .creator([this](const string &n) -> SimpleScene * { create_generic<Scene>(n); return 0; });
+       add_type<SplatMaterial>().base<Material>().suffix(".mat")
+               .creator([this](const string &n) -> SplatMaterial * { create_generic<Material>(n); return 0; })
+               .notify(&set_debug_name<Material>);
        add_type<Technique>().suffix(".tech").keyword("technique")
                .notify(&set_debug_name<Technique>);
        add_type<Texture1D>().base<Texture>().suffix(".tex")