【问题标题】:WebRTC PeerConnection client nodejsWebRTC PeerConnection 客户端 nodejs
【发布时间】:2014-09-06 20:02:13
【问题描述】:

我正在尝试让 ubuntu 上的 WebRTC PeerConnection 客户端与 nodejs 一起工作。

首先我尝试了wrtc (https://github.com/js-platform/node-webrtc)。我设法运行客户端,但似乎无法获取数据流。我注意到这个模块上的 RTCPeerConnection/PeerConnection 具有与我在 chrome 中运行时不同的功能/实现。所以我去找另一个nodejs PeerConnection。

我试过了: https://github.com/Rantanen/node-peerconnection

已经编译的版本抛出错误:_ZN6webrtc17BitrateController23CreateBitrateControllerEv

我认为要让它正常工作,我必须在我的机器上编译 peerconnection。

我已经关注http://www.webrtc.org/reference/getting-started,并在目录下编译webrtc:/home/myuser/.webrtc/。 我有/home/myuser/.webrtc/trunk/out/(Debug/Release)。 我有peerconnection_client 可执行文件。

接下来我克隆了:https://github.com/santiago/node-peerconnection(另一个实现,带有一个 make 文件)。 当我尝试运行 makefile (make WEBRTC_ROOT_PATH=/home/myuser/.webrtc/trunk) 我得到了错误:

src/node_peer_connection_client.h:9:18: fatal error: node.h: No such file or directory
 include <node.h>

我有/usr/include/nodejs(和/usr/include/node 符号链接)。我注意到里面有一个 src 目录 (/usr/include/node/src/node.h)。

我尝试过的其他事情:

https://github.com/js-platform/node-webrtc

https://github.com/Raynos/peer-connection

基本上,我正在尝试让已在我的机器上编译的 PeerConnection 客户端与 nodejs 一起使用。

任何帮助将不胜感激;) 谢谢

【问题讨论】:

标签: node.js ubuntu webrtc


【解决方案1】:

这看起来很有希望:https://github.com/vmolsa/webrtc-native

用法示例: https://github.com/vmolsa/webrtc-native/blob/master/examples/node2browser/index.js:

API:

WebRTC.RTCPeerConnection

WebRTC.RTCIceCandidate

WebRTC.RTCSessionDescription

WebRTC.RTCDataChannel

WebRTC.MediaStream

WebRTC.MediaStreamTrack

WebRTC.getUserMedia

WebRTC.getSources

【讨论】:

  • 谢谢,我会调查的;)
【解决方案2】:

node-webrtc 暂时假设是不错的选择,项目还活着。如果您有任何问题,请在此处发布问题。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-05-07
    • 2015-05-20
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-02-28
    • 1970-01-01
    相关资源
    最近更新 更多