Skip to content

Commit

Permalink
Expand on migration guide for PR 9416 (#816)
Browse files Browse the repository at this point in the history
  • Loading branch information
rparrett authored Nov 6, 2023
1 parent 4f8b74d commit 24fd93b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion content/learn/migration-guides/0.11-0.12/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -918,12 +918,16 @@ Note that using the instance_index is the default way to pass the per-object ind
<div class="migration-guide-area-tag">Rendering</div>
</div>

`Sphere::intersects_obb` and `Frustum::intersects_obb` now take an `Affine3A` instead of a `Mat4`. You can use `Affine3A::from_mat4` or `Transform::compute_affine` to get an `Affine3A`.

`MeshUniform` now stores its current and previous model transforms as 4x3 matrices. Helper functions were added to bevy_pbr::mesh_functions to unpack the data.

```rust
// 0.11
var model = mesh[instance_index].model;

// 0.12
#import bevy_pbr::mesh_functions affine_to_square
#import bevy_pbr::mesh_functions::affine_to_square

var model = affine_to_square(mesh[instance_index].model);
```
Expand Down

0 comments on commit 24fd93b

Please sign in to comment.