fix(render): R1 — repurpose the ParentCellId==null cell-gate bypass (#78)
EntityPassesVisibleCellGate no longer returns true unconditionally for outdoor scenery under a cell filter (was the headline #78 bleed). Outdoor scenery now draws only via the unfiltered bucket (visibleCellIds: null) + ResolveEntitySlot's OutsideView routing. The outdoor-root global Draw passes visibleCellIds: null (no portal-cell scoping outdoors; retires VisibleCellIds as a render gate — peering into buildings is R5). Updated the EntityClipTests case that pinned the old bypass (Included -> Excluded). 174/174 App tests green. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
c4fd71149a
commit
58822fed96
3 changed files with 21 additions and 14 deletions
|
|
@ -85,17 +85,19 @@ public sealed class EntityClipTests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
public void EntityClip_NullParentCell_NonNullVisibleSet_Included()
|
||||
public void EntityClip_NullParentCell_NonNullVisibleSet_Excluded()
|
||||
{
|
||||
// An outdoor entity (ParentCellId == null) with a non-null visibleCellIds
|
||||
// falls through to the final return-true (not a shell, not shell-scoped);
|
||||
// outdoor scenery is not gated by the indoor cell filter.
|
||||
// R1 (bleed fix #78): an outdoor entity (ParentCellId == null) with a non-null cell filter
|
||||
// does NOT pass — it is not a member of any interior cell. (Was an unconditional return-true
|
||||
// bypass, the headline outdoor-scenery bleed.) When such entities must draw through the
|
||||
// doorway, the caller passes visibleCellIds: null and the OutsideView clip-slot routing
|
||||
// (ResolveEntitySlot) gates them instead.
|
||||
var visibleCellIds = new HashSet<uint> { 0xA9B40170u };
|
||||
var entity = Entity(parentCellId: null);
|
||||
|
||||
bool result = WbDrawDispatcher.EntityPassesVisibleCellGate(
|
||||
entity, visibleCellIds, WbDrawDispatcher.EntitySet.All);
|
||||
|
||||
Assert.True(result);
|
||||
Assert.False(result);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue