PreviousNext
Help > Programming PhotoModeler - Scripting/DDE Interface > Commands > SetPhotoStation
SetPhotoStation

Description:

Set up a photo's station's orientation (because it is known or you are providing an approximation). Note that single photo orientation processing (e.g. InverseCamera) will ignore this approximation.

Syntax:

"SetPhotoStation ID x y z  0 w p k"

where:

ID is a unique identifier number for the photograph (>=1), "x y z" is the station perspective center, 0 represents this call type (Eualer angle form), and "w p k" are the station's Euler angles (in radians).

OR

"SetPhotoStation ID x y z  1 r11 r12 r13 r21 r22 r23 r31 r32 r33"

where 1 represents this call type (rotation matrix form), the r's are the values of the rotation matrix (e.g. r21 is the element in the 2nd row and 1st column).

OR

"SetPhotoStation ID x y z 2 x2 y2 z2 roll"

where where 2 represents this call type (roll form), the “x2 y2 z2” are the coordinates of the camera center point and “roll” is the roll angle.

 

Note, if the command is successful, it sets the photo to be "oriented".

Return:

"1" if successful or "0" if not.

Failure returns

- insufficient number of parameters

- no project is open

- photo 'ID' does not exist in project

- the 6th parameters is not '0' or '1'

- any one of the r's is larger than 1.0 or smaller than -1.0

Example:

"SetPhotoStation 1 23.3 12.1 -1.3 0 0.0 1.4 -2.1" OR

"SetPhotoStation 1 23.3 12.1 -1.3 1 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0" OR

"SetPhotoStation 1 23.3 12.1 -1.3 2 0.0 0.0 0.0 45.0"

return: "1"