Skip to content

Commit

Permalink
Fixing isPOT function for value == 0 case.
Browse files Browse the repository at this point in the history
  • Loading branch information
corbanbrook committed Mar 10, 2011
1 parent 9c654c9 commit 170d951
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion webgl-2d.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
var M_HALF_PI = M_PI / 2.0;

function isPOT(value) {
return ((value - 1) & value) === 0;
return value > 0 && ((value - 1) & value) === 0;
}

var vec3 = {
Expand Down

0 comments on commit 170d951

Please sign in to comment.