fixed hash algorithm for color generation