def retime(have, want)
      matching_references = want.references.keys & have.references.keys

      # Resolve subtitle references by getting actual timecodes
      matching_references.each do |reference|
        if (index = have.references[reference][:subtitle])
          have.references[reference][:timecode] = have.subtitles[index][:start]
        end
      end

      case matching_references.length
      when 3..(_infinity = 1.0 / 0)
        # "synchronization jitter" correction by interpolating ? Consider !
      when  2
        retime_by_double_reference(have,
                                   want,
                                   matching_references[0],
                                   matching_references[1])
      when 1
        if have.fps && want.fps
          retime_by_framerate_plus_reference(have, want, matching_references[0])
        else
          retime_by_single_reference(have, want, matching_references[0])
        end
      when 0
        retime_by_framerate(have, want) if have.fps && want.fps
      end
    end
def retime(have, want)
      matching_references = want.references.keys & have.references.keys

      # Resolve subtitle references by getting actual timecodes
      matching_references.each do |reference|
        if (index = have.references[reference][:subtitle])
          have.references[reference][:timecode] = have.subtitles[index][:start]
        end
      end

      case matching_references.length
      when 3..(_infinity = 1.0 / 0)
        # "synchronization jitter" correction by interpolating ? Consider !
      when  2
        retime_by_double_reference(have,
                                   want,
                                   matching_references[0],
                                   matching_references[1])
      when 1
        if have.fps && want.fps
          retime_by_framerate_plus_reference(have, want, matching_references[0])
        else
          retime_by_single_reference(have, want, matching_references[0])
        end
      when 0
        retime_by_framerate(have, want) if have.fps && want.fps
      end
    end
Transfers the subtitles from the state we {Have}, to the state we {Want}.

 @params have [Have] What we {Have}
 @params want [Want] What we {Want}