Hello r0xx,
In the version 1.1.0 you can do the following to convert camera coordinates from WGS84 to the coordinate system on a different Datum:
import math
import PhotoScan
print("Script started")
doc = PhotoScan.app.document
chunk = doc.chunk
new_crs = PhotoScan.CoordinateSystem("EPSG::21781")
new_wkt = new_crs.wkt.split("TOWGS84[")[1].split("]")[0]
dx, dy, dz, rx, ry, rz, s = [float(x) for x in new_wkt.split(",")]
rx = rx * math.pi / (180. * 3600.)
ry = ry * math.pi / (180. * 3600.)
rz = rz * math.pi / (180. * 3600.)
s = 1.0 + s / 1.0E6
R = s * PhotoScan.Matrix([[1, -rz, ry], [rz, 1, -rx], [-ry, rx, 1]])
T = PhotoScan.Matrix([[R[0,0], R[0,1], R[0,2], dx], [R[1,0], R[1,1], R[1,2], dy], [R[2,0], R[2,1], R[2,2], dz], [0, 0, 0, 1]])
for camera in chunk.cameras:
new_loc = new_crs.project(T.inv().mulp(chunk.crs.unproject(camera.reference.location)))
camera.reference.location = new_loc
chunk.crs = new_crs
PhotoScan.app.update()
print("Script finished")
We'll try to implement additional functionality for the final 1.1.0 release for more convenient conversion operation.