So I have been doing a lot of work with texture stuff lately, and I got to a problem that I am kinda confused by.
So normally when you set up a “Tree” model you do some planes that represent branches and are placeholders for geometry, it’s pretty standard, but for some reason the struggle is real in trying to get this setup.
Also there seems to be an odd glitch with the polygons where they are “jumping” randomly for no real reason.
On the left is how it should more or less look, on the right is how its rendering in browser. I have tried every alpha mode but none seem to allow the pass through of other alpha mats behind it through the area of the polygons that are hidden by the alpha texture.
Around 30 seconds in I am able to demonstrate the weird jumping as well.
here is the current material setup
var cherryTreeBranchMatA = new BABYLON.StandardMaterial('cherryTreeBranchMatA', scene)
cherryTreeBranchMatA.backFaceCulling = false
//cherryTreeBranchMatA.twoSidedLighting = true
cherryTreeBranchMatA.useAlphaFromDiffuseTexture = false
cherryTreeBranchMatA.diffuseTexture = new BABYLON.Texture('./assets/textures/cbba_albedo.png')
cherryTreeBranchMatA.opacityTexture = new BABYLON.Texture('./assets/textures/cbba_alpha.png')
cherryTreeBranchMatA.opacityTexture.getAlphaFromRGB = true
cherryTreeBranchMatA.needDepthPrePass = true
cherryTreeBranchMatA.alphaMode = 8
any insight?