Lines Matching refs:ctrl

279 		struct v4l2_ext_control *ctrl)  in cx2341x_get_ctrl()  argument
281 switch (ctrl->id) { in cx2341x_get_ctrl()
283 ctrl->value = params->audio_sampling_freq; in cx2341x_get_ctrl()
286 ctrl->value = params->audio_encoding; in cx2341x_get_ctrl()
289 ctrl->value = params->audio_l2_bitrate; in cx2341x_get_ctrl()
292 ctrl->value = params->audio_ac3_bitrate; in cx2341x_get_ctrl()
295 ctrl->value = params->audio_mode; in cx2341x_get_ctrl()
298 ctrl->value = params->audio_mode_extension; in cx2341x_get_ctrl()
301 ctrl->value = params->audio_emphasis; in cx2341x_get_ctrl()
304 ctrl->value = params->audio_crc; in cx2341x_get_ctrl()
307 ctrl->value = params->audio_mute; in cx2341x_get_ctrl()
310 ctrl->value = params->video_encoding; in cx2341x_get_ctrl()
313 ctrl->value = params->video_aspect; in cx2341x_get_ctrl()
316 ctrl->value = params->video_b_frames; in cx2341x_get_ctrl()
319 ctrl->value = params->video_gop_size; in cx2341x_get_ctrl()
322 ctrl->value = params->video_gop_closure; in cx2341x_get_ctrl()
325 ctrl->value = params->video_bitrate_mode; in cx2341x_get_ctrl()
328 ctrl->value = params->video_bitrate; in cx2341x_get_ctrl()
331 ctrl->value = params->video_bitrate_peak; in cx2341x_get_ctrl()
334 ctrl->value = params->video_temporal_decimation; in cx2341x_get_ctrl()
337 ctrl->value = params->video_mute; in cx2341x_get_ctrl()
340 ctrl->value = params->video_mute_yuv; in cx2341x_get_ctrl()
343 ctrl->value = params->stream_type; in cx2341x_get_ctrl()
346 ctrl->value = params->stream_vbi_fmt; in cx2341x_get_ctrl()
349 ctrl->value = params->video_spatial_filter_mode; in cx2341x_get_ctrl()
352 ctrl->value = params->video_spatial_filter; in cx2341x_get_ctrl()
355 ctrl->value = params->video_luma_spatial_filter_type; in cx2341x_get_ctrl()
358 ctrl->value = params->video_chroma_spatial_filter_type; in cx2341x_get_ctrl()
361 ctrl->value = params->video_temporal_filter_mode; in cx2341x_get_ctrl()
364 ctrl->value = params->video_temporal_filter; in cx2341x_get_ctrl()
367 ctrl->value = params->video_median_filter_type; in cx2341x_get_ctrl()
370 ctrl->value = params->video_luma_median_filter_top; in cx2341x_get_ctrl()
373 ctrl->value = params->video_luma_median_filter_bottom; in cx2341x_get_ctrl()
376 ctrl->value = params->video_chroma_median_filter_top; in cx2341x_get_ctrl()
379 ctrl->value = params->video_chroma_median_filter_bottom; in cx2341x_get_ctrl()
382 ctrl->value = params->stream_insert_nav_packets; in cx2341x_get_ctrl()
393 struct v4l2_ext_control *ctrl) in cx2341x_set_ctrl() argument
395 switch (ctrl->id) { in cx2341x_set_ctrl()
399 params->audio_sampling_freq = ctrl->value; in cx2341x_set_ctrl()
405 if (ctrl->value != V4L2_MPEG_AUDIO_ENCODING_LAYER_2 && in cx2341x_set_ctrl()
406 ctrl->value != V4L2_MPEG_AUDIO_ENCODING_AC3) in cx2341x_set_ctrl()
408 params->audio_encoding = ctrl->value; in cx2341x_set_ctrl()
413 params->audio_l2_bitrate = ctrl->value; in cx2341x_set_ctrl()
420 params->audio_ac3_bitrate = ctrl->value; in cx2341x_set_ctrl()
423 params->audio_mode = ctrl->value; in cx2341x_set_ctrl()
426 params->audio_mode_extension = ctrl->value; in cx2341x_set_ctrl()
429 params->audio_emphasis = ctrl->value; in cx2341x_set_ctrl()
432 params->audio_crc = ctrl->value; in cx2341x_set_ctrl()
435 params->audio_mute = ctrl->value; in cx2341x_set_ctrl()
438 params->video_aspect = ctrl->value; in cx2341x_set_ctrl()
441 int b = ctrl->value + 1; in cx2341x_set_ctrl()
443 params->video_b_frames = ctrl->value; in cx2341x_set_ctrl()
452 int gop = ctrl->value; in cx2341x_set_ctrl()
457 ctrl->value = params->video_gop_size; in cx2341x_set_ctrl()
461 params->video_gop_closure = ctrl->value; in cx2341x_set_ctrl()
468 ctrl->value != V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) in cx2341x_set_ctrl()
470 params->video_bitrate_mode = ctrl->value; in cx2341x_set_ctrl()
475 params->video_bitrate = ctrl->value; in cx2341x_set_ctrl()
480 params->video_bitrate_peak = ctrl->value; in cx2341x_set_ctrl()
483 params->video_temporal_decimation = ctrl->value; in cx2341x_set_ctrl()
486 params->video_mute = (ctrl->value != 0); in cx2341x_set_ctrl()
489 params->video_mute_yuv = ctrl->value; in cx2341x_set_ctrl()
494 params->stream_type = ctrl->value; in cx2341x_set_ctrl()
506 params->stream_vbi_fmt = ctrl->value; in cx2341x_set_ctrl()
509 params->video_spatial_filter_mode = ctrl->value; in cx2341x_set_ctrl()
512 params->video_spatial_filter = ctrl->value; in cx2341x_set_ctrl()
515 params->video_luma_spatial_filter_type = ctrl->value; in cx2341x_set_ctrl()
518 params->video_chroma_spatial_filter_type = ctrl->value; in cx2341x_set_ctrl()
521 params->video_temporal_filter_mode = ctrl->value; in cx2341x_set_ctrl()
524 params->video_temporal_filter = ctrl->value; in cx2341x_set_ctrl()
527 params->video_median_filter_type = ctrl->value; in cx2341x_set_ctrl()
530 params->video_luma_median_filter_top = ctrl->value; in cx2341x_set_ctrl()
533 params->video_luma_median_filter_bottom = ctrl->value; in cx2341x_set_ctrl()
536 params->video_chroma_median_filter_top = ctrl->value; in cx2341x_set_ctrl()
539 params->video_chroma_median_filter_bottom = ctrl->value; in cx2341x_set_ctrl()
542 params->stream_insert_nav_packets = ctrl->value; in cx2341x_set_ctrl()
937 static int v4l2_ctrl_check(struct v4l2_ext_control *ctrl, struct v4l2_queryctrl *qctrl, in v4l2_ctrl_check() argument
950 if (ctrl->value < qctrl->minimum || ctrl->value > qctrl->maximum) in v4l2_ctrl_check()
953 if (menu_items[ctrl->value] == NULL || in v4l2_ctrl_check()
954 menu_items[ctrl->value][0] == '\0') in v4l2_ctrl_check()
958 (ctrl->value & ~qctrl->maximum)) in v4l2_ctrl_check()
971 struct v4l2_ext_control *ctrl = ctrls->controls + i; in cx2341x_ext_ctrls() local
973 err = cx2341x_get_ctrl(params, ctrl); in cx2341x_ext_ctrls()
982 struct v4l2_ext_control *ctrl = ctrls->controls + i; in cx2341x_ext_ctrls() local
986 qctrl.id = ctrl->id; in cx2341x_ext_ctrls()
992 err = v4l2_ctrl_check(ctrl, &qctrl, menu_items); in cx2341x_ext_ctrls()
995 err = cx2341x_set_ctrl(params, busy, ctrl); in cx2341x_ext_ctrls()
1168 struct v4l2_ext_control ctrl; in cx2341x_menu_item() local
1172 ctrl.id = id; in cx2341x_menu_item()
1173 if (cx2341x_get_ctrl(p, &ctrl)) in cx2341x_menu_item()
1175 while (ctrl.value-- && *menu) menu++; in cx2341x_menu_item()
1273 static inline struct cx2341x_handler *to_cxhdl(struct v4l2_ctrl *ctrl) in to_cxhdl() argument
1275 return container_of(ctrl->handler, struct cx2341x_handler, hdl); in to_cxhdl()
1294 static inline int cx2341x_neq(struct v4l2_ctrl *ctrl) in cx2341x_neq() argument
1296 return ctrl && ctrl->val != ctrl->cur.val; in cx2341x_neq()
1299 static int cx2341x_try_ctrl(struct v4l2_ctrl *ctrl) in cx2341x_try_ctrl() argument
1301 struct cx2341x_handler *hdl = to_cxhdl(ctrl); in cx2341x_try_ctrl()
1302 s32 val = ctrl->val; in cx2341x_try_ctrl()
1304 switch (ctrl->id) { in cx2341x_try_ctrl()
1339 static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) in cx2341x_s_ctrl() argument
1349 struct cx2341x_handler *hdl = to_cxhdl(ctrl); in cx2341x_s_ctrl()
1350 s32 val = ctrl->val; in cx2341x_s_ctrl()
1354 switch (ctrl->id) { in cx2341x_s_ctrl()