Adding camera to sensorsdb.xml

I want to save my camera (DJI M3E) to the database, but can’t seem to figure it out. The details I need are below, I can’t get the focal length or principal point to populate as I can’t find the schema for this xml. Any help is appreciated.

Hi @MarkyMike2011
You can find the workflow for that here: Help needed - Drone camera is not in the sensor database!

I need to set the focal length and the principal point but I can’t find the syntax that works

I don’t think principle points are an option for the cam database. The focal is fine from just EXIF; there is no need to add so much precision; 25 is accurate enough.

That said, if you do want to change these parameters, you can create a single button to do it using the sequencer tool.

Just edit this line with your parameters:

-selectImage g/M3E/ -editInputSelection "inpPPX=0.121284" -editInputSelection "inpPPY=-0.221004" -editInputSelection "inpFocal=25.287987" -editInputSelection "inpRadial1=-0.075445" -editInputSelection "inpRadial2=-0.166909" -editInputSelection "inpRadial3=0.306893" -editInputSelection "inpRadial4=-0.205911" -editInputSelection "inpTangential1=-0.000058" -editInputSelection "inpTangential2=0.000388"

add the line to a console window and hit the plus sign:

Now name your sequence, and you will have a button to add those parameters to all cams with M3E in their names (the first command will find the string using regular expressions).

Be very aware of adding principal points unless you are sure they are in the correct format for RC. I recommend just running an alignment without changing any parameters, seeing what principal points RC calculates, and then making sure yours are in the same ballpark. RC principle points are in mm and wrt full frame measured from the centre. So, if you have a principal point in pixels from the edge of a crop sensor, you need to do a lot of calculations to get it right, and setting this wrong will make a horrible mess of the alignment. If you make any mistakes in this process and get a bad alignment and need to make changes, always clear the cache before doing another alignment.