소스 검색

Remove requirement for buffer type images to have width=height on Android devices that do not support NPOT. Now images allowed as long as both height and width are POT on devices that don't support NPOT.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9744 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
iwg..ic 13 년 전
부모
커밋
fa6716877e
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      engine/src/android/com/jme3/renderer/android/TextureUtil.java

+ 1 - 1
engine/src/android/com/jme3/renderer/android/TextureUtil.java

@@ -253,7 +253,7 @@ public class TextureUtil {
         
         if (!NPOT) {
             // Check if texture is POT
-            if (!FastMath.isPowerOfTwo(width) || width != height) {
+            if (!FastMath.isPowerOfTwo(width) || !FastMath.isPowerOfTwo(height)) {
                 throw new RendererException("Non-power-of-2 textures "
                         + "are not supported by the video hardware "
                         + "and no scaling path available for image: " + img);