Extremely simple live player (Was: How to scale to maximum video sink width and height)

Pander pander at users.sourceforge.net
Thu Oct 20 13:52:00 UTC 2016


On 10/16/2016 11:34 PM, Pander wrote:
> On 10/16/2016 07:06 PM, Pander wrote:
>> Hi all,
>>
>> As follow up on
>> https://lists.freedesktop.org/archives/gstreamer-devel/2016-October/060868.html
>> a new post. I have also looked at livav-tools and mplayer but these have
>> much less support for USB cameras formats.
>>
>> So gst-launch is only for testing, hence I am looking for an extremely
>> simple live player based on gst and written in C. When I look at the
>> tutorial, I see that parsing the pipeline is also used there:
>>
>> http://docs.gstreamer.com/pages/viewpage.action?pageId=327735
>>
>> Does that mean that this is also not the fastest way? Note that I want
>> to deploy the solution on Raspberry Pis without X, so it must as fast as
>> possible. Do I simply put in line number 12 the pipeline I need? Or do I
>> omit the parsing and connect with lower lever functions the source to
>> the sink?
>>
>> All I need is
>>   gst-launch-1.0 -q v4l2src ! autovideosink
>> or
>>   gst-launch-1.0 -q v4l2src device=/dev/video1 ! autovideosink
>>
>> (The full-screen part I postpone. As I run it from the command-line
>> without X, I do not have a widget to embed to sink in.)

Implemented the arguments and scaling. This has all been a good learning
experience getting to understand GST and develop with it.

Still need help on getting width and height from the sink. Please see
https://github.com/z25/gstcam/blob/master/src/gstcam.c#L135

Also, I am looking for a sponsor/reviewer to get this application ridden
from all warnings from ./check.sh in order to suitable to become part of
an existing DEB for Debian (and Rasbian) and Ubuntu.

It might be a suitable to refer to as a simple example from the
tutorial's point of view. The application too has its raison d'ĂȘtre as a
simple local camera video player without network for anyone who needs it.

> 
> After diving into the correct tutorial (1.0 on org, not 0.10 on .com) I
> have put together an application that does the bare minimum. All my
> questions are not in the //TODO in the source code. They mainly concern
> handling command-line arguments and getting the width and height from
> the sink (callback or caps?).
> 
> Please review https://github.com/z25/gstcam
> 
> Thanks,
> 
> Pander
> 
>>
>> Thanks,
>>
>> Pander
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>>
> 
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
> 



More information about the gstreamer-devel mailing list