The KeysForge app will give you printable key layouts using just the photo of one locks.The KeysForge app was developed by three academics and allows anyone to reproduce a key with 3D printing from the photo of a lock.
Assistant Professor Eric Wustrow from the University of Colorado and two his colleagues disclosed their work to congress Chaos Communications in Hamburg last month.
The application tries to create an image in black and white and distinguish the keyhole. Then he starts looking for the largest black spot to locate the path and the shape of the key.
The tool creates a CAD model of a key from the image of a lock. This model can then be 3D printed in plastic or in metal.
You can read all of the researchers' paper from the link below
Replication Prohibited: Attacking Restricted Keyways with 3D Printing