Applications of X-ray dynamical diffraction techniques to materials research