[vtk-developers] Power-of-two

David Gobbi david.gobbi at gmail.com
Fri Mar 8 14:54:53 EST 2013


On Fri, Mar 8, 2013 at 12:46 PM, David Lonie <david.lonie at kitware.com> wrote:

>> + CeilLog2
>> + NextPowerOfTwo
>
> These two are the clearest names to me. The others aren't exactly clear what
> the function does.

NextPowerOfTwo isn't really accurate, i.e. if "x" is already a power
of two the the function isn't going to give the next.

I guess CeilLog2() wins.

 - David



More information about the vtk-developers mailing list