Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] Re: SAA7146 Cropping



Michael Hunold <hunold@convergence.de> wrote:
 
Hi Michael,

Hello Jeremy,

On 07/07/04 17:41, Jeremy Jones wrote:
> I am trying to develop a DVB application which has a PIG (Picture In
> Graphic) feature common to most DVB-S IRDs. To achieve this I need to
> shrink the video down to 1/4th of the screen and place it in the upper
> right hand corner. After digging though some documentation it seems
> that this should be possible using v4l2 API (in fact there is example to
> do exactly what I'm trying to do
> http://v4l2spec.bytesex.org/spec-single/v4l2.html#CROP). When I try to
> run this example I get an EINVAL error on the VIDIOC_CROPCAP ioctl(). I
> have a Nexus-S card which has an SAA7146 MPEG decoder so I looked at the
> saa7146_video.c file and noticed that it doesn't handle this ioctl()
> which seems to be the cause of the EINVAL error.

This is correct, the driver does not support the ioctl.

> I looked at the SAA7146
> documentation and it seems like it should be possible to scale the video
> output down to 1/4th the screen.

Yes, it's possible, but you're on the wrong track.

> Is there any other way
> to accomplish what I'm trying to do ? Am I even using the correct APIs
> to do what I'm trying to accomplish ?

I don't think so.

Do you want to compose a "screen" from multiple elements, like live
video, static graphics and text?

This is exactly what I want to do!  The Nexus-s card has an OSD which can be used to draw graphics which overlay the video stream.  Examples of this can be seen in the vdr plugin picture galerie (http://vdrportal.de/board/gallery/categories.php?cat_id=1).  What I want to do is some how shrink the video to only take up 1/4th of the screen and use the OSD to draw garphics on the rest of the screen (no visual overlap of OSD and video).

(Yahoo mail formatting is kind of strange)


> The data from the Video4Linux device is just one of the elements that
> needs to be composed, it's not the underlying screen. So there is no
> need to crop the video data, it just needs to be scaled and positionend
> onto your "screen", ie. you need to specify the correct capture size,
> then capture the data and overlay or copy the data onto your destination
> screen.

I'm not sure exactly how but the Nexus-s already does compose a screen of video and OSD graphics and outputs through composite video on the card.  Using a program like tvtime (which I believe attaches to /dev/video0) I can see the same output on my computer monitor as whats on my TV (it even shows the OSD graphics).  Since all of this is done on the card I figured the mpeg scaling must somehow be done by the card (if possible).


> Thank You,
> bball

CU
Michael.


Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
Home | Main Index | Thread Index