Commit Graph

3901 Commits

Author SHA1 Message Date
Rua
0175bcd2a6
Add DeviceAddress, handle pointers as SPIR-V struct members (#2351)
* Add `DeviceAddress`, handle pointers as SPIR-V struct members

* Add pointers to vulkano-shaders
2023-10-07 15:13:58 +02:00
Rua
fb828a6db2
Clippy fixes for Rust 1.73.0 (#2347)
* Clippy fixes for Rust 1.73.0

* Doc fixes too
2023-10-07 14:13:17 +02:00
marc0246
9d988440df
#2345 changelog 2023-10-03 17:33:13 +02:00
Alexander Rohde
ba4d11afa9
Allow for setting the array length in a shader using a specialization constant. (#2345) 2023-10-03 17:32:39 +02:00
Rua
d22104709f
Document SurfaceApi better (#2340)
* Document `SurfaceApi` better

* Add TryFrom<RawWindowHandle> for SurfaceApi

* Rename Qnx > QnxScreen to match the `from_qnx_screen` constructor
2023-10-01 23:10:18 +02:00
Trevor
c24c7ad155
Add len method to IndexBuffer (#2342)
* ### Additions
- `IndexBuffer::len` method.

* Fixed formatting
2023-09-28 20:12:27 +02:00
Rua
56b051c954
#2336 changelog 2023-09-28 11:06:48 +02:00
marc0246
b49476036c
Remove duplicate validation in GenericMemoryAllocator (#2336)
* Remove duplicate validation

* Merge `GenericMemoryAllocator::new[_unchecked]`

* Fix oopsie from earlier PR
2023-09-28 11:06:08 +02:00
marc0246
44732afefe
Revert "#2338 changelog"
This reverts commit 17fb48b348.
2023-09-27 16:36:54 +02:00
marc0246
17fb48b348
#2338 changelog 2023-09-27 16:33:59 +02:00
Rua
59d7c816fe
Make IndexBuffer::as_bytes public (#2338) 2023-09-27 16:32:07 +02:00
Rua
a8ca0a7f7f
Refactor some shader things and add more validation (#2335)
* Refactor some shader things and add more validation

* Remove pub
2023-09-21 12:18:31 +02:00
marc0246
e9790c1fc3
Make the insides of AllocationHandle private (#2332)
* Make the insides of `AllocationHandle` private

* Fix naming
2023-09-16 10:10:32 +02:00
Rua
06f698a6be
#2333 changelog 2023-09-15 22:24:12 +02:00
Aspen
80ab3a829e
Add interface entry for color index, check during overlap testing (#2333) 2023-09-15 22:22:55 +02:00
Rua
4d17a7392d
Fix typo in cargo:rerun-if-changed (#2331) 2023-09-14 13:22:21 +02:00
Firestar99
86f63ac9f2
small Buffer docs fixes (#2328)
* fixed Buffer::new* docs still referring to buffer_info instead of create_info

* fixed line length

---------

Co-authored-by: Firestar99 <4696087-firestar99@users.noreply.gitlab.com>
2023-09-14 13:22:10 +02:00
marc0246
f0a6ce1435
#2329 changelog 2023-09-14 13:20:37 +02:00
Rua
3c49541bc3
Apply specialization to shader reflection (#2329)
* Apply specialization to shader reflection

* Remove redundant method

* Remove all the SpecId decorations too

* Don't unnecessarily collect the instructions

* Replace decoration groups with individual decorations

* Rename with_specialization

* Missed renames

* Remove the Arcs
2023-09-14 13:19:25 +02:00
marc0246
56e78d9b3c
Fix missing overflow check when constructing suballocators (#2322)
* Fix missing overflow check when constructing suballocators

* Add tests, fix borked code

* Make `Region`'s fields private

* Fix docs

* Borked the merge
2023-09-14 12:02:29 +02:00
Rua
957111658b
#2319 changelog 2023-09-13 16:18:45 +02:00
marc0246
aecb7a476a
Make GenericMemoryAllocatorCreateInfo::block_sizes more flexible (#2319) 2023-09-13 16:17:54 +02:00
marc0246
28224138f2
Fix suballocator cleanup (#2323)
* Fix suballocator cleanup

* impl `Debug` for `dyn Suballocator`
2023-09-13 15:10:36 +02:00
marc0246
771aa30bbe
Fix Miri warnings when running the suballocator tests (#2330) 2023-09-13 09:30:12 +02:00
marc0246
7d63f8e697
Move the allocation_type field to Suballocation (#2327) 2023-09-12 18:15:55 +02:00
marc0246
c43a9c9d50
Document the safety invariants of the (sub)allocator traits (#2321)
* Document the safety invariants of the (sub)allocator traits

* Oopsie

* Remove alignment from the safety requirements

Reason being that this requirement is already explained in the docs of
`Suballocation`, along with the requirements of the other fields.
2023-09-12 17:25:46 +02:00
marc0246
081d9c2d4e
#2316 docs fixes (#2320) 2023-09-09 18:00:22 +02:00
marc0246
1c2371cac4
#2317 docs fixes (#2325) 2023-09-09 18:00:10 +02:00
Austin Johnson
b4f4089ad3
#2317 Changelog 2023-09-07 02:40:02 -05:00
marc0246
c93d71e064
Make the suballocators !Sync (#2317) 2023-09-07 02:39:47 -05:00
Rua
64ea44c25e
#2316 changelog 2023-09-03 13:09:49 +02:00
marc0246
5578bf30da
Memory (sub)allocation API 2.0 (#2316)
* Excommunicate `PoolAllocator`

* Switch to manual deallocation

* Move `ResourceMemory` away from the `suballocator` module

* Remove `SuballocatorError::BlockSizeExceeded`

* Fix examples

* Fix atom size

* Address safety TODOs

* Nice English you got there bro
2023-09-03 13:09:07 +02:00
Rua
fe7b2371a9
Update spirv grammar JSON file (#2315) 2023-09-01 21:53:22 +02:00
Rua
e1acf31a2e
Add missing division for bits-to-bytes conversions (#2313) 2023-08-26 23:00:51 +02:00
marc0246
4ee8aa5f1a
Remove uses of Option::unwrap_unchecked as a safety precaution (#2310) 2023-08-26 17:13:40 +02:00
Rua
04d22e8052
#2311 changelog 2023-08-26 17:13:30 +02:00
marc0246
e1daac6690
Add configuration for custom memory_type_bits masks (#2311) 2023-08-26 17:12:54 +02:00
marc0246
c74eedbdf4
#2307 fixes (#2309) 2023-08-26 12:07:27 +02:00
Rua
c8712dcecc
Wrap buffer values in AccelerationStructureBuildGeometryInfo in an Option (#2307)
* Wrap buffer values in `AccelerationStructureBuildGeometryInfo` in an `Option`

* Oops!

* Also wrap `mode` and `dst_acceleration_structure`

* Un-wrap mode
2023-08-26 11:53:37 +02:00
Rua
10148c5e94
#2306 changelog 2023-08-26 11:26:36 +02:00
marc0246
0c714c1bfe
Fix validation and errors in MemoryAllocator (#2306)
* Fix validation and errors in `MemoryAllocator`

* Doc tests

* Update vulkano/src/memory/allocator/mod.rs

Co-authored-by: Rua <ruawhitepaw@gmail.com>

---------

Co-authored-by: Rua <ruawhitepaw@gmail.com>
2023-08-26 11:26:02 +02:00
Matthieu Vachon
d1a17f9510
Improved display of some error and remove unimplemented! for UnexpectedImageLayout display (#2305)
It appeared to me quite often that I've it some error and the message was lost on display because some `Display` implementation don't record the cause. Improved some of those that I've spotted while debugging some bad code I had.

Also removed the `unimplemented` for `AccessError::UnexpectedImageLayout` and now giving a more descriptive message.
2023-08-26 09:57:27 +02:00
Rua
c8ad5a4512
Fix erroneous used range for buffers in descriptor sets (#2303)
* Fix erroneous used range for buffers in descriptor sets

* Fix mistake resulting from an error in the spec that was just fixed
2023-08-25 21:15:23 +02:00
marc0246
49a8f6607c
#2301 changelog 2023-08-25 20:42:18 +02:00
Firestar99
80023d2a1a
ShaderModule::single_entry_point() (#2301)
* added ShaderModule::single_entry_point() functions

* single_entry_point() always verifies it's the sole entry point, search optimizations

* single_entry_point() docs adjustments

* ShaderModule removed entry_point_map, instead entry points are searched linearly search though a Vec

---------

Co-authored-by: Firestar99 <4696087-firestar99@users.noreply.gitlab.com>
2023-08-25 20:41:17 +02:00
Rua
b3dbca4001
Rust 1.72 fixes (#2302) 2023-08-25 03:01:45 +02:00
Rua
914bfa4f37
#2300 additions 2023-08-24 16:48:57 +02:00
Rua
29acac5711
#2300 changelog 2023-08-24 16:48:21 +02:00
marc0246
de7b6a91a0
Merge MappedDeviceMemory into DeviceMemory, make MemoryAlloc reuse the logic (#2300)
* Merge `MappedDeviceMemory` into `DeviceMemory`

* Fix soundness and utilize new `DeviceMemory` methods in `MemoryAlloc`

* Fix oopsies

* `Sync`ness

* `#[inline]`

* Big oopsie

* Language

* Sanity check for the deprecated stuff

* Full `khr_map_memory2`

* Missed trait impls

* `MemoryUnmapInfo::validate`

* Document mapping behavior of `GenericMemoryAllocator`

* Validate flags

* Update vulkano/src/memory/allocator/mod.rs

Co-authored-by: Rua <ruawhitepaw@gmail.com>

* Remove flags

* Errors

---------

Co-authored-by: Rua <ruawhitepaw@gmail.com>
2023-08-24 16:46:38 +02:00
Rua
015c057fa1
#2295 additions 2023-08-24 15:58:14 +02:00