That is the Birkeland-Eyde process, which was superceded by the Haber-Bosch process because it is much more energy effective.
As far as I understand, the reasons for using methane as the hydrogen source in industrial processes is because of costs and the difficulty in scaling electrolysis industrially.