public virtual int getNumTileParts(int t) { if (firstPackOff == null || firstPackOff[t] == null) { throw new System.InvalidOperationException("Tile " + t + " not found in input codestream."); } return firstPackOff[t].Length; }