[vlc-commits] v4l2: Fix SetupFormat for CONTINUOUS framesize

Ricardo Ribalda Delgado git at videolan.org
Wed Apr 15 21:09:39 CEST 2015


vlc | branch: master | Ricardo Ribalda Delgado <ricardo.ribalda at gmail.com> | Wed Apr 15 20:42:08 2015 +0200| [4372fe4df714fccb15eeb7e0baeae74fb97edaee] | committer: Rémi Denis-Courmont

v4l2: Fix SetupFormat for CONTINUOUS framesize

One of the bounds of the loop were wrong, ending up in testing
formats that were not supported by the hardware.

Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda at gmail.com>
Signed-off-by: Rémi Denis-Courmont <remi at remlab.net>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4372fe4df714fccb15eeb7e0baeae74fb97edaee
---

 modules/access/v4l2/video.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/access/v4l2/video.c b/modules/access/v4l2/video.c
index fe5d1c9..b8544ea 100644
--- a/modules/access/v4l2/video.c
+++ b/modules/access/v4l2/video.c
@@ -508,7 +508,7 @@ int SetupFormat (vlc_object_t *obj, int fd, uint32_t fourcc,
                           width <= fse.stepwise.max_width;
                           width += fse.stepwise.step_width)
                 for (uint32_t height =  fse.stepwise.min_height;
-                              height <= fse.stepwise.max_width;
+                              height <= fse.stepwise.max_height;
                               height += fse.stepwise.step_height)
                 {
                     struct v4l2_fract cur_it;



More information about the vlc-commits mailing list