bevy/crates/bevy_render/src
robtfm cc8f023b3a
fix invalid bone weights (#8316)
# Objective

when a mesh uses zero for all bone weights, vertices end up in the
middle of the screen.

## Solution

we can address this by explicitly setting the first bone weight to 1
when the weights are given as zero. this is the approach taken by
[unity](https://forum.unity.com/threads/whats-the-problem-with-this-import-fbx-warning.133736/)
(although that also sets the bone index to zero) and
[three.js](94c1a4b86f/src/objects/SkinnedMesh.js (L98)),
and likely other engines.

## Alternatives

it does add a bit of overhead, and users can always fix this themselves,
though it's a bit awkward particularly with gltfs.

(note - this is for work so my sme status shouldn't apply)

---------

Co-authored-by: ira <JustTheCoolDude@gmail.com>
2023-04-10 07:49:53 +00:00
..
camera Consistent screen-space coordinates (#8306) 2023-04-05 22:32:36 +00:00
color Color::Lcha constructors (#8041) 2023-03-11 18:50:16 +00:00
mesh fix invalid bone weights (#8316) 2023-04-10 07:49:53 +00:00
primitives Minor mistake in Frustum::intersects_obb (#8305) 2023-04-05 19:37:59 +00:00
render_graph Use RenderGraphApp in more places (#8298) 2023-04-05 20:57:56 +00:00
render_phase Non-breaking change* from UK spellings to US (#8291) 2023-04-08 16:22:46 +00:00
render_resource Remove capacity fields from all Buffer wrapper types (#8301) 2023-04-04 20:12:31 +00:00
renderer Make render graph slots optional for most cases (#8109) 2023-03-21 20:11:13 +00:00
texture Added WebP image format support (#8220) 2023-03-28 19:53:55 +00:00
view Temporal Antialiasing (TAA) (#7291) 2023-03-27 22:22:40 +00:00
extract_component.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
extract_param.rs Use UnsafeWorldCell to increase code quality for SystemParam (#8174) 2023-04-01 15:45:07 +00:00
extract_resource.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
globals.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
globals.wgsl Refactor Globals and View structs into separate shaders (#7512) 2023-02-11 17:55:18 +00:00
lib.rs Suppress the clippy::type_complexity lint (#8313) 2023-04-06 21:27:36 +00:00
pipelined_rendering.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
render_asset.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
settings.rs add OpenGL and DX11 backends (#7481) 2023-02-04 23:20:20 +00:00
spatial_bundle.rs enum Visibility component (#6320) 2022-12-25 00:39:29 +00:00