summaryrefslogtreecommitdiff
path: root/Runtime/GfxDevice/VramLimits.h
diff options
context:
space:
mode:
Diffstat (limited to 'Runtime/GfxDevice/VramLimits.h')
-rw-r--r--Runtime/GfxDevice/VramLimits.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/Runtime/GfxDevice/VramLimits.h b/Runtime/GfxDevice/VramLimits.h
new file mode 100644
index 0000000..238f260
--- /dev/null
+++ b/Runtime/GfxDevice/VramLimits.h
@@ -0,0 +1,11 @@
+#pragma once
+
+// Various limits for what we can do based on VRAM size
+
+#define kVRAMEnoughForLargeShadowmaps 480 // VRAM MB after which we allow even higher resolution shadow maps
+
+#define kVRAMMaxFreePortionForShadowMap 0.3f // allow single shadowmap to take 30% of possibly free VRAM
+#define kVRAMMaxFreePortionForTexture 0.4f // allow single texture to take 40% of possibly free VRAM
+
+
+int ChooseSuitableFSAALevel( int width, int height, int backbufferBPP, int frontbufferBPP, int depthBPP, int fsaa );