Returns the next power of 2 for the specified value.
The value for which to calculate the next power of 2.
The next power of 2.
math.nextPowerOfTwo(17); // returns 32math.nextPowerOfTwo(32); // returns 32 Copy
math.nextPowerOfTwo(17); // returns 32math.nextPowerOfTwo(32); // returns 32
Returns the next power of 2 for the specified value.