diff options
author | Kenneth Russel <[email protected]> | 2007-01-26 19:48:36 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2007-01-26 19:48:36 +0000 |
commit | 82126b9b2114e0be1d16dbdea7bbf6a17c9cad2e (patch) | |
tree | 3fd1d2236b2db150678b5a2cd63846fe4829dea7 /src/classes/com/sun/opengl | |
parent | a1d2ef5526932a14bd02c055e3ead55b3a4844df (diff) |
Fixed Issue 267: class DDSImage return incorrect mipmap level data.
Applied recommended fix from submitter.
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1107 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/opengl')
-rwxr-xr-x | src/classes/com/sun/opengl/util/texture/spi/DDSImage.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/classes/com/sun/opengl/util/texture/spi/DDSImage.java b/src/classes/com/sun/opengl/util/texture/spi/DDSImage.java index 12a855c57..8680ada1c 100755 --- a/src/classes/com/sun/opengl/util/texture/spi/DDSImage.java +++ b/src/classes/com/sun/opengl/util/texture/spi/DDSImage.java @@ -722,7 +722,7 @@ public class DDSImage { for (int i = 0; i < map; i++) { width >>= 1; } - return width; + return Math.max(width, 1); } private int mipMapHeight(int map) { @@ -730,7 +730,7 @@ public class DDSImage { for (int i = 0; i < map; i++) { height >>= 1; } - return height; + return Math.max(height, 1); } private int mipMapSizeInBytes(int map) { |