]> rtime.felk.cvut.cz Git - vajnamar/linux-xlnx.git/commitdiff
vivid: Enable 4k resolution for webcam capture device
authorSoren Brinkmann <soren.brinkmann@xilinx.com>
Mon, 19 Dec 2016 21:06:12 +0000 (13:06 -0800)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 20 Dec 2016 06:58:02 +0000 (07:58 +0100)
Add 3840x2160 as valid resolution for the webcam capture input and
adjust the webcam intervals accordingly.

Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drivers/media/platform/vivid/vivid-vid-cap.c

index b84f081c1b929b9e89d577fbdf585c30e836d34a..e32426c1332f5c2a27d40379567b6b494453b957 100644 (file)
@@ -63,7 +63,7 @@ static const struct vivid_fmt formats_ovl[] = {
 };
 
 /* The number of discrete webcam framesizes */
-#define VIVID_WEBCAM_SIZES 4
+#define VIVID_WEBCAM_SIZES 5
 /* The number of discrete webcam frameintervals */
 #define VIVID_WEBCAM_IVALS (VIVID_WEBCAM_SIZES * 2)
 
@@ -73,6 +73,7 @@ static const struct v4l2_frmsize_discrete webcam_sizes[VIVID_WEBCAM_SIZES] = {
        {  640, 360 },
        { 1280, 720 },
        { 1920, 1080 },
+       { 3840, 2160 },
 };
 
 /*
@@ -80,7 +81,9 @@ static const struct v4l2_frmsize_discrete webcam_sizes[VIVID_WEBCAM_SIZES] = {
  * elements in this array as there are in webcam_sizes.
  */
 static const struct v4l2_fract webcam_intervals[VIVID_WEBCAM_IVALS] = {
+       {  1, 1 },
        {  1, 2 },
+       {  1, 4 },
        {  1, 5 },
        {  1, 10 },
        {  1, 15 },