d13 Posted January 9, 2018 Share Posted January 9, 2018 Does anyone know if it's possible to set the visibility of lines created with `MeshBuilder.CreateLines`? (The reason I ask is I need to toggle lines on and off.) Quote Link to comment Share on other sites More sharing options...
Wingnut Posted January 10, 2018 Share Posted January 10, 2018 Hiya d13, good to see you again. https://www.babylonjs-playground.com/#1RQXG5#11 Lines 31 or 32 should do you well. Party on. Found via line 29... which dumps the guts of the lines mesh... to console. I just went scrolling down thru the 'object inspector' list shown on the JS console... looking for interesting property names. .visibility is there, too, but it doesn't seem to work... using my tests. So, .isVisible and .alpha... works fine. If you wish, we could go "source diving" and see if we can determine why .visibility is not working. Just holler, we'll pack a sandwich and dive-in. It might have something to do with 'alpha blending'. Quote Link to comment Share on other sites More sharing options...
d13 Posted January 10, 2018 Author Share Posted January 10, 2018 @Wingnut Thank you Mr, Wingnut sir, `isVisible` worked perfectly!!! 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.