Sort out background masks (Issue #2)