Modified for Japanese. original: http://neuron2.net/dgmpgdec/dgmpgdec.html