diff --git a/sdk/plugins/format.cpp b/sdk/plugins/format.cpp index 38fe03b..5ae57d4 100644 --- a/sdk/plugins/format.cpp +++ b/sdk/plugins/format.cpp @@ -23,6 +23,8 @@ #include #include +#include "core/bee.h" + using namespace br; using namespace cv; @@ -123,6 +125,50 @@ BR_REGISTER(Format, DefaultFormat) /*! * \ingroup formats + * \brief Reads a NIST BEE similarity matrix. + * \author Josh Klontz \cite jklontz + */ +class mtxFormat : public Format +{ + Q_OBJECT + + Template read() const + { + return BEE::readSimmat(file); + } + + void write(const Template &t) const + { + BEE::writeSimmat(t, file); + } +}; + +BR_REGISTER(Format, mtxFormat) + +/*! + * \ingroup formats + * \brief Reads a NIST BEE mask matrix. + * \author Josh Klontz \cite jklontz + */ +class maskFormat : public Format +{ + Q_OBJECT + + Template read() const + { + return BEE::readMask(file); + } + + void write(const Template &t) const + { + BEE::writeMask(t, file); + } +}; + +BR_REGISTER(Format, maskFormat) + +/*! + * \ingroup formats * \brief Retrieves an image from a webcam. * \author Josh Klontz \cite jklontz */