Validation workaround `prime-effect-layers`: extra frame needed before capture when effect layers exist

Aperta
#2,006 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@bkaradzic-microsoft ci sta già lavorando.

Dal 3/11/2026.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

Affected tests (10)

  • Glow layer and LODs
  • Attractors
  • Glow layer and LODs
  • Prepass SSAO + highlight layer
  • sphere-with-custom-shader-to-display-wireframe-using-glow-layer
  • dissolve-effect-with-node-material-and-glow-layer
  • Glow layer with vertex alpha
  • Particles - Attractors
  • Selection outline layer with instances
  • Selection outline layer with instances and LOD

What the workaround does

Renders one extra frame before capture when the scene has effect layers (GlowLayer / HighlightLayer). Without it, the first captured frame is missing the glow/highlight contribution on BN. Introduced in #1913.

Recommended fix

Root cause is not confirmed. Capture the first frame with RenderDoc and compare with the second:

  • If the effect-layer RTT is rendered after the main pass in the same frame (view ordering / submission order in NativeEngine / bgfx view IDs), fix view ordering in BN so RTTs are submitted before the views that sample them.
  • If the effect layer's isReady() returns true before its effects/merge effect are compiled, fix readiness in Babylon.js (EffectLayer.isReady / _shouldRender).
    Then remove the workaround.

Workaround implementations live in Apps/Playground/Scripts/validation_native.js (WORKAROUNDS map); tests opt in via the workarounds array in Apps/Playground/Scripts/config.json. See Documentation/AddingNewValidationTests.md.

Lingua principale
C++
Stelle
931
Fork
169
Merge medio
2g 17h
PR unite (30g)
66

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di BabylonJS/BabylonNative

Tutte le issue di BabylonJS/BabylonNative

Issue simili

Altre issue su C++

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.