summaryrefslogtreecommitdiff
path: root/src/render_assets.h
diff options
context:
space:
mode:
authorChuyan Zhang <me@zcy.moe>2024-10-06 11:43:15 -0700
committerChuyan Zhang <me@zcy.moe>2024-10-06 11:43:15 -0700
commit60b9692af28a353c4e5813d1723422477e31f433 (patch)
treee776799b962d3ce179abab5f751904a46e1439c4 /src/render_assets.h
parent9ed211d1ca084b25d1780da3bde19e9da64d4a4a (diff)
downloadiris-60b9692af28a353c4e5813d1723422477e31f433.tar.gz
iris-60b9692af28a353c4e5813d1723422477e31f433.zip
Add material texture loadglTF-load
Diffstat (limited to 'src/render_assets.h')
-rw-r--r--src/render_assets.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/render_assets.h b/src/render_assets.h
index 113084a..1819271 100644
--- a/src/render_assets.h
+++ b/src/render_assets.h
@@ -27,9 +27,32 @@ struct Material {
glm::vec4 base_color;
float metallic;
float roughness;
+
+ int32_t base_color_texture;
+ int32_t metallic_roughness_texture;
+ int32_t normal_texture;
+ int32_t occulsion_texture;
+ int32_t emissive_texture;
+};
+
+
+struct Image {
+ std::vector<uint8_t> data;
+ glm::uvec3 extent;
+ int32_t bits_per_channel;
+};
+
+struct Sampler2D {
+ int32_t min_filter;
+ int32_t mag_filter;
+ int32_t wrap_s;
+ int32_t wrap_t;
};
struct Texture {
+ std::string name;
+ Image image;
+ Sampler2D sampler;
};
struct Camera {