Rednering sprites according to the hierarchy of sprites and not sorting order? (Sorting group)

Hi. I want to render sprites according to the hierarchy of sprites and not based on sorting order.
I have utilized sorting group but it needs sprites have the same sorting order and layer.

Canvas does this. Otherwise, you want to write your own renderer that works like canvas.