diff options
author | tcmal <me@aria.rip> | 2024-08-25 17:44:23 +0100 |
---|---|---|
committer | tcmal <me@aria.rip> | 2024-08-25 17:44:23 +0100 |
commit | c9fb3ae28fe491bc55243fb80d8c6be93f37ad99 (patch) | |
tree | c8d6519479d3b17f5bd657495c4d7fe2d2830a1a /stockton-render/src/draw/texture/repo.rs | |
parent | c52a05e6d3977efce6bd4479aa312dc90e0452e5 (diff) |
feat(render): ui working
Diffstat (limited to 'stockton-render/src/draw/texture/repo.rs')
-rw-r--r-- | stockton-render/src/draw/texture/repo.rs | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/stockton-render/src/draw/texture/repo.rs b/stockton-render/src/draw/texture/repo.rs index 8191f7b..ef35610 100644 --- a/stockton-render/src/draw/texture/repo.rs +++ b/stockton-render/src/draw/texture/repo.rs @@ -1,10 +1,8 @@ -use stockton_levels::prelude::HasTextures; - use super::{ block::TexturesBlock, + load::TextureLoadConfig, loader::{BlockRef, LoaderRequest, TextureLoader, TextureLoaderRemains, NUM_SIMULTANEOUS_CMDS}, resolver::TextureResolver, - LoadableImage, }; use crate::error::LockPoisoned; use crate::types::*; @@ -49,17 +47,12 @@ impl<'a> TextureRepo<'a> { family.queue_type().supports_transfer() && family.max_queues() >= NUM_SIMULTANEOUS_CMDS } - pub fn new< - T: 'static + HasTextures + Send + Sync, - R: 'static + TextureResolver<I> + Send + Sync, - I: 'static + LoadableImage + Send, - >( + pub fn new<R: 'static + TextureResolver + Send + Sync>( device_lock: Arc<RwLock<DeviceT>>, family: QueueFamilyId, queue: Arc<RwLock<QueueT>>, adapter: &Adapter, - texs_lock: Arc<RwLock<T>>, - resolver: R, + config: TextureLoadConfig<R>, ) -> Result<Self> { // Create Channels let (req_send, req_recv) = channel(); @@ -112,8 +105,7 @@ impl<'a> TextureRepo<'a> { ds_lock.clone(), req_recv, resp_send, - texs_lock, - resolver, + config, )?; std::thread::spawn(move || loader.loop_until_exit()) |