Added mask-matrix.