1
2#include "RTSPStreamerPlugin.h"
3
4#include "RTSPMediaIO.h"
5
6
7RTSPStreamer::RTSPStreamer()
8{
9}
10
11
12RTSPStreamer::~RTSPStreamer()
13{
14}
15
16
17status_t
18RTSPStreamer::Sniff(const BUrl& url, BDataIO** source)
19{
20	RTSPMediaIO* outSource = new RTSPMediaIO(url);
21	status_t ret = outSource->Open();
22	if (ret == B_OK) {
23		*source = outSource;
24		return B_OK;
25	}
26	delete outSource;
27	return ret;
28}
29
30
31Streamer*
32RTSPStreamerPlugin::NewStreamer()
33{
34	return new RTSPStreamer();
35}
36
37
38MediaPlugin *instantiate_plugin()
39{
40	return new RTSPStreamerPlugin();
41}
42