How to set parameters of orthographic camera to see only a specified plane My question: 
How can I set the parameters of orthographic camera, to look only at a specific plane from orthogonal position, and at the same time to see the whole plane on the render (fit the size of render to the plane size of a plane)? 

Big picture: I have multiple planes in 3D space and I want to take a photo of each plane (render each plane) using python script. I want to set the parameters of orthographic camera, such that the camera is looking at one plane at a time from orthogonal position and the whole plane is visible on the render. Planes should not be moved in 3D space and planes are rectangular, and can be of any width/height combination.

-Just as an idea: Maybe a part of the solution would to use the "Damped track constraint", but I'm still not sure about setting the camera orthogonally and to see the whole plane.

Thank you very much for your time!
You can create a macro with the following steps for each plane:


set plane as active object.
bpy.ops.view3d.view_axis(type='TOP', align_active=True)
bpy.ops.view3d.camera_to_view()
bpy.ops.view3d.camera_to_view_selected()
if needed, change your render resolution to the same dimensions of the plane.