From bf9c3de94a98c91cc4044c4bd7b3314559484ede Mon Sep 17 00:00:00 2001 From: rachytski Date: Sat, 17 Dec 2011 14:54:31 +0400 Subject: [PATCH] made map texture squared. --- yg/render_state.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/yg/render_state.cpp b/yg/render_state.cpp index a10b685e5c..04ca2c96c6 100644 --- a/yg/render_state.cpp +++ b/yg/render_state.cpp @@ -55,6 +55,9 @@ namespace yg m_textureWidth = static_cast(pow(2, ceil(log(double(w)) / log2))); m_textureHeight = static_cast(pow(2, ceil(log(double(h)) / log2))); + + m_textureWidth = max(m_textureWidth, m_textureHeight); + m_textureHeight = max(m_textureWidth, m_textureHeight); } }