MP4DeleteTrack man page
MP4DeleteTrack — Delete a track
Specifies the mp4 file to which the operation applies.
Specifies the track to which the operation applies.
Upon success, true (1). Upon an error, false (0).
MP4DeleteTrack deletes the control information associated with the specified track. The trackId will become invalid if this call succeeds.
Note that the samples associated with this track are not deleted with this call. This can be accomplished via MP4Optimize(). The reason for this is that multiple tracks can reference the same samples so a global view must be taken when deleting them.