diff options
author | Janne Grunau <j@jannau.net> | 2008-08-08 06:21:00 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-10-12 07:36:47 -0400 |
commit | 188919ac57810e39138749338d5a33ba1e970e23 (patch) | |
tree | 4ec96a44894c8d3ea7557393eb1fac08536564f6 /drivers/media/video/v4l2-common.c | |
parent | a832781cd383e70929c0ceece23f8a5b62e2152b (diff) |
V4L/DVB (8634): v4l2: extend MPEG Encoding API with AVC and AAC
Adds Advanced Audio Coding (AAC) and MPEG-4 Advanced Video Coding
(AVC/H.264) as audio/video codecs to the extended controls API.
Updates cx2341x driver to the new values.
Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/v4l2-common.c')
-rw-r--r-- | drivers/media/video/v4l2-common.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/media/video/v4l2-common.c b/drivers/media/video/v4l2-common.c index 88ca13104417..893ac496c4b4 100644 --- a/drivers/media/video/v4l2-common.c +++ b/drivers/media/video/v4l2-common.c | |||
@@ -187,9 +187,10 @@ const char **v4l2_ctrl_get_menu(u32 id) | |||
187 | NULL | 187 | NULL |
188 | }; | 188 | }; |
189 | static const char *mpeg_audio_encoding[] = { | 189 | static const char *mpeg_audio_encoding[] = { |
190 | "Layer I", | 190 | "MPEG-1 Layer I", |
191 | "Layer II", | 191 | "MPEG-1 Layer II", |
192 | "Layer III", | 192 | "MPEG-1 Layer III", |
193 | "MPEG-4 AAC", | ||
193 | NULL | 194 | NULL |
194 | }; | 195 | }; |
195 | static const char *mpeg_audio_l1_bitrate[] = { | 196 | static const char *mpeg_audio_l1_bitrate[] = { |
@@ -271,6 +272,7 @@ const char **v4l2_ctrl_get_menu(u32 id) | |||
271 | static const char *mpeg_video_encoding[] = { | 272 | static const char *mpeg_video_encoding[] = { |
272 | "MPEG-1", | 273 | "MPEG-1", |
273 | "MPEG-2", | 274 | "MPEG-2", |
275 | "MPEG-4 AVC", | ||
274 | NULL | 276 | NULL |
275 | }; | 277 | }; |
276 | static const char *mpeg_video_aspect[] = { | 278 | static const char *mpeg_video_aspect[] = { |
@@ -358,7 +360,7 @@ int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, s32 min, s32 max, s32 ste | |||
358 | /* MPEG controls */ | 360 | /* MPEG controls */ |
359 | case V4L2_CID_MPEG_CLASS: name = "MPEG Encoder Controls"; break; | 361 | case V4L2_CID_MPEG_CLASS: name = "MPEG Encoder Controls"; break; |
360 | case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: name = "Audio Sampling Frequency"; break; | 362 | case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: name = "Audio Sampling Frequency"; break; |
361 | case V4L2_CID_MPEG_AUDIO_ENCODING: name = "Audio Encoding Layer"; break; | 363 | case V4L2_CID_MPEG_AUDIO_ENCODING: name = "Audio Encoding"; break; |
362 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: name = "Audio Layer I Bitrate"; break; | 364 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: name = "Audio Layer I Bitrate"; break; |
363 | case V4L2_CID_MPEG_AUDIO_L2_BITRATE: name = "Audio Layer II Bitrate"; break; | 365 | case V4L2_CID_MPEG_AUDIO_L2_BITRATE: name = "Audio Layer II Bitrate"; break; |
364 | case V4L2_CID_MPEG_AUDIO_L3_BITRATE: name = "Audio Layer III Bitrate"; break; | 366 | case V4L2_CID_MPEG_AUDIO_L3_BITRATE: name = "Audio Layer III Bitrate"; break; |
@@ -493,7 +495,7 @@ int v4l2_ctrl_query_fill_std(struct v4l2_queryctrl *qctrl) | |||
493 | case V4L2_CID_MPEG_AUDIO_ENCODING: | 495 | case V4L2_CID_MPEG_AUDIO_ENCODING: |
494 | return v4l2_ctrl_query_fill(qctrl, | 496 | return v4l2_ctrl_query_fill(qctrl, |
495 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1, | 497 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1, |
496 | V4L2_MPEG_AUDIO_ENCODING_LAYER_3, 1, | 498 | V4L2_MPEG_AUDIO_ENCODING_AAC, 1, |
497 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2); | 499 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2); |
498 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: | 500 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: |
499 | return v4l2_ctrl_query_fill(qctrl, | 501 | return v4l2_ctrl_query_fill(qctrl, |
@@ -535,7 +537,7 @@ int v4l2_ctrl_query_fill_std(struct v4l2_queryctrl *qctrl) | |||
535 | case V4L2_CID_MPEG_VIDEO_ENCODING: | 537 | case V4L2_CID_MPEG_VIDEO_ENCODING: |
536 | return v4l2_ctrl_query_fill(qctrl, | 538 | return v4l2_ctrl_query_fill(qctrl, |
537 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1, | 539 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1, |
538 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2, 1, | 540 | V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC, 1, |
539 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2); | 541 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2); |
540 | case V4L2_CID_MPEG_VIDEO_ASPECT: | 542 | case V4L2_CID_MPEG_VIDEO_ASPECT: |
541 | return v4l2_ctrl_query_fill(qctrl, | 543 | return v4l2_ctrl_query_fill(qctrl, |