So what I've been doing to bake Cycles depth maps is based on the following thread found on the BA.org forum and I've mentioned this here already but I'd like to take this a step further using a script but I'm not sure how to do this myself.
If you have a look at the following thread, there is a method for creating Cycles Depth maps using an Orthographic camera but it's limited to planer objects.
http://blenderartists.org/forum/showthread.php?273033-Sculpting-with-UVs-and-displacements/page34
I've expanded this technique slightly by baking an objects' color as white and with no Margin overdraw so that I have a guide for using the above mentioned technique but in a more 3D way since the resulting texture will match up with the 3D Objects UV coordinates.
Basically, this is how I modeled the pillars on the following model.

and the setup looks like this.

The problem is that we have to be very careful around the UV Island boundaries because if the depth map does not match up perfectly with the UV's then the Displace modifier will make a big mess at all the seams.
So this brings me to the question. How can we convert a UV coordinate set into an actual flat 3D mesh that would still match up perfectly with the UV's of the model they were created from.
Here is an image to help illustrate this. 
So does anyone have some thoughts on how to make a script that can make this conversion from UV's to a new mesh that looks exactly like the UV's of the first model so that the Cycles Camera Depth map technique can be used to make perfectly aligned displacement UV maps?
X and Y should translate directly into the new meshs' X and Y positions and z would be set to be all 0's. This worked when I did it with GLSL so it should work here as well.
So I guess my question is how can we write a script using Blender Python that does this?
