teoxoy
c38ed8d9fa
move surface creation methods on the Instance
2024-10-14 13:24:44 +02:00
teoxoy
de97e5449c
move enumerate_adapters
on the Instance
2024-10-14 13:24:44 +02:00
teoxoy
952ba3e12c
move queue methods on the Queue
type
2024-10-14 13:24:44 +02:00
teoxoy
c65c4626f1
make Fallible<T>
public
2024-10-14 13:24:44 +02:00
teoxoy
4d55c6917e
make remaining Adapter
methods public
2024-10-14 13:24:44 +02:00
teoxoy
d1c95d2bfd
add adapter getters
2024-10-14 13:24:44 +02:00
teoxoy
321bd64ba2
add Adapter::backend()
2024-10-14 13:24:44 +02:00
teoxoy
5627a0b6d9
move request_adapter
on the Instance
2024-10-14 13:24:44 +02:00
teoxoy
40206ce4d7
add new Instance::as_hal
fn
2024-10-14 13:24:44 +02:00
Erich Gubler
91447aefc9
refactor: s/once_cell::sync::OnceCell/std::sync::OnceLock
...
Weaken our dependence on the `once_cell` crate by using functionality
from `std` instead that was upstreamed from `once_cell`.
It's not yet possible to eliminate this dependency entirely, but do what
we can for now.
2024-10-11 15:52:21 -07:00
teoxoy
71b4f361e2
chore(core): more detail on TODO
for push constants
2024-10-02 04:41:34 -04:00
teoxoy
38a13b94f0
refactor: make Snatchable::snatch
take _guard
by &mut _
2024-10-02 04:41:34 -04:00
teoxoy
7ac533a312
add missing indirect buffer offset validation
2024-10-02 04:41:34 -04:00
Erich Gubler
0903ba6d47
refactor(core): delete unused CreateDeviceError
2024-10-02 04:41:34 -04:00
teoxoy
76af20348d
remove old comment
2024-10-02 04:41:34 -04:00
teoxoy
025787bbad
remove duplicate validation
2024-10-02 04:41:34 -04:00
Elie Michel
c9202ee54a
Remove redundant let binding ( #6356 )
2024-10-02 10:21:30 +02:00
Erich Gubler
fc2fd95a98
fix: handle Queue::submit
non-fatally ( #6318 )
...
* Change the signature of `wgpu_core::Global::queue_submit` to return
a `(SubmissionIndex, …)` in addition to its current error type.
* Change the control flow of errors in `Queue::submit` to break to the
end of a block. This is similar to what we already do in many APIs in
`wgpu_core`.
* Hoist the scope of the local `submit_index` binding so it can be used
at the point where we need to convert current error paths to also
return the submission index.
Later, we will likely want to avoid actually retrieving a new submission
index so we can minimize the critical section of code. We'll need to
figure out a strategy for returning a valid (but not necessarily unique)
index in the case of failures that prevent successful submission.
2024-09-25 02:52:25 +00:00
Erich Gubler
2f81ae156c
style: use concat!(…)
in DOWNLEVEL_*_MESSAGE
( #6305 )
2024-09-22 00:27:32 +00:00
Erich Gubler
841e7c8857
fix: only log Device::maintain
waits if they happen ( #6303 )
2024-09-21 18:47:35 +02:00
Erich Gubler
9977edc51f
chore!: remove #[no_mangle] … extern "C" …
from fn
s in bundle_ffi
( #6272 )
2024-09-21 16:33:13 +00:00
Erich Gubler
0d339fc9f1
chore: suppress unused_qualifications
for wgpu_core::id
const. assertions ( #6295 )
2024-09-18 21:48:04 +02:00
Teodor Tanasoaia
c8beade187
remove backend from ID ( #6263 )
2024-09-13 17:30:38 +02:00
Adam Winiarczuk
f3cbd6ce54
fix: Set mip_level_count in TextureInitTracker for externally created textures ( #6249 )
...
Co-authored-by: Adam Winiarczuk <tsu@liv.tv>
2024-09-10 22:28:36 +00:00
teoxoy
c4110afc7f
[wgpu-core] inline Storage.insert_impl()
2024-09-10 11:58:54 +02:00
teoxoy
2addb267fc
[wgpu-core] remove FutureId.into_id()
2024-09-10 11:58:54 +02:00
teoxoy
c182d3f24f
[wgpu-core] rename .strict_unregister()
& .strict_remove()
to .remove()
2024-09-10 11:58:54 +02:00
teoxoy
ac74f36590
[wgpu-core] rename .strict_get()
to .get()
2024-09-10 11:58:54 +02:00
teoxoy
31edbfd0dc
[wgpu-core] use .strict_get()
& .strict_unregister()
for command buffers
...
We now only rely on the presence of the inner `CommandBufferMutable` to determine if command buffers are invalid.
2024-09-10 11:58:54 +02:00
teoxoy
c0c594eff2
[wgpu-core] use Fallible
for RenderBundle
2024-09-10 11:58:54 +02:00
teoxoy
ee3b63a9af
[wgpu-core] use Fallible
for PipelineCache
2024-09-10 11:58:54 +02:00
teoxoy
5bcdd4266e
[wgpu-core] use Fallible
for ShaderModule
2024-09-10 11:58:54 +02:00
teoxoy
1c5793afb3
[wgpu-core] use Fallible
for PipelineLayout
2024-09-10 11:58:54 +02:00
teoxoy
e444e78d94
[wgpu-core] use Fallible
for BindGroupLayout
2024-09-10 11:58:54 +02:00
teoxoy
45206e553d
[wgpu-core] use Fallible
for RenderPipeline
2024-09-10 11:58:54 +02:00
teoxoy
82ce2ea747
[wgpu-core] use Fallible
for ComputePipeline
2024-09-10 11:58:54 +02:00
teoxoy
b42500ee40
[wgpu-core] use Fallible
for BindGroup
2024-09-10 11:58:54 +02:00
teoxoy
2ea314e978
[wgpu-core] remove Arc
around StagingBuffer
2024-09-10 11:58:54 +02:00
teoxoy
b14fe14e88
[wgpu-core] use Fallible
for QuerySet
2024-09-10 11:58:54 +02:00
teoxoy
3ed1abc492
[wgpu-core] use Fallible
for Sampler
2024-09-10 11:58:54 +02:00
teoxoy
04f17d4197
[wgpu-core] use Fallible
for TextureView
2024-09-10 11:58:54 +02:00
teoxoy
c630821f1d
[wgpu-core] use Fallible
for Texture
2024-09-10 11:58:54 +02:00
teoxoy
68e8b7d4a8
[wgpu-core] introduce Fallible
and use it for Buffer
(first step of invalidity internalization)
2024-09-10 11:58:54 +02:00
teoxoy
3437589107
[wgpu-core] use .strict_get()
& .strict_unregister()
for devices
...
This works because we never assign errors to devices (they are never invalid).
2024-09-10 11:58:54 +02:00
teoxoy
07c397a1e5
[wgpu-core] use .strict_get()
& .strict_unregister()
for queues
...
This works because we never assign errors to queues (they are never invalid).
2024-09-10 11:58:54 +02:00
teoxoy
aa280ecd44
[wgpu-core] change return type of device creation methods to be more rusty
...
This is fine from the WebGPU spec's perspective as device creation returns a promise that can reject.
2024-09-10 11:58:54 +02:00
teoxoy
da9afea271
[wgpu-core] use .strict_get()
& .strict_unregister()
for surfaces
...
This works because we never assign errors to surfaces (they are never invalid).
2024-09-10 11:58:54 +02:00
teoxoy
98426329a4
[wgpu-core] introduce Registry
.strict_get()
& .strict_unregister()
and use them for adapters
...
This works because we never assign errors to adapters (they are never invalid).
2024-09-10 11:58:54 +02:00
teoxoy
70a9c01b48
[wgpu-core] make the Registry
generic over T: Clone
2024-09-10 11:58:54 +02:00
teoxoy
d550342f47
[wgpu-core] use device.instance_flags
when possible
2024-09-10 11:58:54 +02:00