Figuring out bitmasks.