[Mesa-dev] [PATCH 3/3] st/va: move vlVaBuffer declaration further up

Emil Velikov emil.l.velikov at gmail.com
Fri Dec 2 16:26:51 UTC 2016


From: Emil Velikov <emil.velikov at collabora.com>

This allows us to remove the struct vlVaBuffer reference, which lead the
compiler to emit a "assignment from incompatible pointer type" warnings.

Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
 src/gallium/state_trackers/va/va_private.h | 30 +++++++++++++++---------------
 1 file changed, 15 insertions(+), 15 deletions(-)

diff --git a/src/gallium/state_trackers/va/va_private.h b/src/gallium/state_trackers/va/va_private.h
index c9a6a41..054cfb3 100644
--- a/src/gallium/state_trackers/va/va_private.h
+++ b/src/gallium/state_trackers/va/va_private.h
@@ -220,6 +220,20 @@ typedef struct {
 } vlVaSubpicture;
 
 typedef struct {
+   VABufferType type;
+   unsigned int size;
+   unsigned int num_elements;
+   void *data;
+   struct {
+      struct pipe_resource *resource;
+      struct pipe_transfer *transfer;
+   } derived_surface;
+   unsigned int export_refcount;
+   VABufferInfo export_state;
+   unsigned int coded_size;
+} vlVaBuffer;
+
+typedef struct {
    struct pipe_video_codec templat, *decoder;
    struct pipe_video_buffer *target;
    union {
@@ -242,7 +256,7 @@ typedef struct {
    } mpeg4;
 
    struct vl_deint_filter *deint;
-   struct vlVaBuffer *coded_buf;
+   vlVaBuffer *coded_buf;
    int target_id;
 } vlVaContext;
 
@@ -254,20 +268,6 @@ typedef struct {
 } vlVaConfig;
 
 typedef struct {
-   VABufferType type;
-   unsigned int size;
-   unsigned int num_elements;
-   void *data;
-   struct {
-      struct pipe_resource *resource;
-      struct pipe_transfer *transfer;
-   } derived_surface;
-   unsigned int export_refcount;
-   VABufferInfo export_state;
-   unsigned int coded_size;
-} vlVaBuffer;
-
-typedef struct {
    struct pipe_video_buffer templat, *buffer;
    struct util_dynarray subpics; /* vlVaSubpicture */
    VAContextID ctx;
-- 
2.10.2



More information about the mesa-dev mailing list