【发布时间】:2014-08-21 06:04:37
【问题描述】:
我一直在尝试使用托管媒体聚合开源。
我的服务器正在从局域网中的另一台 PC 获取其源代码。
几个问题:
我让我的 RtspClient 连接到我的服务器, 现在我希望能够与客户端一起工作(发送播放、暂停并实际查看视频播放的位置)并且还没有找到任何代码示例。
我希望能够通过我的服务器在我的计算机中流式传输本地视频文件,有没有办法做到这一点?
我试图从我的 PC 上的 VLC 连接到服务器 (localhost) - 没有成功..
这是我的代码:
public ServerExample()
{
//Create the server optionally specifying the port to listen on
server = new RtspServer(554);
source = new RtspSourceStream("RtspSourceTest",
"rtsp://192.168.30.11:5544/stream");
// Add the stream to the server
server.AddStream(source);
// Start the server and underlying streams
server.Start();
//The server is now running, you can access the stream with VLC, QuickTime, etc
AccessWithClient();
}
private void AccessWithClient()
{
RtspClient client = new RtspClient("rtsp://localhost:554/RtspSourceTest", RtspClient.ClientProtocolType.Tcp);
client.Connect();
}
有什么想法吗? 谢谢!
【问题讨论】: