// // Created by tangchao on 2022/6/28. // #ifndef XIMEAIMAGERECORDER_CONFIGFILE_H #define XIMEAIMAGERECORDER_CONFIGFILE_H #include #include #include #include #include #include using namespace std; using namespace libconfig; class Configfile { public: Configfile(); void setConfigfilePath(string configfilePath); bool isConfigfileExist(); bool parseConfigfile(); bool getBin(int &bin); bool getEffectiveWindow(int &width, int &offsetx, int &height, int &offsety); bool getEffectiveWindowRoi(int &width, int &offsetx); bool getGainOffset(float &gain, float &offset); bool createConfigFile(); bool updateConfigFile(); private: string m_configfilePath; Config cfg; }; #endif //XIMEAIMAGERECORDER_CONFIGFILE_H