Skip to content

Commit

Permalink
OGL: Use SplitPath() instead of std::regex.
Browse files Browse the repository at this point in the history
  • Loading branch information
waddlesplash committed Sep 27, 2015
1 parent 5643fe5 commit 06c6f60
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Source/Core/VideoBackends/OGL/main.cpp
Expand Up @@ -38,7 +38,6 @@ Make AA apply instantly during gameplay if possible

#include <algorithm>
#include <cstdarg>
#include <regex>

#include "Common/Atomic.h"
#include "Common/CommonPaths.h"
Expand Down Expand Up @@ -105,7 +104,11 @@ static std::vector<std::string> GetShaders(const std::string &sub_dir = "")
});
std::vector<std::string> result;
for (std::string path : paths)
result.push_back(std::regex_replace(path, std::regex("^.*/(.*)\\.glsl$"), "$1"));
{
std::string name;
SplitPath(path, nullptr, &name, nullptr);
result.push_back(name);
}
return result;
}

Expand Down

0 comments on commit 06c6f60

Please sign in to comment.