How to use depth priority when debug drawing in c++?

For example DrawDebugDirectionalArrow() takes a DepthPriority as a parameter, but I don’t know how to use it. When I give 1 or (uint8)('\001') it does not appear on the screen ; and when I give (uint8)('\002') or greater I can see it but not in front of other objects (same as with the default value (uint8)('\000')).

How can I have my debug drawings in front of anything else?

Have you managed to figure this out yet ?

nope :-/ …

Have you tried SDPG_Foreground and SDPG_MAX from ESceneDepthPriorityGroup? (API) Inspecting DrawDebugHelpers.cpp makes me think they are the original enum values. That said, SDPG_Foreground should be equal to 1 and SDPG_MAX to 2, so it may give the same results…

1 Like

This gives the same results for me in 4.19.

Has depth priority for debug drawing been nonfunctional for almost 3 years?

Thanks! This works for me in UE 4.27, I am using SDPG_Foreground :slight_smile:

Use ECC_WorldStatic
This has worked for everything I’ve needed but there must be others should you need them.
IntelliSense gave me this as recommended so I guess they must have made it easier since you guys had this problem - it was still confusing as the parameter had a terrible prompt.
Just for anyone else who comes across this thread.