Methods and apparatus provide for a clip-beat aligner that identifies
musical beats in an audio file. An editing mode is provided to associate
the audio file with a media segment according to a timeline. The
clip-beat aligner aligns a boundary of the media segment with a musical
beat on the timeline. Upon performing an editing operation, the clip-beat
aligner maintains that the boundary of the media segment is aligned with
any one of the musical beats. To align a boundary of each media segment
with a musical beat, the clip-beat aligner identifies a musical beat that
is proximate to the position of the media segment's boundary. The
clip-beat aligner then aligns the media segment's boundary with the
proximate musical beat by, if necessary, automatically trimming the media
segment's duration such that the media segment's boundary occurs at the
same moment in time as the proximate musical beat.