QDir dir(path);
QStringList nameFilters;
nameFilters << "*.jpg" << "*.png";
files = dir.entryList(nameFilters, QDir::Files|QDir::Readable, QDir::Name);
QStringList getFileNames(const QString &path)
{
QDir dir(path);
QStringList nameFilters;
nameFilters << "*.jpg" << "*.png";
QStringList files = dir.entryList(nameFilters, QDir::Files|QDir::Readable, QDir::Name);
return files;
}