Plane address mismatch of vaapi video buffer

Sreerenj Balachandran bsreerenj at gmail.com
Mon Feb 22 13:52:41 UTC 2016


You have to consider the GstVideoCropMeta attached to the buffer.
See this:
https://github.com/sreerenjb/gst-checksumsink/blob/master/gstchecksumsink.c#L338

On Mon, Feb 22, 2016 at 3:12 PM, Thornton, Keith <keith.thornton at zeiss.com>
wrote:

> This is probably an alignment problem. Your stepsize is probably 1088 long
> because it must be divisible by 16.
>
> -----Ursprüngliche Nachricht-----
> Von: gstreamer-devel [mailto:gstreamer-devel-bounces at lists.freedesktop.org]
> Im Auftrag von Thomas Scheuermann
> Gesendet: Montag, 22. Februar 2016 13:42
> An: gstreamer-devel at lists.freedesktop.org
> Betreff: Plane address mismatch of vaapi video buffer
>
> Hi all,
>
> I use a pipeline which which uses vaapidecode and vaapipostproc for a
> video and the frames are delivered to appsink. I keep the NV12 format.
> Outside the pipeline I get the sample from where I want to access the
> video frame. I use the following code to get access:
>
> buffer = gst_sample_get_buffer(_sample); caps =
> gst_sample_get_caps(_sample); gst_video_frame_map(&frame, &vinfo, buffer,
> GST_MAP_READ)
>
> Now I should be able to access the video planes via frame.data[0] for the
> Y plane and frame.data[1] for the UV plane.
>
> This works for a video with e.g. 1280x720. But if I use a video of
> 1920x1080 the Y plane is still correct but the UV plane is shifted for
> some lines and starts later as in data[1].
>
> The strides should be in
> vinfo.stride[0]
> vinfo.stride[1]
>
> but they also dont match.
>
> How can I get the correct addresses of the planes?
> Do I have to set something special if I use a VAAPI generetad buffer?
> How do I get the correct stride of the planes?
>
> I use GStreamer 1.4.5 at the moment.
>
> Regards,
>
> Thomas
> This message is subject to the following terms and conditions: MAIL
> DISCLAIMER<http://www.barco.com/en/maildisclaimer>
> _______________________________________________
> 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
>



-- 
Regards,

Sreerenj Balachandran
Intel Open Source Technology Center
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160222/2a8d2a40/attachment.html>


More information about the gstreamer-devel mailing list