Face culling and transparent textures


I’m trying to get a box to show up as a wireframe (but with custom borders) so I made a texture

with borders and transparent faces. when I put this on my geometry I get some weird results, the inside walls

of the box are sometimes textured and sometimes not. I have set FaceCullMode to off. Is there some other option

I have to set to get all sides to show up? Here is a picture of my problem


A part of the box is not visible behind “Pack”. (though the text has nothing to do with the problem

it just happend to be there at the moment)

Hello there monkeys! this is my first post and I’m a little concerned that this has been resolved already (I searched quite a bit though) here is a pic about the same issue. Tried setting the face cull mode to off.

Have you tried:




Or anything else?

Yes I’ve tried those I wonder where’s the trick here… I managed to make this happen aswell:

in (1) you see the cube that’s giving me headaches viewed from the inside of a quad with the same material (transparency working from both sides as you can see)
in (2) you can see thin boxes (they look like quads, transparency working)
in (3) you can see the holly cube that let’s me see the quads behind it but doesn’t let me see some of its faces

Well, I’m no expert but I did have similar problems recently and solved them, so here is what I have for an object with FaceCull off and transparent textures…

I have UseAlpaha ticked, and AlphaDiscardThreshhold set to 0.1. DepthTest and DepthWrite are both ticked, AlphaTestFallOff is set to 0.8f. (Those are all settings when I open the j3m in the sdk, can be set in code though).

Then I just use the above bits,
mat.getAdditionalRenderState().setBlendMode(RenderState.BlendMode.Alpha); and spatial.setQueueBucket(Bucket.Transparent);

This gives me exactly what you’ve gone for, non face culled model with transparent textures.

If it’s still not working, I’ll happily take a look if you post the code (Ill just make a texture) as I’m sure I can get it working eventually.

AIght! thanks in advance :blush: I guess there’s something wrong with my code so here it is!:

    Material mat = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md");
    mat.setTexture("ColorMap", assetManager.loadTexture("Textures/orangeFrame.png"));
    Box b = new Box(1f, 1f, 1f);
    Geometry geom = new Geometry("Holly Cube", b);
    geom.setLocalTranslation(0, 5, 0);


Added this and it works for me, hope this helps

1 Like

It worked!!!

1 Like