[rcore] Add filtering folders to `LoadDirectoryFilesEx()`/`ScanDirectoryFiles()` (#4302)
* Add filtering folders in ScanDirectoryFiles and ScanDirectoryFilesRecursively
Add define FILTER_FOLDER for that purpose
Fix folder names matching filter being added to result
* Move FILTER_FOLDER define to internals of rcore and document option in comment
@ -251,6 +251,10 @@ unsigned int __stdcall timeEndPeriod(unsigned int uPeriod);
#define MAX_AUTOMATION_EVENTS 16384 // Maximum number of automation events to record
#endif
#ifndef FILTER_FOLDER
#define FILTER_FOLDER "/DIR" // Filter string used in ScanDirectoryFiles, ScanDirectoryFilesRecursively and LoadDirectoryFilesEx to include directories in the result array