updated from the CamFort project