Fix: use env for temp directory, it better handles utf-8 directory

This commit is contained in:
Raimund58
2020-12-13 10:29:38 +01:00
committed by Laurent Clouet
parent fa82be607c
commit 7d984f94a5
2 changed files with 7 additions and 24 deletions

View File

@@ -220,6 +220,8 @@ import lombok.Getter;
Map<String, String> new_env = new HashMap<String, String>();
new_env.put("BLENDER_USER_CONFIG", configuration.getWorkingDirectory().getAbsolutePath().replace("\\", "\\\\"));
new_env.put("TEMP", configuration.getWorkingDirectory().getAbsolutePath().replace("\\", "\\\\"));
new_env.put("TMP", configuration.getWorkingDirectory().getAbsolutePath().replace("\\", "\\\\"));
new_env.put("CORES", Integer.toString(configuration.getNbCores()));
new_env.put("PRIORITY", Integer.toString(configuration.getPriority()));
new_env.put("PYTHONPATH", ""); // make sure blender is using the embedded python, if not it could create "Fatal Python error: Py_Initialize"