mjpeg

Mjpeg VLC and HTTP Streaming

痞子三分冷 提交于 2019-12-03 08:31:19
I'm generating a MJpeg Stream and trying to stream it to VLC and play it there. The code: public void SendMultiPartData(String contentType, Func<byte[]> getData) { MemoryStream mem = null; response.StatusCode = 200; for ( byte[] buffer = getData(); buffer != null && buffer.Length > 0; buffer = getData()) { response.ContentType = "multipart/x-mixed-replace; boundary=--testboundary"; ASCIIEncoding ae = new ASCIIEncoding(); byte[] boundary = ae.GetBytes("\r\n--testboundary\r\nContent-Type: " + contentType + "\r\nContent-Length:" + buffer.Length + "\r\n\r\n"); mem = new MemoryStream(boundary); mem

HttpWebResponse with MJPEG and multipart/x-mixed-replace; boundary=--myboundary response content type from security camera not working

≯℡__Kan透↙ 提交于 2019-12-03 07:10:37
I have an ASP.NET application that I need to show a video feed from a security camera. The video feed has a content type of 'multipart/x-mixed-replace; boundary=--myboundary' with the image data between the boundaries. I need assistance with passing that stream of data through to my page so that the client side plugin I have can consume the stream just as it would if I browsed to the camera's web interface directly. The following code does not work: //Get response data byte[] data = HtmlParser.GetByteArrayFromStream(response.GetResponseStream()); if (data != null) { HttpContext.Current

C++/OpenCV Streaming Camera-Video/Images (MJPEG) from Socket into Browser (Windows 8.1)

六眼飞鱼酱① 提交于 2019-12-03 06:25:42
问题 Still pretty new to openCV/C++ so please bear with me :) I am currently trying to find a good (and possibly easy) way to stream my camera frames in realtime (or almost realtime) from my OpenCV application so that I can open my browser, type in the IP and see the image. So far I got the server done using winsock2 (if anyone has a good cross-platform alternative and can tell me what's different, I'd be quite glad) and can connect to it via entering the IP in my browser. Socket-/Server-Code: /

Read stream from specific link

和自甴很熟 提交于 2019-12-03 04:04:55
I need to read stream from mjpeg with OpenCV library. In more details, I need to read http://194.126.108.66:8887/ . But when I try to do it with VideoCapture ipCam; ipCam.open("http://194.126.108.66:8887/") I get the error icvOpenAvi_XINE(): Unable to initialize video driver . I have tested this code with another link to mjpeg - http://c-cam.uchicago.edu/mjpg/video.mjpg It works fine. What is the difference between these 2 links? And how to read http://194.126.108.66:8887/ ? OpenCV expects a filename extension for its VideoCapture argument, even though one isn't always necessary (like in your

Solutions to stream from a decklink card to browsers (Gstreamer -> TCP MJPEG -> ?)

牧云@^-^@ 提交于 2019-12-03 03:41:00
I need to live stream from a decklink card to a browser. I also must be able to do it with a very poor network link (128kbits/s...), so I need to be able to stream at a very low fps (1 fps is fine) and a very low image quality. At the moment I'm using GStreamer to get the video from the card, to transcode it to MJPEG, and to stream it with TCP. This part is perfectly working, but now I need to tube this tcp stream to an HTTP stream. I can do this with VLC and it works well at a "normal" framerate (15 fps -> 0.5 sec of latency). But if I feed VLC with a 1 fps stream, it introduces a latency of

C++/OpenCV Streaming Camera-Video/Images (MJPEG) from Socket into Browser (Windows 8.1)

◇◆丶佛笑我妖孽 提交于 2019-12-02 19:49:21
Still pretty new to openCV/C++ so please bear with me :) I am currently trying to find a good (and possibly easy) way to stream my camera frames in realtime (or almost realtime) from my OpenCV application so that I can open my browser, type in the IP and see the image. So far I got the server done using winsock2 (if anyone has a good cross-platform alternative and can tell me what's different, I'd be quite glad) and can connect to it via entering the IP in my browser. Socket-/Server-Code: //socket long rc; SOCKET acceptSocket; SOCKADDR_IN addr; WSADATA wsa; // initialize winsock rc=WSAStartup

Android: streaming the camera as mjpeg

对着背影说爱祢 提交于 2019-12-02 18:20:45
After several days of searching SO and google I'm beginning to give up, so I thought I might as well post here. I'm creating an android app which should offer some kind of video chat. As this should be as close as possible to realtime, I read about various protocols and decided to try MJPEG for starters (not concerning with audio for now). Right now streaming the data is driving me nuts. The connection gets established, the app starts writing the camera preview frames to the stream, but neither VLC nor mplayer start playing video. Monitoring the connection reveals that the data is arriving.

.load() does not work on ipad

风流意气都作罢 提交于 2019-12-02 03:48:51
I have simple script to check image, but it is not working properly on my ipad with ios 5.1. In image i receive stream of jpg's, so load must work on each frame (as in big safari), but in ipad it fires only once. May be some suggestions? $('#image').load(function(){ console.log(new Date().getTime();); }); Parv Sharma It is mentioned on the jQuery official website: Caveats of the load event when used with images A common challenge developers attempt to solve using the .load() shortcut is to execute a function when an image (or collection of images) have completely loaded. There are several

How to get errors/warnings in [UIImage initWithData:]

两盒软妹~` 提交于 2019-12-01 23:54:20
问题 i have an MJPEG stream over RTSP/UDP from which i want to generate JPEGs for a UIImageView with [UIImage initWithData:]. Most of the time this works good, but sometimes i get corrupt images and log messages like: ImageIO: <ERROR> JPEGCorrupt JPEG data: premature end of data segment My Question is: how can i see (during runtime), that such message occurs? Unfortunatly 'initWithData' has no error output, is there any other way? Thank you. Edit: in this case, the initWithData does return a valid

How to get errors/warnings in [UIImage initWithData:]

拥有回忆 提交于 2019-12-01 22:43:53
i have an MJPEG stream over RTSP/UDP from which i want to generate JPEGs for a UIImageView with [UIImage initWithData:]. Most of the time this works good, but sometimes i get corrupt images and log messages like: ImageIO: <ERROR> JPEGCorrupt JPEG data: premature end of data segment My Question is: how can i see (during runtime), that such message occurs? Unfortunatly 'initWithData' has no error output, is there any other way? Thank you. Edit: in this case, the initWithData does return a valid UIImage object, not nil! Alex Nichol There is a similar thread to this one on stack overflow: Catching