From 260ae0d2726f8a89f49f45ecd1fe819035b2090c Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Sat, 1 Feb 2003 23:54:03 +0000 Subject: - remove a magic number, thanks to Cameron Simpson CVS patchset: 4082 CVS date: 2003/02/01 23:54:03 --- src/input/input_v4l.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/input/input_v4l.c b/src/input/input_v4l.c index e67ea2dc9..1c32351b2 100644 --- a/src/input/input_v4l.c +++ b/src/input/input_v4l.c @@ -42,11 +42,10 @@ #define NUM_FRAMES 40 -#define NUM_RESOLUTIONS 5 static struct { int width; int height; -} resolutions[NUM_RESOLUTIONS] = { +} resolutions[] = { { 768, 576 }, { 640, 480 }, { 384, 288 }, @@ -54,6 +53,8 @@ static struct { { 160, 120 }, }; +#define NUM_RESOLUTIONS (sizeof(resolutions)/sizeof(resolutions[0])) + /* #define LOG */ -- cgit v1.2.3