Get full body mask as texture on UE5

Hi, any ideas on how to mask out a detected full body in UE5?
When I use the show image on the initializer, it does all masking in full depth. I want to get only persons without any background as a texture to apply this texture to 3d objects.

Hi @MrDabolins, welcome to the forums!

I’m not sure how you would proceed to do exactly what you want, but you can access the mask data from the BodyData structure. I’m afraid that to manipulate it as you wish, you will have to dive into C++ a bit because we haven’t exposed some of the methods to manipulate the mask yet.
Using the segmentation of our UE5 plugin is not a common use case, so I don’t know when it will be done, sorry.

I’ll log it on our side though, thanks for the report.

Thank you for your response. It has clarified my workflow, and I will use the background segmentation example as a starting point. My goal is to combine real-time camera feed with CG effects, essentially compositing. I plan to use body segmentation to isolate only the human body. The current segmentation example segments everything, including tables, lamps, and other objects. This makes it difficult to achieve the desired CG effects. I hope that segmentation will be implemented soon. The work done is really impressive, and ZED opens up a new way of stage art. Thank you, guys!

1 Like

Thanks for the kind words @MrDabolins !

If you’re taking reference from the background subtraction, I think you can set the indexes in “Object Detection Runtime Parameters/Object Classe Filters” to 0 instead of -1, for all except for the index [0] which is the PERSON class. It should segment only the people if I’m not mistaken.

@MrDabolins

:warning: I was wrong for the background subtraction, I just checked and it does not segment, it uses the depth to clamp out pixels further than a set distance.

Also, I’m told there is an issue with the Object Detection in the wrappers that will be fixed in the next release. We’ll add the means to manipulate the masks in BP in the plugin as soon as possible after that.