Predicting visibility of interference fringes in X-ray grating interferometry.