Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vdpau screen capture on H3 #61

Open
radojko opened this issue Apr 23, 2018 · 5 comments
Open

Vdpau screen capture on H3 #61

radojko opened this issue Apr 23, 2018 · 5 comments

Comments

@radojko
Copy link

radojko commented Apr 23, 2018

How to capture vdpau output on H3?

I'm trying to capture mpv and mplayer with vdpau but I got black window on the player place when using any capturing app like: screenshot, shutter, fb2png, fbgrab

@rellla
Copy link
Member

rellla commented Apr 24, 2018

Hi,
capture funtionality is not implemented in libvdpau-sunxi, because that will most likely need https://github.com/linux-sunxi/libvdpau-sunxi/blob/master/surface_output.c#L92
rellla

@mittorn
Copy link

mittorn commented Apr 24, 2018

cedarx seems to output video directly to sunxi-disp layers using color keys to draw elements on video. I do not know if it's possible to grab data back from this layer

@radojko
Copy link
Author

radojko commented Apr 25, 2018

Thanks for answers!
The same situation is to grab omxplayer video on RPi, but there is an app to capture all screen including video. I know this is not trivial ( I don't understand rella's answer 😄 ) because video is output to HDMI from GPU not on X11.
BTW. I'm very satisfied with video performance and stability on H3, especially HEVC decoding, and this screen capture is only missing piece to use H3 on my project :(

@rellla
Copy link
Member

rellla commented Apr 25, 2018

The problem is, that video and osd/gui are not rendered into 1 common layer, so you can't just dump the output surface into a file. This is sunxi specific, because the display engine uses 2 separate layers to bring everything to screen.
Therefore you have to grab the video surface and the osd surface separately, mix them together and dump it into a file.
That should easily be possible to code, but it has to be done at all.
This rellla@d3f1bdb was an ugly trial to do this, but iirc it never worked (correct)...
If you want and have the skills, you can look into it to get the principle...
rellla

@radojko
Copy link
Author

radojko commented Apr 26, 2018

Just looked, but in this moment I would rather pay 🍺 to somebody who can help to community :)
I no need osd, only video layer composed with x11 desktop.
@rellla

What GRAB define in:
define GRAB Uncomment this to try experimental get_bits_native support
does in the case of enabling we will get and this two layers in framebuffer and then just capture screen with for example fbgrab?

For somebody who is interested in this, this is how is that done on RPi:
https://github.com/KanoComputing/kano-screenshot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants