Allow user to set maximum memory he allows render to use
This commit is contained in:
@@ -47,6 +47,7 @@ public class Configuration {
|
||||
private String proxy;
|
||||
private int maxUploadingJob;
|
||||
private int nbCores;
|
||||
private int maxMemory; // max memory allowed for render
|
||||
private int priority;
|
||||
private ComputeType computeMethod;
|
||||
private GPUDevice GPUDevice;
|
||||
@@ -64,6 +65,7 @@ public class Configuration {
|
||||
this.static_exeDirName = "exe";
|
||||
this.maxUploadingJob = 1;
|
||||
this.nbCores = -1; // ie not set
|
||||
this.maxMemory = -1; // ie not set
|
||||
this.priority = 19; // default lowest
|
||||
this.computeMethod = null;
|
||||
this.GPUDevice = null;
|
||||
@@ -127,6 +129,14 @@ public class Configuration {
|
||||
return this.nbCores;
|
||||
}
|
||||
|
||||
public void setMaxMemory(int max) {
|
||||
this.maxMemory = max;
|
||||
}
|
||||
|
||||
public int getMaxMemory() {
|
||||
return this.maxMemory;
|
||||
}
|
||||
|
||||
public void setUsePriority(int priority) {
|
||||
if (priority > 19)
|
||||
priority = 19;
|
||||
|
||||
Reference in New Issue
Block a user