RenderCheck: the IoU floor is 0.999, so a bone 10 degrees or 2 cm off and hard weights fail; the normal and culling-box gaps are stated

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Meta Vens 2026-11-20 06:12:00 +01:00
commit 7ce8213f64
2 changed files with 8 additions and 5 deletions

View file

@ -84,7 +84,8 @@ Exports need export templates (not installed here yet), so the client runs from
The smoke has no renderer. `RenderCheck.tscn` is the check that does: it poses the puppet in a bent pose under a moved parent, renders one frame
(gl_compatibility, the client's renderer), and compares the drawn silhouette with the mesh skinned on the CPU (intersection over union, at
least 0.95), and checks the lit puppet is not clipped to white. Add `-- --png=<path>` to keep the frame. It needs a display.
least 0.999: a correct render measures 1.0000, and a forearm bone 10 degrees off, a bone 2 cm off and hard weights fail), and checks the lit puppet is not clipped to white. Add `-- --png=<path>` to keep the frame. It needs a display.
Known gaps: the silhouette does not see the shading normal (a puppet whose NORMAL is left unskinned passes) or the culling box (a 1 cm `CustomAabb` passes).
### Modeled

View file

@ -18,11 +18,13 @@ namespace BadDay.Client.Tests;
public partial class RenderCheck : Node
{
/// <summary>
/// A correct render measures 1.000 in this pose. The four skinning mutants Soul found (a flipped weight, no inverse bind, the
/// creation pose as the bind, an inverted CUSTOM1 weight) and one that ignores the parent transform measure 0.10 to 0.61, so
/// 0.95 keeps a wide gap on both sides.
/// A correct render measures 1.0000 in this pose, on every run so far, so the floor sits at the measurement's noise. Soul's
/// gross skinning mutants (a flipped weight, no inverse bind, the creation pose as the bind, an inverted CUSTOM1 weight, an
/// ignored parent) measure 0.10 to 0.61; the localized ones (a forearm bone 10 degrees off 0.982, a bone 2 cm off 0.973, hard
/// weights 0.998) were under a floor of 0.95 and only fail at this one. Gaps that remain: the silhouette cannot see the shading
/// normal (unskinned normals measure 1.0000) or the culling box (the puppet stays on screen with a 1 cm box).
/// </summary>
private const float MinIou = 0.95f;
private const float MinIou = 0.999f;
/// <summary>The puppet's lit faces: at most this share of its pixels may be at 250 or more of 255.</summary>
private const float MaxClipped = 0.02f;