1 /*******************************************************************************
2 * Copyright 2016-2019 Intel Corporation.
3 *
4 * This software and the related documents are Intel copyrighted  materials,  and
5 * your use of  them is  governed by the  express license  under which  they were
6 * provided to you (License).  Unless the License provides otherwise, you may not
7 * use, modify, copy, publish, distribute,  disclose or transmit this software or
8 * the related documents without Intel's prior written permission.
9 *
10 * This software and the related documents  are provided as  is,  with no express
11 * or implied  warranties,  other  than those  that are  expressly stated  in the
12 * License.
13 *******************************************************************************/
14 
15 #if !defined( __IPP_IW_CONFIG__ )
16 #define __IPP_IW_CONFIG__
17 
18 #ifndef IW_BUILD
19 #error this is a private header
20 #endif
21 
22 /*
23     These switches are used during IW library compilation to customize the library code and decrease memory footprint
24     of the library.
25 */
26 
27 /* /////////////////////////////////////////////////////////////////////////////
28 //                   Library Features
29 ///////////////////////////////////////////////////////////////////////////// */
30 
31 #ifndef IW_ENABLE_THREADING_LAYER
32 #define IW_ENABLE_THREADING_LAYER 0 // Enables Intel IPP Threading Layer calls inside IW if possible (requires OpenMP support)
33 #endif                              // Parallel version of functions will be used if:
34                                     // 1. There is a parallel implementation for a particular function (see function description in the header)
35                                     // 2. If iwGetThreadsNum() function result is greater than 1 before functions call or spec initialization call
36                                     // Note: tiling cannot be used with internal threading. IwiTile parameter will be ignored if conditions above are true before function call
37                                     // To disable threading on run time: call iwSetThreadsNum(1) before a function call
38 
39 #ifndef IW_ENABLE_TLS
40 #define IW_ENABLE_TLS 1             // Enables use of Thread Local Storage. This adds dependency on POSIX Threads on POSIX systems.
41 #endif
42 
43 /* /////////////////////////////////////////////////////////////////////////////
44 //                   Data types
45 ///////////////////////////////////////////////////////////////////////////// */
46 
47 // These switches can remove Intel IPP functions calls with some data types to reduce memory footprint.
48 // Functions which operates with several types and channels will be enabled if at least one of parameters has enabled type
49 // Note that some functionality can become completely disabled if some of these defines are switched off
50 #ifndef IW_ENABLE_DATA_TYPE_8U
51 #define IW_ENABLE_DATA_TYPE_8U  1
52 #endif
53 #ifndef IW_ENABLE_DATA_TYPE_8S
54 #define IW_ENABLE_DATA_TYPE_8S  1
55 #endif
56 #ifndef IW_ENABLE_DATA_TYPE_16U
57 #define IW_ENABLE_DATA_TYPE_16U 1
58 #endif
59 #ifndef IW_ENABLE_DATA_TYPE_16S
60 #define IW_ENABLE_DATA_TYPE_16S 1
61 #endif
62 #ifndef IW_ENABLE_DATA_TYPE_32U
63 #define IW_ENABLE_DATA_TYPE_32U 0
64 #endif
65 #ifndef IW_ENABLE_DATA_TYPE_32S
66 #define IW_ENABLE_DATA_TYPE_32S 1
67 #endif
68 #ifndef IW_ENABLE_DATA_TYPE_32F
69 #define IW_ENABLE_DATA_TYPE_32F 1
70 #endif
71 #ifndef IW_ENABLE_DATA_TYPE_64U
72 #define IW_ENABLE_DATA_TYPE_64U 0
73 #endif
74 #ifndef IW_ENABLE_DATA_TYPE_64S
75 #define IW_ENABLE_DATA_TYPE_64S 0
76 #endif
77 #ifndef IW_ENABLE_DATA_TYPE_64F
78 #define IW_ENABLE_DATA_TYPE_64F 1
79 #endif
80 
81 /* /////////////////////////////////////////////////////////////////////////////
82 //                   Channels
83 ///////////////////////////////////////////////////////////////////////////// */
84 
85 #ifndef IW_ENABLE_CHANNELS_C1
86 #define IW_ENABLE_CHANNELS_C1  1
87 #endif
88 #ifndef IW_ENABLE_CHANNELS_C3
89 #define IW_ENABLE_CHANNELS_C3  1
90 #endif
91 #ifndef IW_ENABLE_CHANNELS_C4
92 #define IW_ENABLE_CHANNELS_C4  1
93 #endif
94 #ifndef IW_ENABLE_CHANNELS_AC4
95 #define IW_ENABLE_CHANNELS_AC4 0
96 #endif
97 
98 /* /////////////////////////////////////////////////////////////////////////////
99 //                   Functions Features
100 ///////////////////////////////////////////////////////////////////////////// */
101 
102 // iwiResize
103 #ifndef IW_ENABLE_iwiResize_Nearest
104 #define IW_ENABLE_iwiResize_Nearest         0
105 #endif
106 #ifndef IW_ENABLE_iwiResize_Super
107 #define IW_ENABLE_iwiResize_Super           1
108 #endif
109 #ifndef IW_ENABLE_iwiResize_Linear
110 #define IW_ENABLE_iwiResize_Linear          1
111 #endif
112 #ifndef IW_ENABLE_iwiResize_LinearAA
113 #define IW_ENABLE_iwiResize_LinearAA        0
114 #endif
115 #ifndef IW_ENABLE_iwiResize_Cubic
116 #define IW_ENABLE_iwiResize_Cubic           1
117 #endif
118 #ifndef IW_ENABLE_iwiResize_CubicAA
119 #define IW_ENABLE_iwiResize_CubicAA         0
120 #endif
121 #ifndef IW_ENABLE_iwiResize_Lanczos
122 #define IW_ENABLE_iwiResize_Lanczos         1
123 #endif
124 #ifndef IW_ENABLE_iwiResize_LanczosAA
125 #define IW_ENABLE_iwiResize_LanczosAA       0
126 #endif
127 
128 #endif
129