Fixed frame index order

Was making 0 the index of the latest frame; now it's the index of the
oldest one.