diff --git a/.vscode/settings.json b/.vscode/settings.json index 6194f3c3..994b4040 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -2,6 +2,7 @@ "git.detectSubmodules": false, "cSpell.words": [ "msaa", + "repr", "vsync" ], "files.watcherExclude": { diff --git a/game/dist/shaders/texture_render.fs b/game/dist/shaders/texture_render.fs new file mode 100644 index 00000000..e69de29b diff --git a/game/game_logic/src/rendering/mod.rs b/game/game_logic/src/rendering/mod.rs index 84cb5be0..883289b4 100644 --- a/game/game_logic/src/rendering/mod.rs +++ b/game/game_logic/src/rendering/mod.rs @@ -1,3 +1,4 @@ //! This module contains lower level rendering logic. -pub mod event_loop; \ No newline at end of file +pub mod event_loop; +pub mod utilities; \ No newline at end of file diff --git a/game/game_logic/src/rendering/utilities/mod.rs b/game/game_logic/src/rendering/utilities/mod.rs index e69de29b..522880be 100644 --- a/game/game_logic/src/rendering/utilities/mod.rs +++ b/game/game_logic/src/rendering/utilities/mod.rs @@ -0,0 +1,2 @@ +pub mod vram_anim; +pub mod size_mismatch; \ No newline at end of file diff --git a/game/game_logic/src/rendering/utilities/size_mismatch.rs b/game/game_logic/src/rendering/utilities/size_mismatch.rs new file mode 100644 index 00000000..17508b0a --- /dev/null +++ b/game/game_logic/src/rendering/utilities/size_mismatch.rs @@ -0,0 +1,9 @@ +/// The policy for how to handle rendering a small frame on a big texture + +#[repr(C)] +#[derive(Debug, Clone, PartialEq, Copy)] +pub enum TextureSizeMismatchRenderPolicy { + TopLeft, + Center, +} + diff --git a/game/game_logic/src/rendering/utilities/vram_anim.rs b/game/game_logic/src/rendering/utilities/vram_anim.rs new file mode 100644 index 00000000..c551d238 --- /dev/null +++ b/game/game_logic/src/rendering/utilities/vram_anim.rs @@ -0,0 +1,11 @@ +use raylib::texture::Texture2D; + +#[derive(Debug)] +pub struct VramAnimTexture {} + +impl VramAnimTexture { + /// Construct a new `VramAnimTexture` + pub fn new(texture: Texture2D) -> Self { + Self {} + } +}