使用FFplay播放RTMP链接

使用FFplay播放RTMP链接

我已经设法使用 ffplay 播放了几个 rtmp 流,但不幸的是不是这个,我正尝试播放来自http://www1.iransima.ir/

第一次尝试

我尝试过提供网页源代码中的 URL

jwplayer("container").setup({
  file : "rtmp://cdn.iransima.ir/e-tv3?wmsAuthSign=c2VydmVyX3RpbWU9OC81LzIwMTUgNjo0OTo1MSBQTSZoYXNoX3ZhbHVlPWJVK3N1MFlTR1FobjJ0bGdJNGRZYVE9PSZ2YWxpZG1pbnV0ZXM9MTA=/tv3-300k.stream",
  width : "100%",
  aspectratio : "16:9",
  Autostart : "true",
  rtmp : {
    securetoken : "4cb3b8d53539e241"
  },
  skin : "/templates/total/player/skins/me.xml",
  abouttext : "Iran Sima",
  aboutlink : "http://www.iransima.ir/",
  logo : {
    file : "/templates/total/images/slogo.png",
    link : "http://www.iransima.ir",
    position : "top-right",
    margin : "12",
    hide : false,
    linktarget : "_blank"
  }
});
jwplayer().onReady(function(dataAndEvents) {
  ga("send", "event", "LiveS Iran 300", "tv3");
});
jwplayer().onError(function(dataAndEvents, pageTitle) {
  ga("send", "event", "LiveS Iran tv3 Error", pageTitle);
});
/**
 * @param {string} action
 * @return {undefined}
 */
function playme(action) {
  ga("send", "event", "LiveS Iran 300", action);
  var name = document.getElementById("seccode").value;
  if (action == "tv3") {
    /** @type {string} */
    var e_tv3 = "e-tv3"
  } else {
    if (action == "varzesh") {
      /** @type {string} */
      e_tv3 = "e-varzesh";
    } else {
      if (action == "ostani") {
        /** @type {string} */
        e_tv3 = "e-ostani";
      } else {
        /** @type {string} */
        e_tv3 = "e-tv";
      }
    }
  }
  $.post("engine/ajax/hcode.php?scode=" + name, function(m3) {
    jwplayer("container").setup({
      file : "rtmp://cdn.iransima.ir/" + e_tv3 + "?wmsAuthSign=" + m3 + "/" + action + "-300k" + ".stream",
      width : "100%",
      aspectratio : "16:9",
      Autostart : "true",
      rtmp : {
        securetoken : "4cb3b8d53539e241"
      },
      skin : "/templates/total/player/skins/me.xml",
      abouttext : "Iran Sima",
      aboutlink : "http://www.iransima.ir/",
      logo : {
        file : "/templates/total/images/slogo.png",
        link : "http://www.iransima.ir",
        position : "top-right",
        margin : "12",
        hide : false,
        linktarget : "_blank"
      }
    });
  });
  jwplayer().onError(function(dataAndEvents, pageTitle) {
    ga("send", "event", "LiveS Iran " + action + " Error", pageTitle);
  });
}
;

以下是我尝试过的 ffplay 命令

ffplay rtmp://cdn.iransima.ir/e-tv3?wmsAuthSign=c2VydmVyX3RpbWU9O
C81LzIwMTUgNjo0OTo1MSBQTSZoYXNoX3ZhbHVlPWJVK3N1MFlTR1FobjJ0bGdJNGRZYVE9PSZ2YWxpZ
G1pbnV0ZXM9MTA=/tv3-300k.stream

F:\Apps\ffmpeg>ffplay rtmp://cdn.iransima.ir/e-tv3?wmsAuthSign=c2VydmVyX3RpbWU9O
C81LzIwMTUgNjo0OTo1MSBQTSZoYXNoX3ZhbHVlPWJVK3N1MFlTR1FobjJ0bGdJNGRZYVE9PSZ2YWxpZ
G1pbnV0ZXM9MTA= -rtmp_playpath tv3-300k.stream

我也尝试过命令,-rtmp_app-rtmp_swfurl没有成功

第二次尝试

我使用了 URL Snooper 和 Wireshark,并成功获得了響鳴url,但我还是没能用 ffplay 成功播放它

ffplay rtmpe://91.225.53.36/e-tv3?wmsAuthSign=c2VydmVyX3RpbWU9OC8
1LzIwMTUgNTo1NTo1OSBQTSZoYXNoX3ZhbHVlPS82bkw2NHl0clQrSkZ6LzBSZUJydkE9PSZ2YWxpZG1
pbnV0ZXM9MTA= -rtmp_playpath tv3-300k.stream

我肯定在这里遗漏了一些东西,如果有人能给我指明正确的方向,我将不胜感激。

相关内容