-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Grid children disappear once linked mesh is outside view #12607
Conversation
@@ -142,6 +142,7 @@ export class Container extends Control { | |||
|
|||
public _flagDescendantsAsMatrixDirty(): void { | |||
for (const child of this.children) { | |||
child._isClipped = false; | |||
child._markMatrixAsDirty(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn t the marMatrixAsDirty set the flag ??? just wondering :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, this is a very special case! I was struggeling with this decision.
This special case appears ONLY when a container has a container as a child. Setting isClipped every time the matrix is set dirty will be redundant. This is the least amount of isClipped-resetting.
But I agree with you that it does feel a bit off.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe let s wait for @deltakosh feedback tomorrow as I remember the caching was pretty heavy to put in place :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am anyhow not merging this until approved :-)
Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s). |
Please make sure to label your PR with "bug", "new feature" or "breaking change" label(s). |
Snapshot stored with reference name: Test environment: To test a playground add it to the URL, for example: https://babylonsnapshots.z22.web.core.windows.net/refs/pull/12607/merge/index.html#WGZLGJ#4600 Links to test babylon tools with this snapshot: https://playground.babylonjs.com/?snapshot=refs/pull/12607/merge To test the snapshot in the playground with a playground ID add it after the snapshot query string: https://playground.babylonjs.com/?snapshot=refs/pull/12607/merge#BCU1XR#0 |
Fixes #12602
This forces resetting the clipping state of children when their matrix is set as dirty.