Hi mate,
Impossible is what I hate most
So there a bit ugly solution but works actually, which goes:
stream the media file stream by TCP and receiving it after this by your embedded player
void HTTPStreamer(object obj)
{
Thread.Sleep(1000);
Stream Reciever = (Stream)obj;
TcpListener listener = new TcpListener(IPAddress.Loopback, 12);
listener.Start();
TcpClient client = listener.AcceptTcpClient();
client.Client.Send(Encoding.Default.GetBytes("HTTP/1.1 200 OK\nDate: Tue, 02 Aug 2011 22:24:05 GMT\nServer: Apache/2.2.8 (Win32) PHP/5.2.5\nLast-Modified: Tue, 02 Aug 2011 22:21:13 GMT\nETag: \"1000000009896-1743f-4a98d2a63ee22\"\nAccept-Ranges: bytes\nContent-Length: 95295\nKeep-Alive: timeout=5, max=100\nConnection: Keep-Alive\nContent-Type: text/plain"));
int length = 0;
byte[] buffer = new byte[1024];
while (Reciever.CanRead)
{
try
{
length = Reciever.Read(buffer, 0, 1024);
client.GetStream().Write(buffer, 0, length);
}
catch
{
break;
}
}
}
MemoryStream YourStream
Thread th = new Thread(HTTPListener);
th.start(YourStream);
<pre>
My first solution in this lovely site, sorry for the mistakes
Cheers