fixes calculations of segment number for SegmentTemplate mpds