@@ -105,12 +105,11 @@ use crate::{
105
105
binding_model, command, conv,
106
106
hal_api:: HalApi ,
107
107
id,
108
- lock:: { rank, Mutex } ,
108
+ lock:: { rank, Mutex , RwLock } ,
109
109
pipeline, resource,
110
110
snatch:: SnatchGuard ,
111
111
} ;
112
112
113
- use parking_lot:: RwLock ;
114
113
use std:: { fmt, ops, sync:: Arc } ;
115
114
use thiserror:: Error ;
116
115
@@ -489,11 +488,26 @@ impl<A: HalApi> RenderBundleScope<A> {
489
488
/// Create the render bundle scope and pull the maximum IDs from the hubs.
490
489
pub fn new ( ) -> Self {
491
490
Self {
492
- buffers : RwLock :: new ( BufferUsageScope :: default ( ) ) ,
493
- textures : RwLock :: new ( TextureUsageScope :: default ( ) ) ,
494
- bind_groups : RwLock :: new ( StatelessTracker :: new ( ) ) ,
495
- render_pipelines : RwLock :: new ( StatelessTracker :: new ( ) ) ,
496
- query_sets : RwLock :: new ( StatelessTracker :: new ( ) ) ,
491
+ buffers : RwLock :: new (
492
+ rank:: RENDER_BUNDLE_SCOPE_BUFFERS ,
493
+ BufferUsageScope :: default ( ) ,
494
+ ) ,
495
+ textures : RwLock :: new (
496
+ rank:: RENDER_BUNDLE_SCOPE_TEXTURES ,
497
+ TextureUsageScope :: default ( ) ,
498
+ ) ,
499
+ bind_groups : RwLock :: new (
500
+ rank:: RENDER_BUNDLE_SCOPE_BIND_GROUPS ,
501
+ StatelessTracker :: new ( ) ,
502
+ ) ,
503
+ render_pipelines : RwLock :: new (
504
+ rank:: RENDER_BUNDLE_SCOPE_RENDER_PIPELINES ,
505
+ StatelessTracker :: new ( ) ,
506
+ ) ,
507
+ query_sets : RwLock :: new (
508
+ rank:: RENDER_BUNDLE_SCOPE_QUERY_SETS ,
509
+ StatelessTracker :: new ( ) ,
510
+ ) ,
497
511
}
498
512
}
499
513
0 commit comments