Label3D Outline renders under Sprite3D even when closer to the camera

Godot Version

Godot 4.3 Dev 5

Question

I have a Label 3D that I’m trying to position over top a Sprite3D and I was noticing that the outline is rendering underneath the Sprite3D even though the text is correctly on top. Both are laying flat so that positive Y is UP and towards the camera. I’ve pulled the text up with no change. I also tried adjusting some values like Sort order just to see if it made any difference, but nothing seems to work.

I was curious if anyone has run into similar behavior? I wanted to ask first before logging it as an issue.

image

This happens because transparent objects need to be sorted and the outline has a lower sort priority than the Sprite3D by default.

You can change the Label3D.alpha_cut to Discard and tweak the Label3D.alpha_scissor_threshold This method has some drawbacks listed here Label3D — Godot Engine (stable) documentation in English

Alternatively, you can change the Label3D.render_priority and Label3D.outline_render_priority to higher values than the Sprite3D VisualInstance3D.sorting_offset. For example, if the Sprite3D sorting_offset is 0 then you will need to set the Label3D render_priority and outline_render_priority to 1 and 0 respectively. This method also has some drawbacks like that the label will always be drawn on top of the sprite no matter the depth.

More info here 3D text — Godot Engine (stable) documentation in English

1 Like

Thanks! I completely missed that outline render priority parameter under “Flags”.