Added code to compute mean frame of a clip.