Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'intern/memutil/intern/MEM_CacheLimiterC-Api.cpp')
-rw-r--r--intern/memutil/intern/MEM_CacheLimiterC-Api.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/intern/memutil/intern/MEM_CacheLimiterC-Api.cpp b/intern/memutil/intern/MEM_CacheLimiterC-Api.cpp
index 6156b511f01..f6f1fe419d4 100644
--- a/intern/memutil/intern/MEM_CacheLimiterC-Api.cpp
+++ b/intern/memutil/intern/MEM_CacheLimiterC-Api.cpp
@@ -29,6 +29,8 @@
#include "MEM_CacheLimiter.h"
#include "MEM_CacheLimiterC-Api.h"
+static bool is_disabled = false;
+
static size_t & get_max()
{
static size_t m = 32 * 1024 * 1024;
@@ -45,6 +47,16 @@ size_t MEM_CacheLimiter_get_maximum()
return get_max();
}
+void MEM_CacheLimiter_set_disabled(bool disabled)
+{
+ is_disabled = disabled;
+}
+
+bool MEM_CacheLimiter_is_disabled(void)
+{
+ return is_disabled;
+}
+
class MEM_CacheLimiterHandleCClass;
class MEM_CacheLimiterCClass;