diff --git a/sdk/openbr_plugin.h b/sdk/openbr_plugin.h index 0a0bd66..ca49a32 100644 --- a/sdk/openbr_plugin.h +++ b/sdk/openbr_plugin.h @@ -845,6 +845,7 @@ class BR_EXPORT Format : public Object public: virtual ~Format() {} virtual Template read() const = 0; /*!< \brief Returns a br::Template created by reading #br::Object::file. */ + virtual void write(const Template &t) const = 0; /*!< \brief Writes the br::Template to #br::Object::file. */ }; /*! diff --git a/sdk/plugins/format.cpp b/sdk/plugins/format.cpp index 9e1e7b2..38fe03b 100644 --- a/sdk/plugins/format.cpp +++ b/sdk/plugins/format.cpp @@ -63,6 +63,12 @@ class csvFormat : public Format return Template(m); } + + void write(const Template &t) const + { + (void) t; + qFatal("csvFormat::write not supported."); + } }; BR_REGISTER(Format, csvFormat) @@ -105,6 +111,12 @@ class DefaultFormat : public Format return t; } + + void write(const Template &t) const + { + (void) t; + qFatal("csvFormat::write not supported."); + } }; BR_REGISTER(Format, DefaultFormat) @@ -129,6 +141,12 @@ class webcamFormat : public Format videoCapture->read(m); return Template(m); } + + void write(const Template &t) const + { + (void) t; + qFatal("webcamFormat::write not supported."); + } }; BR_REGISTER(Format, webcamFormat) @@ -191,6 +209,12 @@ class xmlFormat : public Format return t; } + + void write(const Template &t) const + { + (void) t; + qFatal("xmlFormat::write not supported."); + } }; BR_REGISTER(Format, xmlFormat)