Dear Goncalo and the rest of the Bonsai community,
I am using a lens that gives my camera a fish-eye view, which I need to undistort. I have been playing around with the "Find Chessboard Corners", "Calibrate Camera Chessboard" and "Undistort" nodes, but I can't quite get what I want. I have searched in this forum and on the Bonsai website, but I have not been able to find a lot of information about how to properly use these nodes. I have attached the script that I am using.
Basically, I have a 2m x 2m maze, and I am moving the checkerboard around this maze while the "Calibrate Camera Chessboard" continuously outputs the estimated camera intrinsic parameters. After having made sure the checkerboard have covered all edges and the center of my maze, I save the outputted estimated intrinsic parameters and then manually input them into the "Undistort" node. However, either only the area around the checkerboard gets undistorted, or there is always some parts of the maze that remain undistorted.
I have also attached two pictures, one frame showing an example of the the undistorted image as seen from the "Find Chessboard Corners" node, and one example of a frame from the from the Undistort node.
Thank you for the help.
Nils