From db464f35f5a10b58d9ed1085e0b462689adee583 Mon Sep 17 00:00:00 2001 From: Siddhesh Wani Date: Mon, 25 May 2015 14:46:31 +0530 Subject: Original Version --- src/c/statisticsFunctions/max/drowmaxa.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 src/c/statisticsFunctions/max/drowmaxa.c (limited to 'src/c/statisticsFunctions/max/drowmaxa.c') diff --git a/src/c/statisticsFunctions/max/drowmaxa.c b/src/c/statisticsFunctions/max/drowmaxa.c new file mode 100644 index 00000000..a3099231 --- /dev/null +++ b/src/c/statisticsFunctions/max/drowmaxa.c @@ -0,0 +1,23 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Bruno JOFRET + * + * This file must be used under the terms of the CeCILL. + * This source file is licensed as described in the file COPYING, which + * you should have received as part of this distribution. The terms + * are also available at + * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt + * + */ + +#include "statMax.h" + +void drowmaxa(double *in, int rows, int columns, double* out) { + int i = 0, j = 0; + + for (i = 0; i < columns; i++) { + out[i]=in[i*rows]; + for (j = 1 ; j < rows ; j++) + if (in[i*rows+j]>out[i]) out[i] = in[i*rows+j]; + } +} -- cgit From 5f2d4d678256289e72c1455cf26d9c0ecdeedc0e Mon Sep 17 00:00:00 2001 From: imushir Date: Fri, 27 Nov 2015 15:22:41 +0530 Subject: added c files for u8 u16 i8 i16 --- src/c/statisticsFunctions/max/drowmaxa.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/c/statisticsFunctions/max/drowmaxa.c') diff --git a/src/c/statisticsFunctions/max/drowmaxa.c b/src/c/statisticsFunctions/max/drowmaxa.c index a3099231..db0c72c0 100644 --- a/src/c/statisticsFunctions/max/drowmaxa.c +++ b/src/c/statisticsFunctions/max/drowmaxa.c @@ -11,13 +11,14 @@ */ #include "statMax.h" - +//#include "max.h" void drowmaxa(double *in, int rows, int columns, double* out) { int i = 0, j = 0; - - for (i = 0; i < columns; i++) { + for (i = 0; i < columns; i++) + { out[i]=in[i*rows]; for (j = 1 ; j < rows ; j++) - if (in[i*rows+j]>out[i]) out[i] = in[i*rows+j]; + if (in[i*rows+j]>out[i]) + out[i] = in[i*rows+j]; } } -- cgit From c8fd6991786ccddb44547b619178bb391f3f9b96 Mon Sep 17 00:00:00 2001 From: siddhu8990 Date: Thu, 18 Aug 2016 15:47:18 +0530 Subject: RPi-PWM and basic imaage processing --- src/c/statisticsFunctions/max/drowmaxa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/c/statisticsFunctions/max/drowmaxa.c') diff --git a/src/c/statisticsFunctions/max/drowmaxa.c b/src/c/statisticsFunctions/max/drowmaxa.c index db0c72c0..596c535f 100644 --- a/src/c/statisticsFunctions/max/drowmaxa.c +++ b/src/c/statisticsFunctions/max/drowmaxa.c @@ -11,7 +11,7 @@ */ #include "statMax.h" -//#include "max.h" + void drowmaxa(double *in, int rows, int columns, double* out) { int i = 0, j = 0; for (i = 0; i < columns; i++) -- cgit