Fixed build errors for 64 bit compilation

Compiler complained about size_t size when  going from 32 to 64 bit
compilation, and this let's the program compile while preserving at
least 4294967295 vertices instead of possibly losing some with a cast.