Skip to content

fix(forum-55482): make RenderQuickSort stable to preserve Spine 3D draw order - #2372

Open
guozhaokui wants to merge 1 commit into
layabox:LayaAir_3.3from
guozhaokui:bot/forum-55482-3.3
Open

fix(forum-55482): make RenderQuickSort stable to preserve Spine 3D draw order#2372
guozhaokui wants to merge 1 commit into
layabox:LayaAir_3.3from
guozhaokui:bot/forum-55482-3.3

Conversation

@guozhaokui

Copy link
Copy Markdown
Member

…aw order

When render elements have equal sort values (same materialRenderQueue,
distanceForSort, sortingFudge), the quicksort partition could swap them
arbitrarily, breaking Spine's internal draw order. Fix by tracking original
indices and using them as a tiebreaker when all other sort keys are equal.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant