Renderer with different resolutions on same camera

My goal is to have a 3d scene where i can render some objects in one resolution and other objects in another.
My solution was to have two cameras, one rendering at a low res and the other at the current screen res then compare the depth of the rendered images and output the desired image. The problem is im not able to get the depth of the cameras into a render texture.
Does anyone have a solution to this?

Got answered in the forum