I have an image which contains a photo of playground behind a low chain mesh fence.
I'm trying to superimose an object behind that fence into the playground.
This means the portion of the object that is behind the fence must be infront of the background but behind the fence.
Being chain mesh and not very regular its too hard to erase every hole in the mesh so the object showes through. Playing with the opacity of the object where it's behind the fence looks a little clunky.
You might try the technique in the first part of the video below, but instead of using the resulting selection (shown at 5:08) to erase the fence, invert it so you can then create a mask of the holes between the fence wires, through which the object can show through.