bevy/crates/bevy_pbr/src/meshlet
James Liu e62a01f403
Make PersistentGpuBufferable a safe trait (#12744)
# Objective
Fixes #12727. All parts that `PersistentGpuBuffer` interact with should
be 100% safe both on the CPU and the GPU: `Queue::write_buffer_with`
zeroes out the slice being written to and when uploading to the GPU, and
all slice writes are bounds checked on the CPU side.

## Solution
Make `PersistentGpuBufferable` a safe trait. Enforce it's correct
implementation via assertions. Re-enable `forbid(unsafe_code)` on
`bevy_pbr`.
2024-03-29 13:14:34 +00:00
..
asset.rs
copy_material_depth.wgsl
cull_meshlets.wgsl
downsample_depth.wgsl
dummy_visibility_buffer_resolve.wgsl
from_mesh.rs
gpu_scene.rs
material_draw_nodes.rs
material_draw_prepare.rs
meshlet_bindings.wgsl
meshlet_mesh_material.wgsl
meshlet_preview.png
mod.rs
persistent_buffer_impls.rs Make PersistentGpuBufferable a safe trait (#12744) 2024-03-29 13:14:34 +00:00
persistent_buffer.rs Make PersistentGpuBufferable a safe trait (#12744) 2024-03-29 13:14:34 +00:00
pipelines.rs
visibility_buffer_raster_node.rs
visibility_buffer_raster.wgsl
visibility_buffer_resolve.wgsl
write_index_buffer.wgsl