Lines Matching full:sel

199 			       struct v4l2_subdev_selection *sel)  in histo_get_selection()  argument
207 if (sel->pad != HISTO_PAD_SINK) in histo_get_selection()
213 sel->which); in histo_get_selection()
219 switch (sel->target) { in histo_get_selection()
225 sel->r.left = 0; in histo_get_selection()
226 sel->r.top = 0; in histo_get_selection()
227 sel->r.width = crop->width; in histo_get_selection()
228 sel->r.height = crop->height; in histo_get_selection()
235 sel->r.left = 0; in histo_get_selection()
236 sel->r.top = 0; in histo_get_selection()
237 sel->r.width = format->width; in histo_get_selection()
238 sel->r.height = format->height; in histo_get_selection()
243 sel->r = *vsp1_entity_get_pad_selection(&histo->entity, config, in histo_get_selection()
244 sel->pad, sel->target); in histo_get_selection()
259 struct v4l2_subdev_selection *sel) in histo_set_crop() argument
268 sel->r.left = clamp_t(unsigned int, sel->r.left, 0, format->width - 1); in histo_set_crop()
269 sel->r.top = clamp_t(unsigned int, sel->r.top, 0, format->height - 1); in histo_set_crop()
270 sel->r.width = clamp_t(unsigned int, sel->r.width, HISTO_MIN_SIZE, in histo_set_crop()
271 format->width - sel->r.left); in histo_set_crop()
272 sel->r.height = clamp_t(unsigned int, sel->r.height, HISTO_MIN_SIZE, in histo_set_crop()
273 format->height - sel->r.top); in histo_set_crop()
277 sel->pad, V4L2_SEL_TGT_CROP); in histo_set_crop()
278 *selection = sel->r; in histo_set_crop()
281 sel->pad, in histo_set_crop()
283 *selection = sel->r; in histo_set_crop()
290 struct v4l2_subdev_selection *sel) in histo_set_compose() argument
302 sel->r.left = 0; in histo_set_compose()
303 sel->r.top = 0; in histo_set_compose()
306 sel->pad, in histo_set_compose()
323 sel->r.width = clamp(sel->r.width, crop->width / 4, crop->width); in histo_set_compose()
324 ratio = 1 << (crop->width * 2 / sel->r.width / 3); in histo_set_compose()
325 sel->r.width = crop->width / ratio; in histo_set_compose()
328 sel->r.height = clamp(sel->r.height, crop->height / 4, crop->height); in histo_set_compose()
329 ratio = 1 << (crop->height * 2 / sel->r.height / 3); in histo_set_compose()
330 sel->r.height = crop->height / ratio; in histo_set_compose()
333 sel->pad, in histo_set_compose()
335 *compose = sel->r; in histo_set_compose()
342 struct v4l2_subdev_selection *sel) in histo_set_selection() argument
348 if (sel->pad != HISTO_PAD_SINK) in histo_set_selection()
354 sel->which); in histo_set_selection()
360 if (sel->target == V4L2_SEL_TGT_CROP) in histo_set_selection()
361 ret = histo_set_crop(subdev, config, sel); in histo_set_selection()
362 else if (sel->target == V4L2_SEL_TGT_COMPOSE) in histo_set_selection()
363 ret = histo_set_compose(subdev, config, sel); in histo_set_selection()