75fa6c9a0b3de4d27fba9f741ba136079d7f4ec3
4 * Copyright (C) Georg Martius - February 2011
5 * georg dot martius at web dot de
6 * Copyright (C) Alexey Osipov - Jule 2011
7 * simba at lerlan dot ru
8 * speed optimizations (threshold, spiral, SSE, asm)
10 * This file is part of vid.stab video stabilization library
12 * vid.stab is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License,
14 * as published by the Free Software Foundation; either version 2, or
15 * (at your option) any later version.
17 * vid.stab is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with GNU Make; see the file COPYING. If not, write to
24 * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
28 #ifndef MOTIONDETECT_OPT_H
29 #define MOTIONDETECT_OPT_H
31 #include "motiondetect.h"
33 #ifdef USE_SSE2_ASM //enable SSE2 inline asm code
34 #define compareSubImg compareSubImg_thr_sse2_asm
35 #elif defined(USE_SSE2) //enable SSE2 code
36 #define compareSubImg compareSubImg_thr_sse2
37 #elif defined(USE_ORC)
38 #define compareSubImg compareSubImg_thr_orc
40 #define compareSubImg compareSubImg_thr
44 double contrastSubImg1_SSE(unsigned char* const I
, const Field
* field
,
45 int width
, int height
);
49 double contrastSubImg_variance_orc(unsigned char* const I
, const Field
* field
,
50 int width
, int height
);
51 double contrastSubImg_variance_C(unsigned char* const I
, const Field
* field
,
52 int width
, int height
);
57 unsigned int compareSubImg_orc(unsigned char* const I1
, unsigned char* const I2
,
58 const Field
* field
, int width1
, int width2
, int height
,
59 int bytesPerPixel
, int d_x
, int d_y
,
60 unsigned int threshold
);
63 unsigned int compareSubImg_thr_orc(unsigned char* const I1
, unsigned char* const I2
,
64 const Field
* field
, int width1
, int width2
, int height
,
65 int bytesPerPixel
, int d_x
, int d_y
,
66 unsigned int threshold
);
70 unsigned int compareSubImg_thr_sse2(unsigned char* const I1
, unsigned char* const I2
,
71 const Field
* field
, int width1
, int width2
, int height
,
72 int bytesPerPixel
, int d_x
, int d_y
,
73 unsigned int threshold
);
77 unsigned int compareSubImg_thr_sse2_asm(unsigned char* const I1
, unsigned char* const I2
,
78 const Field
* field
, int width1
, int width2
,
79 int height
, int bytesPerPixel
,
80 int d_x
, int d_y
, unsigned int threshold
);
83 #endif /* MOTIONDETECT_OPT_H */
87 * c-file-style: "stroustrup"
88 * c-file-offsets: ((case-label . *) (statement-case-intro . *))
89 * indent-tabs-mode: nil
95 * vim: expandtab shiftwidth=2: