The total pair production cross section of γ-rays in hydrogen and deuterium