mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-17 19:10:24 +00:00
Use std::array for a list of extensions
This list doesn't change and the size is known at compile time.
This commit is contained in:
parent
975e4f9908
commit
ffacc30597
@ -1,5 +1,7 @@
|
||||
#include "loadingscreen.hpp"
|
||||
|
||||
#include <array>
|
||||
|
||||
#include <osgViewer/Viewer>
|
||||
|
||||
#include <osg/Texture2D>
|
||||
@ -67,7 +69,7 @@ namespace MWGui
|
||||
mVFS->normalizeFilename(pattern);
|
||||
|
||||
/* priority given to the left */
|
||||
std::list<std::string> supported_extensions = {".tga", ".dds", ".ktx", ".png", ".bmp", ".jpeg", ".jpg"};
|
||||
const std::array<std::string, 7> supported_extensions {{".tga", ".dds", ".ktx", ".png", ".bmp", ".jpeg", ".jpg"}};
|
||||
|
||||
auto found = index.lower_bound(pattern);
|
||||
while (found != index.end())
|
||||
|
Loading…
Reference in New Issue
Block a user