Replaced uint by unsigned int for Windows compatibility.