Re: [PATCH v3 2/4] drm: Add drm_rect_calc_{hscale, vscale}() utility functions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 16, 2013 at 01:47:20PM +0300, ville.syrjala@xxxxxxxxxxxxxxx wrote:
> diff --git a/include/drm/drm_rect.h b/include/drm/drm_rect.h
> index 2b7278c..de24f16 100644
> --- a/include/drm/drm_rect.h
> +++ b/include/drm/drm_rect.h
> @@ -128,5 +128,17 @@ bool drm_rect_intersect(struct drm_rect *r, const struct drm_rect *clip);
>  bool drm_rect_clip_scaled(struct drm_rect *src, struct drm_rect *dst,
>  			  const struct drm_rect *clip,
>  			  int hscale, int vscale);
> +int drm_rect_calc_hscale(const struct drm_rect *src,
> +			 const struct drm_rect *dst,
> +			 int min_hscale, int max_hscale);
> +int drm_rect_calc_vscale(const struct drm_rect *src,
> +			 const struct drm_rect *dst,
> +			 int min_vscale, int max_vscale);
> +int drm_rect_calc_hscale_relaxed(struct drm_rect *src,
> +				 struct drm_rect *dst,
> +				 int min_hscale, int max_hscale);
> +int drm_rect_calc_vscale_relaxed(struct drm_rect *src,
> +				 struct drm_rect *dst,
> +				 int min_vscale, int max_vscale);

These struct drm_rect *src should be const so it is clear that dst is
being manipulated.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux