mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-02 09:41:13 -06:00
Enable the user to specify a custom temporary folder to keep the OS's temp folder clean
Change the configuration file to point the temp folder into the OpenSpace folder Update Ghoul to not overwrite default font files (closes #944)
This commit is contained in:
Submodule ext/ghoul updated: e91413398b...d73b914734
@@ -78,7 +78,8 @@ Paths = {
|
||||
LOGS = "${BASE}/logs",
|
||||
MODULES = "${BASE}/modules",
|
||||
SCRIPTS = "${BASE}/scripts",
|
||||
SHADERS = "${BASE}/shaders"
|
||||
SHADERS = "${BASE}/shaders",
|
||||
TEMPORARY = "${BASE}/temp"
|
||||
}
|
||||
|
||||
ModuleConfigurations = {
|
||||
|
||||
@@ -104,10 +104,7 @@ namespace openspace {
|
||||
|
||||
class Scene;
|
||||
|
||||
OpenSpaceEngine::OpenSpaceEngine()
|
||||
: _scene(nullptr)
|
||||
, _loadingScreen(nullptr)
|
||||
{
|
||||
OpenSpaceEngine::OpenSpaceEngine() {
|
||||
FactoryManager::initialize();
|
||||
FactoryManager::ref().addFactory(
|
||||
std::make_unique<ghoul::TemplateFactory<Renderable>>(),
|
||||
@@ -164,19 +161,20 @@ void OpenSpaceEngine::registerPathTokens() {
|
||||
ghoul::filesystem::FileSystem::TokenClosingBraces;
|
||||
LDEBUG(fmt::format("Registering path {}: {}", fullKey, path.second));
|
||||
|
||||
const bool override = (fullKey == "${BASE}");
|
||||
if (override) {
|
||||
const bool overrideBase = (fullKey == "${BASE}");
|
||||
if (overrideBase) {
|
||||
LINFO(fmt::format("Overriding base path with '{}'", path.second));
|
||||
}
|
||||
|
||||
const bool overrideTemporary = (fullKey == "${TEMPORARY}");
|
||||
|
||||
using Override = ghoul::filesystem::FileSystem::Override;
|
||||
FileSys.registerPathToken(
|
||||
std::move(fullKey),
|
||||
std::move(path.second),
|
||||
Override(override)
|
||||
Override(overrideBase || overrideTemporary)
|
||||
);
|
||||
}
|
||||
|
||||
LTRACE("OpenSpaceEngine::initialize(end)");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user