I want to crop just only jpg files in a directory.
Tried if statement, but don't know what should inside if().
void Cutimage::load_images(string img_prefix)
{
for (const auto& entry : fs::directory_iterator(img_prefix)) {
cout << entry.path() << endl; //output all directory's filenames
if () { //I applied some statements but doesn't work
string path_string = entry.path().string();
crop_images(path_string);
}
}