-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
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
Optimize Outline rendering of MMD #9472
Conversation
Have you considered using |
Not yet. |
Yes. I haven't looked at it in detail, but usually these |
I see, I'll try with |
Updated. I'm feeling like I want the following functions
|
What are those functions for? |
For example, to hide some objects from a certain camera like I do in this change. To do that with the current enable/disable(), the code would be
But it isn't straightforward. |
var tmpEnabled = this.renderer.shadowMap.enabled; | ||
this.renderer.shadowMap.enabled = false; | ||
var invisibledObjects = []; | ||
var setInvisible; |
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.
Why don't you directly create the setVisible
and restoreVisible
functions here?
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.
Because I couldn't point MMDHelper
by using this
here.
And to use camera
passed to this method.
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.
setInvisible( this, object )
? 😊
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.
callback function for traverse
doesn't accept any arguments except for object
:(
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 see I see!
Thanks! |
* Optimize Outline rendering of MMD * Use Layers instead of visible for MMDHelper.renderOutline() optimization
In outline rendering pass, I set
visible
= false for the objects not to be needed rendering outlinelike the stage of
webgl_loader_mmd_audio
example.