XQFaceDatabase Class Reference

#include <imagerecognition/xqfacedatabase.h>

Link against: faceplatform.lib

class XQFaceDatabase : public QObject, public QObject

The interface to the database that stores the learnings.

Inherits from

  • XQFaceDatabase
    Public Member Enumerations
    enumFaceGroupProperty { FaceId, FaceCount, FaceThumbnailPath }
    enumFaceGroupType { NamedGroup, UnnamedGroup, AllGroups }
    Public Member Functions
    XQFaceDatabase(XQFaceThumbnailer &, const QString &, QObject *)
    ~XQFaceDatabase()
    QString defaultPath()
    XQFaceGroup faceGroup(const QString &)
    QAbstractItemModel *faceGroups(FaceGroupType)
    XQFaceThumbnailer &thumbnailer()
    Public Slots
    voidclearFaceReference(const QString &, const QString &)
    voidclearFaceReferences(const QString &)
    voidclearSourceReferences(const QString &)
    Public Signals
    voidfaceUpdated(const XQFaceRegion &, const QString &)
    voidgroupMerged(const QString &, const QString &)
    Inherited Attributes
    QObject::d_ptr
    QObject::objectName
    QObject::staticQtMetaObject
    Inherited Functions
    QObject::QObject(QObjectPrivate &,QObject *)
    QObject::blockSignals(bool)
    QObject::childEvent(QChildEvent *)
    QObject::children()const
    QObject::connect(const QObject *,const QMetaMethod &,const QObject *,const QMetaMethod &,Qt::ConnectionType)
    QObject::connect(const QObject *,const char *,const QObject *,const char *,Qt::ConnectionType)
    QObject::connect(const QObject *,const char *,const char *,Qt::ConnectionType)const
    QObject::connectNotify(const char *)
    QObject::customEvent(QEvent *)
    QObject::deleteLater
    QObject::destroyed
    QObject::disconnect(const QObject *,const QMetaMethod &,const QObject *,const QMetaMethod &)
    QObject::disconnect(const QObject *,const char *)
    QObject::disconnect(const QObject *,const char *,const QObject *,const char *)
    QObject::disconnect(const char *,const QObject *,const char *)
    QObject::disconnectNotify(const char *)
    QObject::dumpObjectInfo()
    QObject::dumpObjectTree()
    QObject::dynamicPropertyNames()const
    QObject::event(QEvent *)
    QObject::eventFilter(QObject *,QEvent *)
    QObject::findChild(const QString &)const
    QObject::findChildren(const QRegExp &)const
    QObject::findChildren(const QString &)const
    QObject::inherits(const char *)const
    QObject::installEventFilter(QObject *)
    QObject::isWidgetType()const
    QObject::killTimer(int)
    QObject::moveToThread(QThread *)
    QObject::objectName()const
    QObject::parent()const
    QObject::property(const char *)const
    QObject::receivers(const char *)const
    QObject::registerUserData()
    QObject::removeEventFilter(QObject *)
    QObject::sender()const
    QObject::senderSignalIndex()const
    QObject::setObjectName(const QString &)
    QObject::setParent(QObject *)
    QObject::setProperty(const char *,const QVariant &)
    QObject::setUserData(uint,QObjectUserData *)
    QObject::signalsBlocked()const
    QObject::startTimer(int)
    QObject::thread()const
    QObject::timerEvent(QTimerEvent *)
    QObject::userData(uint)const
    QObject::~QObject()

    Detailed Description

    This class interfaces the application with the database in the following ways
    • Provides (instantiates) an abstract item model for reading the database

    • Emits signals when database is changed due to actions from other applications (or even from some other part of the application)

    • Provides API to access data for a given person

    • Provides API to cleanup dead references in the database.

    Note:

    Most of the signals and functions begining with clear (e.g. clearSourceReferences) are intended for advanced usecases where the application is doing the maintainance of the learning database. Typically, there would be only one such application on the device.

    Member Enumeration Documentation

    Enum FaceGroupProperty

    Enumrations used to index the columns of the abstract item model.

    EnumeratorValueDescription
    FaceId0

    Name or tag

    FaceCount
    Number of Face regions present in this group. (in other words, the number of images this person is present in)
    Note:

    If a person is present twice in an image (e.g. a picture of a person looking into a mirror) then this would add two to face count (counted twice)

    FaceThumbnailPath

    The path/identifier to the cover thumbnail for this Face group.

    Enum FaceGroupType

    A filter used while creating the abstract item model.

    EnumeratorValueDescription
    NamedGroup0

    All groups that have a name/tag associated with it. (Another term for "Known").

    UnnamedGroup

    All groups that dont have a name/tag associated with it. (Another term for "Unknown")

    AllGroups

    All groups with and without tags

    Constructor & Destructor Documentation

    XQFaceDatabase ( XQFaceThumbnailer &, const QString &, QObject * )

    XQFaceDatabase(XQFaceThumbnailer &thumbnailer,
    const QString &path =  QString(),
    QObject *parent = 0
    )

    ~XQFaceDatabase ( )

    ~XQFaceDatabase()

    Destructor for XQFaceDatabase.

    Member Function Documentation

    clearFaceReference ( const QString &, const QString & )

    voidclearFaceReference(const QString &sourceId,
    const QString &faceId
    )[slot]

    clearFaceReferences ( const QString & )

    voidclearFaceReferences(const QString &faceId)[slot]

    clearSourceReferences ( const QString & )

    voidclearSourceReferences(const QString &sourceId)[slot]

    defaultPath ( )

    QString defaultPath()[static]

    A convinience function to get the default path to learnings-database.

    This is the path to learnings database that will be assumed if path is not provided in the XQFaceDatabase constructor

    Return Value
    The default learnings database path that is used if path is not provided.

    faceGroup ( const QString & )

    XQFaceGroup faceGroup(const QString &faceId)

    faceGroups ( FaceGroupType )

    QAbstractItemModel *faceGroups(FaceGroupTypegroupType = AllGroups)

    faceUpdated ( const XQFaceRegion &, const QString & )

    voidfaceUpdated(const XQFaceRegion &faceRegion,
    const QString &oldFaceId
    )[signal]

    groupMerged ( const QString &, const QString & )

    voidgroupMerged(const QString &oldId,
    const QString &newId
    )[signal]

    thumbnailer ( )

    XQFaceThumbnailer &thumbnailer()

    A convinience function to get a reference to the thumbnailer object in use.

    Can be used to get a reference to the thumbnailer object that was supplied when the constructor was called

    Return Value
    Reference to the thumbnailer object that is being used.