From patchwork Mon Apr 19 03:31:02 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xiaolin Zhang X-Patchwork-Id: 93413 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o3J3VXjF022679 for ; Mon, 19 Apr 2010 03:31:34 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753631Ab0DSDbU (ORCPT ); Sun, 18 Apr 2010 23:31:20 -0400 Received: from mga01.intel.com ([192.55.52.88]:46886 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752927Ab0DSDbT convert rfc822-to-8bit (ORCPT ); Sun, 18 Apr 2010 23:31:19 -0400 Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga101.fm.intel.com with ESMTP; 18 Apr 2010 20:30:09 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.52,233,1270450800"; d="scan'208";a="559173507" Received: from pgsmsx601.gar.corp.intel.com ([10.221.43.69]) by fmsmga002.fm.intel.com with ESMTP; 18 Apr 2010 20:30:57 -0700 Received: from shzsmsx502.ccr.corp.intel.com (10.239.4.97) by pgsmsx601.gar.corp.intel.com (10.221.43.69) with Microsoft SMTP Server (TLS) id 8.2.176.0; Mon, 19 Apr 2010 11:31:05 +0800 Received: from shsmsx501.ccr.corp.intel.com ([10.239.4.141]) by shzsmsx502.ccr.corp.intel.com ([10.239.4.97]) with mapi; Mon, 19 Apr 2010 11:31:03 +0800 From: "Zhang, Xiaolin" To: "Zhang, Xiaolin" , Hans Verkuil CC: "linux-media@vger.kernel.org" , "Zhu, Daniel" , "Bian, Jonathan" Date: Mon, 19 Apr 2010 11:31:02 +0800 Subject: [PATCH] To support more color effects (negative, sketch, emboss, etc) by extending v4l2_colorfx enum items Thread-Topic: [PATCH] To support more color effects (negative, sketch, emboss, etc) by extending v4l2_colorfx enum items Thread-Index: AcrbDyTKG8u+KNblQAOo4xyifzFTVAABKIDwARb/t6A= Message-ID: <33AB447FBD802F4E932063B962385B351D8B5DDA@shsmsx501.ccr.corp.intel.com> References: <33AB447FBD802F4E932063B962385B351D84C129@shsmsx501.ccr.corp.intel.com> <258a57e817688f9fa0c1e87fdadc740c.squirrel@webmail.xs4all.nl> <33AB447FBD802F4E932063B962385B351D84C1BF@shsmsx501.ccr.corp.intel.com> In-Reply-To: <33AB447FBD802F4E932063B962385B351D84C1BF@shsmsx501.ccr.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Mon, 19 Apr 2010 03:31:34 +0000 (UTC) diff --git a/Documentation/DocBook/v4l/controls.xml b/Documentation/DocBook/v4l/controls.xml index f464506..ee0a359 100644 --- a/Documentation/DocBook/v4l/controls.xml +++ b/Documentation/DocBook/v4l/controls.xml @@ -277,8 +277,15 @@ minimum value disables backlight compensation. Selects a color effect. Possible values for enum v4l2_colorfx are: V4L2_COLORFX_NONE (0), -V4L2_COLORFX_BW (1) and -V4L2_COLORFX_SEPIA (2). +V4L2_COLORFX_BW (1), +V4L2_COLORFX_SEPIA (2), +V4L2_COLORFX_NEGATIVE (3), +V4L2_COLORFX_EMBOSS (4), +V4L2_COLORFX_SKETCH (5), +V4L2_COLORFX_SKY_BLUE (6), +V4L2_COLORFX_GRASS_GREEN (7), +V4L2_COLORFX_SKIN_WHITEN (8) and +V4L2_COLORFX_VIVID (9). V4L2_CID_ROTATE diff --git a/Documentation/DocBook/v4l/videodev2.h.xml b/Documentation/DocBook/v4l/videodev2.h.xml index 0683259..11bf4cc 100644 --- a/Documentation/DocBook/v4l/videodev2.h.xml +++ b/Documentation/DocBook/v4l/videodev2.h.xml @@ -1018,6 +1018,13 @@ enum v4l2_colorfx { V4L2_COLORFX_NONE = 0, V4L2_COLORFX_BW = 1, V4L2_COLORFX_SEPIA = 2, + V4L2_COLORFX_NEGATIVE = 3, + V4L2_COLORFX_EMBOSS = 4, + V4L2_COLORFX_SKETCH = 5, + V4L2_COLORFX_SKY_BLUE = 6, + V4L2_COLORFX_GRASS_GREEN = 7, + V4L2_COLORFX_SKIN_WHITEN = 8, + V4L2_COLORFX_VIVID = 9. }; #define V4L2_CID_AUTOBRIGHTNESS (V4L2_CID_BASE+32) #define V4L2_CID_BAND_STOP_FILTER (V4L2_CID_BASE+33) diff --git a/drivers/media/video/v4l2-common.c b/drivers/media/video/v4l2-common.c index 36b5cb8..cc5c499 100644 --- a/drivers/media/video/v4l2-common.c +++ b/drivers/media/video/v4l2-common.c @@ -340,6 +340,13 @@ const char **v4l2_ctrl_get_menu(u32 id) "None", "Black & White", "Sepia", + "Negative", + "Emboss", + "Sketch", + "Sky blue", + "Grass green", + "Skin whiten", + "Vivid", NULL }; static const char *tune_preemphasis[] = { diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index 3793d16..a8f2c35 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -1023,6 +1023,13 @@ enum v4l2_colorfx { V4L2_COLORFX_NONE = 0, V4L2_COLORFX_BW = 1, V4L2_COLORFX_SEPIA = 2, + V4L2_COLORFX_NEGATIVE = 3, + V4L2_COLORFX_EMBOSS = 4, + V4L2_COLORFX_SKETCH = 5, + V4L2_COLORFX_SKY_BLUE = 6, + V4L2_COLORFX_GRASS_GREEN = 7, + V4L2_COLORFX_SKIN_WHITEN = 8, + V4L2_COLORFX_VIVID = 9, }; #define V4L2_CID_AUTOBRIGHTNESS (V4L2_CID_BASE+32) #define V4L2_CID_BAND_STOP_FILTER (V4L2_CID_BASE+33)