This psychophysical method can be used to quantified pictorial relief (the perceived surface depth profile). The PsychToolbox (Matlab) software for doing the gauge figure task can be found here.
For long I have wanted to make a processing version. I changed it a bit (especially the preparation program) but it works (download)! Please cite the original paper if you publish something based on either code:
M.W.A. Wijntjes. Probing pictorial relief: from experimental design to surface reconstruction. Behavior research methods, 44(1):135–143, 2012.
gif from experiment:
Screenshot from simple mathematica notebook (included in zip):
Other processing code: