gwenael Posted December 23, 2013 Share Posted December 23, 2013 I found the "private" attribute _localPivotScaling is only used in BABYLON.Mesh.prototype.computeWorldMatrix. Is it on purpose that it's an attribute instead of a local variable? I'm not an expert in javascript... Same question for _localPivotScalingRotation, _localRotation, _localTranslation, _localBillboard and _localWorld. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted December 24, 2013 Share Posted December 24, 2013 I use this local variable to avoid instantiating a new matrix every time I need to compute world matrix I use this as an attribute to keep the allocated memory (I want to reduce the GC pressure actually) Quote Link to comment Share on other sites More sharing options...
gwenael Posted December 24, 2013 Author Share Posted December 24, 2013 Yeah I missed the part where you use references for the matrices. Indeed it's better to reduce the GC pressure instead of the memory print. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.