#ifndef IOUTPUT_H#define IOUTPUT_H#include <cstdio>#include "_cvcommon.h"structCvMat;structCvRect;classIOutput{public:enumOutputType{PNG_DATASET,JPG_DATASET};public:virtualboolwrite(constCvMat&img,constCvRect&boundingBox)=0;virtual~IOutput();staticIOutput*createOutput(constchar*filename,OutputTypetype);protected:IOutput();/* finds the beginning of the last token in the path */voidfindFilePathPart(char**partOfPath,char*fullPath);virtualboolinit(constchar*filename);protected:intcurrentIdx;charimgFullPath[PATH_MAX];char*imgFileName;FILE*annotationsList;};#endif // IOUTPUT_H