From a803c12995e8d426d247e62c014bda70ab9e79e9 Mon Sep 17 00:00:00 2001 From: Toni Spets Date: Thu, 24 Mar 2011 19:08:27 +0200 Subject: [PATCH] Use npot textures if the surface size exceeds 1024x1024 --- render.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/render.c b/render.c index 0e48ccc..6634832 100644 --- a/render.c +++ b/render.c @@ -25,8 +25,8 @@ DWORD WINAPI render_main(void) int i,j; HGLRC hRC; - int tex_width = 1024; - int tex_height = 1024; + int tex_width = ddraw->render.width > 1024 ? ddraw->render.width : 1024; + int tex_height = ddraw->render.height > 1024 ? ddraw->render.height : 1024; float scale_w = 1.0f; float scale_h = 1.0f; int *tex = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, tex_width * tex_height * sizeof(int));