[Bug 759533] vaapisink: doesn't upload packed formats correctly

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Tue Mar 28 14:43:50 UTC 2017


https://bugzilla.gnome.org/show_bug.cgi?id=759533

Víctor Manuel Jáquez Leal <vjaquez at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #348776|none                        |needs-work
             status|                            |

--- Comment #24 from Víctor Manuel Jáquez Leal <vjaquez at igalia.com> ---
Review of attachment 348776:
 --> (https://bugzilla.gnome.org/review?bug=759533&attachment=348776)

::: gst-libs/gst/vaapi/gstvaapiwindow.c
@@ +120,3 @@
+  GstVaapiSurface *vpp_surface = NULL;
+  GstVaapiFilterStatus status;
+

should we check first for 

if (!window->has_vapp)
  return NULL;

???

@@ +123,3 @@
+  /* Ensure VA surface pool is created */
+  /* XXX: optimize the surface format to use. e.g. YUY2 */
+  if (!window->surface_pool) {

I would create a boolean function ensure_filter_surface_pool()

@@ +132,3 @@
+
+  /* Ensure VPP pipeline is built */
+  if (!window->filter) {

Again, I'd create a boolean function ensure_filter().

It might call ensure_filter_surface_pool() or roll it in.

@@ +141,3 @@
+
+  if (src_rect
+      && !gst_vaapi_filter_set_cropping_rectangle (window->filter, src_rect))

IMO, this is hard to read. I'd change it to

if (src_rect) {
   blah
}

@@ +144,3 @@
+    return NULL;
+  if (dst_rect
+      && !gst_vaapi_filter_set_target_rectangle (window->filter, dst_rect))

ditto

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list