Export in STL, OBJ, AMF or 3MF

Has anyone tried to generate and export a project into any of these file formats STL, OBJ, AMF, and 3MF from openFrameworks, it may sound stupid because there are excellent 3D modelling / CAD software packages for that purpose, but when it comes to a work that it has to be written in C++ / OF and later on 3D printed with no edit of other software, how it works?

Never tried but there is a PLY output from ofMesh
https://openframeworks.cc/documentation/3d/ofMesh/#show_save