Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2023-07

MJPEG streamer

8 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Steve Gatenby

Would anybody know if there is a component / code to enable reading an mjpeg stream from a http camera to a Lazarus form/panel (or anything really)

Dont mind installing libraries etc -

Looking to suit Linux specifically though

Thanks - SteveG

Reply by email

Ondrej Pokorny
to Steve Gatenby
Steve Gatenby wrote 7 lines
Would anybody know if there is a component / code to enable reading an mjpeg stream from a http camera to a Lazarus form/panel (or anything really) Dont mind installing libraries etc - Looking to suit Linux specifically though

I would try the VLC player component:
https://wiki.freepascal.org/Video_Playback_Libraries http://lazplanet.blogspot.com/2018/01/how-to-make-simple-video-player-in.html

VLC can open a video stream from a RTSP camera.

Ondrej

Reply by email

Michael Van Canneyt
to Steve Gatenby: Would anybody know if there is a component / code to enable reading an mjpeg stream from…
Steve Gatenby wrote 6 lines
Would anybody know if there is a component / code to enable reading an mjpeg stream from a http camera to a Lazarus form/panel (or anything really) Dont mind installing libraries etc - Looking to suit Linux specifically though

vlc can play media streams, so I think Libvlc can be used for this. The lazvlc.lpk contains a component that encapsulates vlc, it's just a matter of feeding it the correct url.

Michael.

Reply by email

Bo Berglund
to Steve Gatenby: Would anybody know if there is a component / code to enable reading an mjpeg stream from…
Steve Gatenby wrote 8 lines
Would anybody know if there is a component / code to enable reading an mjpeg stream from a http camera to a Lazarus form/panel (or anything really) Dont mind installing libraries etc - Looking to suit Linux specifically though Thanks - SteveG

I have been using PasLibVlc from here:
https://prog.olsztyn.pl/paslibvlc/

in order to read/display/navigate mp4 video files in an editing application I wrote a number of years ago.
It works very well on both Windows and Linux (Ubuntu and RaspberryPiOS). The only requirement I am aware of is that VLC must be installed on the development (and host) machines.

It is a bit old now (last update from 2020-07-05), but works just fine for me.

Bo Berglund Developer in Sweden

Reply by email

Steve Gatenby
to Steve Gatenby: Would anybody know if there is a component / code to enable reading an mjpeg stream from…
Steve Gatenby wrote 10 lines
Would anybody know if there is a component / code to enable reading an mjpeg stream from a http camera to a Lazarus form/panel (or anything really) Dont mind installing libraries etc - Looking to suit Linux specifically though Thanks - SteveG

Thank you all -

exactly what I was hoping for - possibilities to follow :)

I will post if / once I get it figured as may be useful to others

Reply by email

Steve Gatenby
to Steve Gatenby
Steve Gatenby wrote 20 lines
On 23/7/23 18:35, Steve Gatenby via lazarus wrote: > Would anybody know if there is a component / code to enable reading > an mjpeg stream from a http camera to a Lazarus form/panel (or > anything really) > > Dont mind installing libraries etc - > > Looking to suit Linux specifically though > > Thanks - SteveG > Thank you all - exactly what I was hoping for - possibilities to follow :) I will post if / once I get it figured as may be useful to others

I have written a (very) small unit to capture stream from esp32-cam (currently) and display in standard Lazarus TImage. First draft allows multiple cams / images.

What is the accepted way of supplying for use by others ? - do we have a central place for snippets / units for Pascal / Lazarus.

I know about CCR etc, but this is a bit small for that :) - so not sure what to do with it.

Have considered github, but seems overkill for such a small offering (and no guarantees it would always exist)

Regard - SteveG

Reply by email

Ondrej Pokorny
to Steve Gatenby
Steve Gatenby wrote 34 lines
On 24/7/23 09:35, Steve Gatenby via lazarus wrote: > > On 23/7/23 18:35, Steve Gatenby via lazarus wrote: >> Would anybody know if there is a component / code to enable reading >> an mjpeg stream from a http camera to a Lazarus form/panel (or >> anything really) >> >> Dont mind installing libraries etc - >> >> Looking to suit Linux specifically though >> >> Thanks - SteveG >> > > Thank you all - > > exactly what I was hoping for - possibilities to follow :) > > I will post if / once I get it figured as may be useful to others > > I have written a (very) small unit to capture stream from esp32-cam (currently) and display in standard Lazarus TImage. First draft allows multiple cams / images. What is the accepted way of supplying for use by others ? - do we have a central place for snippets / units for Pascal / Lazarus. I know about CCR etc, but this is a bit small for that :) - so not sure what to do with it. Have considered github, but seems overkill for such a small offering (and no guarantees it would always exist)

I am interested in your solution.

If the unit uses the Lazarus-included lazvlc.lpk (or any other solution included in FPC/Lazarus), I would store it in the examples folder within Lazarus main:
https://gitlab.com/freepascal.org/lazarus/lazarus/-/tree/main/examples

Please either create an issue in Lazarus gitlab and send the code there or send me the example as zipped file and I will upload it to examples.

Thanks,
Ondrej

Reply by email