1
Python and Java API / Setting bounding box via 2 markers
« on: July 18, 2018, 07:01:37 AM »
Hi all
I'm refining a workflow for doing high resolution scanning using photogrammetry and am at the stage of adding some more automation. Most of the generic processing stuff I can probably work my way through but I have one things that's a bit more complex that's similar to http://www.agisoft.com/forum/index.php?topic=8060.msg38554.
I'm using an L-shaped target with coded CPs to set the orientation of the image. This is working nicely and I'm looking to add cropping to this. Having looked through a few posts this might be best done by defining the bounding box after alignment so that only the required area is processed. I detect markers and import cords prior to alignment so rotation of the model is not required. Bounding box would need to be aligned to the coordinate system (already a script for that) and then positioned/sized to match CPs defining the top/left and bottom right corners. CP labels would be constant and named during detection "target NNN" Height of bounding box is OK after alignment
Current setup is attached. Tope Left CP would be added to L-shaped scale bar, bottom right would be a single CP placed manually. I could hard -code the top/left cords but the script would be a little more re-useable getting the cords from a CP.
Any help would be greatly appreciated and happy to share details of the rest of the setup. Using a Hasselblad H5D60 to scan at 600dpi up to ~2x4m including foldouts from very large books which don't lie flat.
I'm refining a workflow for doing high resolution scanning using photogrammetry and am at the stage of adding some more automation. Most of the generic processing stuff I can probably work my way through but I have one things that's a bit more complex that's similar to http://www.agisoft.com/forum/index.php?topic=8060.msg38554.
I'm using an L-shaped target with coded CPs to set the orientation of the image. This is working nicely and I'm looking to add cropping to this. Having looked through a few posts this might be best done by defining the bounding box after alignment so that only the required area is processed. I detect markers and import cords prior to alignment so rotation of the model is not required. Bounding box would need to be aligned to the coordinate system (already a script for that) and then positioned/sized to match CPs defining the top/left and bottom right corners. CP labels would be constant and named during detection "target NNN" Height of bounding box is OK after alignment
Current setup is attached. Tope Left CP would be added to L-shaped scale bar, bottom right would be a single CP placed manually. I could hard -code the top/left cords but the script would be a little more re-useable getting the cords from a CP.
Any help would be greatly appreciated and happy to share details of the rest of the setup. Using a Hasselblad H5D60 to scan at 600dpi up to ~2x4m including foldouts from very large books which don't lie flat.