Fixes an issue when rgbMask is missing