[Mesa-dev] [PATCH] st/vdpau: drop unnecessary variable prof

Christian König deathsimple at vodafone.de
Sat Aug 17 02:18:33 PDT 2013


Am 16.08.2013 22:41, schrieb Emil Velikov:
> Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>

Well, any halve way sane compiler should be able to optimize that 
anyway, but on the other hand the patch looks good to me.

Reviewed-by: Christian König <christian.koenig at amd.com>

> ---
>   src/gallium/state_trackers/vdpau/mixer.c | 5 ++---
>   1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/src/gallium/state_trackers/vdpau/mixer.c b/src/gallium/state_trackers/vdpau/mixer.c
> index 26db5c8..8c20d05 100644
> --- a/src/gallium/state_trackers/vdpau/mixer.c
> +++ b/src/gallium/state_trackers/vdpau/mixer.c
> @@ -50,7 +50,6 @@ vlVdpVideoMixerCreate(VdpDevice device,
>      VdpStatus ret;
>      struct pipe_screen *screen;
>      unsigned max_width, max_height, i;
> -   enum pipe_video_profile prof = PIPE_VIDEO_PROFILE_UNKNOWN;
>   
>      vlVdpDevice *dev = vlGetDataHTAB(device);
>      if (!dev)
> @@ -132,8 +131,8 @@ vlVdpVideoMixerCreate(VdpDevice device,
>         VDPAU_MSG(VDPAU_WARN, "[VDPAU] Max layers > 4 not supported\n", vmixer->max_layers);
>         goto no_params;
>      }
> -   max_width = screen->get_video_param(screen, prof, PIPE_VIDEO_CAP_MAX_WIDTH);
> -   max_height = screen->get_video_param(screen, prof, PIPE_VIDEO_CAP_MAX_HEIGHT);
> +   max_width = screen->get_video_param(screen, PIPE_VIDEO_PROFILE_UNKNOWN, PIPE_VIDEO_CAP_MAX_WIDTH);
> +   max_height = screen->get_video_param(screen, PIPE_VIDEO_PROFILE_UNKNOWN, PIPE_VIDEO_CAP_MAX_HEIGHT);
>      if (vmixer->video_width < 48 ||
>          vmixer->video_width > max_width) {
>         VDPAU_MSG(VDPAU_WARN, "[VDPAU] 48 < %u < %u not valid for width\n", vmixer->video_width, max_width);



More information about the mesa-dev mailing list