Repository: opencv
Issue: Add ability to serve video stream
Labels: auto-transferred,priority: normal,feature,category: videoio

Transferred from http://code.opencv.org/issues/3475

```
|| Cody Rigney on 2014-01-06 21:56
|| Priority: Normal
|| Affected: None
|| Category: highgui-video
|| Tracker: Feature
|| Difficulty: Hard
|| PR: 
|| Platform: None / None
```
## Add ability to serve video stream

```
Could the capability be added to easily broadcast a motion jpeg to clients using VideoWriter?  Does it make sense to add this to video writer, or it's own class?  If added to VideoWriter, additional parameters could be passed for binding IP address and port number.

This feature would make debugging on embedded devices, for example, much easier.

It seems to make sense for Issue #1324 to be completed before this one.  I can complete these, but I need to find a couple answers to some questions first.
```
## History
##### Cody Rigney on 2014-01-06 21:58

```
Is there a class used for networking (across platforms) in the opencv source?  Or at least an example?  I will dig through and look if I don't get an answer.  Thanks.
```
##### Andrew Senin on 2014-01-23 14:13

```
Here is a link I found:
http://www.rosoo.net/a/201004/9123.html

Haven't tried, though.
-   Difficulty set to Hard
-   Target version changed from 3.0 to Next Hackathon
-   Assignee deleted (Cody Rigney)
-   Status changed from New to Open
```
##### Cody Rigney on 2014-01-24 02:01

```
Thanks.

I have this implemented for windows and unix-like systems. It's single threaded but can serve multiple clients.  It only does mjpeg right now which means you can view it from a browser. (Great for embedded device debugging).  All you do is open a videowriter but specify a port and the fourcc for mjpeg only.  Then write frames as usual.  I still have to test the unix part and builds then I will submit a pull request.
```
##### Andrew Senin on 2014-01-24 10:02

```
Thanks Cody! That would be great!
-   Target version changed from Next Hackathon to 3.0-alpha
-   Assignee set to Cody Rigney
```
##### be rak on 2014-05-30 09:49

```
any updates on this ? a lot of people have been asking
```
##### Cody Rigney on 2014-08-04 14:24

```
Sorry for the long delay.  I had the code done a while back but bought a new computer and forgot about that enhancement I had been working on, on the previous computer.  I will try to get this committed within the next couple of weeks.  If not, I'll post what I have so far for another person to finish.
```
##### Cody Rigney on 2014-08-04 14:28

```
Another point to this, I have noticed that the popular browsers are bugged on what I implemented (multi-part jpeg).  Firefox has a massive memory leak but works, while Chrome and IE require it to be embedded in HTML to work.  Either way, I'll try to finish it up.
```
##### Aly Osama on 2014-12-17 19:44

```
Hi, i want to ask what is the progress in this feature so that i could complete it
thanks
```
##### Cody Rigney on 2015-03-02 15:02

```
Aly Osama wrote:
> Hi, i want to ask what is the progress in this feature so that i could complete it
> thanks

Hi, I'll submit the patch.  I thought I would have the chance to complete it, but I have been very busy.  Please give me till the end of the week.  Thanks.
```
##### Maksim Shabunin on 2015-04-27 09:11

```
-   Target version changed from 3.0-alpha to 3.0
```