Make layer's use_mask flag default to true. Support a bit array describing the mask to use. Improve error handling in ProjectRasterFile (also addresses RT #2947).