The pressure variation of the bandgap, at the isostructural phase transition of wurtzite InN, is determined theoretically, using the first-principles total-energy pseudopotential method. It is found that the bandgap (as well as the structural parameters) exhibit three different types of behavior, in three regions of pressure. Optical experiments at low temperatures could then be employed to directly identify the two different wurtzite phases of InN.