hollow Posted May 3, 2018 Share Posted May 3, 2018 Hello together, in PG https://www.babylonjs-playground.com/#1KUJ0A#104 you can see an default scene with an additional sphere outside the view (sphere_boycott) with renderingGroupId=1. Until now all looks good. If you focus the rendering window/side and press 'cursor key down' to get an larger distance with the actual camera position - or rotate the view to the right side - the added sphere will be shown and the tittled glow-effect fills up the whole sphere. I think, this is not the expected behavior?! Are more information needed? regards and thank you all for the great work and help edit 3 -- (start additional information) there is anonther (for me) unexpected behavior: in PG http://www.babylonjs-playground.com/indexstable#B73AIM (opacity on HighlightLayer) are 2 more cases, where the HL not correct works: The 1st 2 spheres are from an material example. there, the 2nd (middle) and over that the 3rd (right) added from me (example 1) has an opacityTexture (tree) over the grass diffuseTexture - both don't show the HL the 4th sphere (front) is added like the sides of the cube with dog-puzzle-piece, the tree.png with hasAlpha=true and looks beautiful, like expected. -- (end additional information) Edit (link string to link) Edit2 (2nd try) Edit3 (additional information about 8hrs after post) ... thanks for reading Quote Link to comment Share on other sites More sharing options...
Guest Posted May 3, 2018 Share Posted May 3, 2018 Pinging @Sebavan Quote Link to comment Share on other sites More sharing options...
Sebavan Posted May 3, 2018 Share Posted May 3, 2018 Hello, About the second playground it is all expected as the Highlight Layer does not support transparency: https://doc.babylonjs.com/how_to/highlight_layer#default-use-case About the first example I would say it is almost expected ? What happens is as you are using a separate rendering group you are erasing the required info for the highlight to work (this requires the stencil buffer) so you could prevent this like here: https://www.babylonjs-playground.com/#1KUJ0A#105 Or rely on separate cameras to achieve the same effect easily: https://doc.babylonjs.com/how_to/highlight_layer#multi-camera The fact that it does not directly happen is the result of amazing optimization in the engine where out of focus meshes are not rendered making harder to understand. hollow 1 Quote Link to comment Share on other sites More sharing options...
hollow Posted May 5, 2018 Author Share Posted May 5, 2018 Hello and thanks for your reply, but I'm still stuck on this. here https://doc.babylonjs.com/resources/transparency_and_how_meshes_are_rendered under 'Opaque or Transparent?' are 4 cases described: Depth pre-pass meshes - I think that's here not relevant, right? Opaque Meshes - will be the 'left' sphere from my first PG? Alpha Tested Meshes - seems has the possibility to be highlighted (it could be the 'front' sphere) , right? but only 'Alpha Blended Meshes' are not possible to highlight? And would it right to say, all what is visible for the depthRenderer is highlightable? a little bit offTopic: in this doc is the screenshot of an greyscaled depthRenderer picture, and the link to the PG here: https://www.babylonjs-playground.com/#1PHYB0#6 there the view is broken by pressing F9 in 3.3.0-alpha and an error (fireProcMaterial) for 3.2.0 (stable) is thrown (i will understand how the greyscale image is produced, I'm only able to create an BW-texture on a plane without Shaders) thanks in advance Quote Link to comment Share on other sites More sharing options...
Sebavan Posted May 5, 2018 Share Posted May 5, 2018 You are exactly right: "all what is visible for the depthRenderer is highlightable". Basically, the highlight layer relies internally on the depth buffer to create the effect. Quote Link to comment Share on other sites More sharing options...
Sebavan Posted May 10, 2018 Share Posted May 10, 2018 About the depth texture issue, the code was trying to rely on private methods instead of the dedicated public ones. You can take a look at the fix version here: https://www.babylonjs-playground.com/#1PHYB0#68 hollow 1 Quote Link to comment Share on other sites More sharing options...
hollow Posted May 10, 2018 Author Share Posted May 10, 2018 thank you verry much, that helps me 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.