Patients about to undergo complex facial surgery could be shown an computer-generated image of how their face will look afterwards.
Surgeons may be able to predict the effects of their work
The software, developed at Brigham and Women's Hospital in Boston, US, uses data from MRI scans to model layers of skin on the face.
It predicts how they will knit together after surgery.
Similar software is used in the rendering of faces in movie special effects, reports New Scientist.
At the moment the computer is able to manipulate images of the various layers of skin and fat close to the surface, rather than the bone and muscle deeper down.
Surgeons cutting out, for example, a tumour on the face, must cut the skin into flaps and fold it away from the operation site, then reposition them once they have finished.
However, it is hard to predict how the skin will bunch or sag following this.
By calculating the relative thicknesses of the skin layers and the fat beneath, the software gives a rendering of how it thinks the face will look afterwards.
The project is led by Steve Pieper, a computer scientist at the hospital, who worked with a company called Digital Elite in Los Angeles.
Digital Elite produce virtual reality humans for use in feature films, television, and computer games.
Once the structure of the face has been mapped, a series of equations is applied to every segment to work out what it will do in response to the stresses and strains of surgery.
The MRI scan can reveal a great deal about the condition of skin layers beneath the surface, such as their stiffness, which could have a major impact on how they cope with being stretched and bunched.
In theory, the programme could predict the level of scarring after surgery.
Modern graphics card technology means that the finished "prediction" can be rendered far more quickly, allowing the surgeon, or even the patient, to look at the likely results from all angles as it rotates in real time.
Pieper told New Scientist: "The system allows the user to see the results of a particular wound closure and edit the cutting path to explore different options."
Future developments could include adding the different properties of ageing skin to the computer model, and trying to predict where skin could sag after an operation.