diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /third_party/rust/gpu-descriptor/src/lib.rs | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'third_party/rust/gpu-descriptor/src/lib.rs')
-rw-r--r-- | third_party/rust/gpu-descriptor/src/lib.rs | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/third_party/rust/gpu-descriptor/src/lib.rs b/third_party/rust/gpu-descriptor/src/lib.rs new file mode 100644 index 0000000000..08217454e3 --- /dev/null +++ b/third_party/rust/gpu-descriptor/src/lib.rs @@ -0,0 +1,35 @@ +//! +//! Library for Vulkan-like APIs to allocated descriptor sets +//! from descriptor pools fast, with least overhead and zero fragmentation. +//! +//! Straightforward usage: +//! ```ignore +//! use gpu_descriptor::DescriptorAllocator; +//! +//! let mut allocator = DescriptorAllocator::new(max_update_after_bind_descriptors_in_all_pools); // Limit as dictated by API for selected hardware +//! +//! let result = allocator.allocate( +//! device, // Implementation of `gpu_descriptor::DescriptorDevice`. Comes from plugins. +//! layout, // Descriptor set layout recognized by device's type. +//! flags, // Flags specified when layout was created. +//! layout_descriptor_count, // Descriptors count in the layout. +//! count, // count of sets to allocated. +//! ); +//! ``` +//! + +#![cfg_attr(not(feature = "std"), no_std)] +#![warn( + missing_docs, + trivial_casts, + trivial_numeric_casts, + unused_extern_crates, + unused_import_braces, + unused_qualifications +)] + +extern crate alloc; + +mod allocator; + +pub use {crate::allocator::*, gpu_descriptor_types::*}; |