diff options
author | 2020-02-28 14:38:42 +0100 | |
---|---|---|
committer | 2020-02-28 14:38:42 +0100 | |
commit | 4e7159c22c6be90f61aa715d5eb6811f805cb597 (patch) | |
tree | 77faf86bc65142d3c224b240a0c5922b7f4f9025 /wgpu/src/image/atlas/layer.rs | |
parent | fc55e3a3df9e08d361985b01528d2a6095d98aba (diff) | |
download | iced-4e7159c22c6be90f61aa715d5eb6811f805cb597.tar.gz iced-4e7159c22c6be90f61aa715d5eb6811f805cb597.tar.bz2 iced-4e7159c22c6be90f61aa715d5eb6811f805cb597.zip |
Stop creating image pipeline when unnecessary
Diffstat (limited to 'wgpu/src/image/atlas/layer.rs')
-rw-r--r-- | wgpu/src/image/atlas/layer.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/wgpu/src/image/atlas/layer.rs b/wgpu/src/image/atlas/layer.rs new file mode 100644 index 00000000..b1084ed9 --- /dev/null +++ b/wgpu/src/image/atlas/layer.rs @@ -0,0 +1,17 @@ +use crate::image::atlas::Allocator; + +#[derive(Debug)] +pub enum Layer { + Empty, + Busy(Allocator), + Full, +} + +impl Layer { + pub fn is_empty(&self) -> bool { + match self { + Layer::Empty => true, + _ => false, + } + } +} |