diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-03-11 06:52:57 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-03-11 06:52:57 +0300 |
commit | 4184f890fdbef7409af27f1e9a13b01161001ef2 (patch) | |
tree | 2958d2c1579c5055ff8aa708774150ef8d20a90f /source/blender/gpu/intern/gpu_extensions.c | |
parent | f9cca128869fc07da46c095ac7dce16467121092 (diff) |
GPU: minor changes to support standalone GHOST builds
- Move gpuPush/Pop from GPU_draw.h into GPU_state.h
as this is for pushing/popping state.
- Add 'GPU_STANDALONE' define, to bypass use of user-preferences
for theme colors and pixelsize, as well as pbvh init/free functions.
Needed to get GHOST tests working again.
Diffstat (limited to 'source/blender/gpu/intern/gpu_extensions.c')
-rw-r--r-- | source/blender/gpu/intern/gpu_extensions.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_extensions.c b/source/blender/gpu/intern/gpu_extensions.c index 4676cc3b244..5a2b74f3407 100644 --- a/source/blender/gpu/intern/gpu_extensions.c +++ b/source/blender/gpu/intern/gpu_extensions.c @@ -348,7 +348,11 @@ void gpu_extensions_exit(void) bool GPU_mem_stats_supported(void) { +#ifndef GPU_STANDALONE return (GLEW_NVX_gpu_memory_info || GLEW_ATI_meminfo) && (G.debug & G_DEBUG_GPU_MEM); +#else + return false; +#endif } void GPU_mem_stats_get(int *totalmem, int *freemem) |