I am taking my first stab at using the python API in Photoscan. I have been able to create a document, load photos into a chunk and align/create geometry. However, I want to update the camera calibration information and have been unable to get it to work. Relevant snippet of code is below:
for i in range(0,numFiles):
p = PhotoScan.Photo()
testFile = data[i].rstrip()
p.open(testFile)
cenX = p.width/2
cenY = p.height/2
p.user_calib = ps.Calibration(cx=cenX,cy=cenY,fx=12180.0,fy=12180.0)
newChunk.photos.add(p)
I'm trying to use p.user_calib to set the calibration, but it sets all values to zero when I do what's above. Any thoughts???
Thank you.