/**
   * Constructor with a list of video codecs
   *
   * @param codecs Ordered list of codecs (preferred codec in first)
   */
  public LiveVideoPlayer(MediaCodec[] codecs) {
    // Set the local RTP port
    localRtpPort = NetworkRessourceManager.generateLocalRtpPort();
    reservePort(localRtpPort);

    // Init codecs
    supportedMediaCodecs = codecs;

    // Set the default media codec
    if (supportedMediaCodecs.length > 0) {
      setVideoCodec(supportedMediaCodecs[0]);
    }
  }
  /**
   * Constructor with a list of video codecs and allowing to share RTP stream with video renderer
   *
   * @param codecs Ordered list of codecs (preferred codec in first)
   * @param vr video renderer
   */
  public LiveVideoPlayer(MediaCodec[] codecs, VideoRenderer vr) {
    // Set the local RTP port
    localRtpPort = NetworkRessourceManager.generateLocalRtpPort();
    reservePort(localRtpPort);

    // Get and set locally the audio renderer reference
    videoRenderer = vr;

    // Init codecs
    supportedMediaCodecs = codecs;

    // Set the default media codec
    if (supportedMediaCodecs.length > 0) {
      setVideoCodec(supportedMediaCodecs[0]);
    }
  }