8 std::unordered_map<std::string, std::shared_ptr<Texture>> modelCache;
10 for (
const auto &entry : std::filesystem::directory_iterator(folderPath)) {
11 if (entry.is_regular_file()) {
13 const std::string &filepath = entry.path().string();
14 modelCache[filepath] = create(device, filepath);
This file contains the Texture Factory class.
static std::unordered_map< std::string, std::shared_ptr< Texture > > loadAll(Device &device, const std::string &folderPath)