| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /* Automatically generated code, do not edit */ | ||
| 2 | /* Generated from source file: side4h.pck */ | ||
| 3 | |||
| 4 | 211546 | inline int side4h_3d_filter( const double* p0, const double* p1, const double* p2, const double* p3, const double* p4, double h0, double h1, double h2, double h3, double h4) { | |
| 5 | double a11; | ||
| 6 | 211546 | a11 = (p1[0] - p0[0]); | |
| 7 | double a12; | ||
| 8 | 211546 | a12 = (p1[1] - p0[1]); | |
| 9 | double a13; | ||
| 10 | 211546 | a13 = (p1[2] - p0[2]); | |
| 11 | double a14; | ||
| 12 | 211546 | a14 = (h0 - h1); | |
| 13 | double a21; | ||
| 14 | 211546 | a21 = (p2[0] - p0[0]); | |
| 15 | double a22; | ||
| 16 | 211546 | a22 = (p2[1] - p0[1]); | |
| 17 | double a23; | ||
| 18 | 211546 | a23 = (p2[2] - p0[2]); | |
| 19 | double a24; | ||
| 20 | 211546 | a24 = (h0 - h2); | |
| 21 | double a31; | ||
| 22 | 211546 | a31 = (p3[0] - p0[0]); | |
| 23 | double a32; | ||
| 24 | 211546 | a32 = (p3[1] - p0[1]); | |
| 25 | double a33; | ||
| 26 | 211546 | a33 = (p3[2] - p0[2]); | |
| 27 | double a34; | ||
| 28 | 211546 | a34 = (h0 - h3); | |
| 29 | double a41; | ||
| 30 | 211546 | a41 = (p4[0] - p0[0]); | |
| 31 | double a42; | ||
| 32 | 211546 | a42 = (p4[1] - p0[1]); | |
| 33 | double a43; | ||
| 34 | 211546 | a43 = (p4[2] - p0[2]); | |
| 35 | double a44; | ||
| 36 | 211546 | a44 = (h0 - h4); | |
| 37 | double Delta1; | ||
| 38 | 211546 | Delta1 = (((a21 * ((a32 * a43) - (a33 * a42))) - (a31 * ((a22 * a43) - (a23 * a42)))) + (a41 * ((a22 * a33) - (a23 * a32)))); | |
| 39 | double Delta2; | ||
| 40 | 211546 | Delta2 = (((a11 * ((a32 * a43) - (a33 * a42))) - (a31 * ((a12 * a43) - (a13 * a42)))) + (a41 * ((a12 * a33) - (a13 * a32)))); | |
| 41 | double Delta3; | ||
| 42 | 211546 | Delta3 = (((a11 * ((a22 * a43) - (a23 * a42))) - (a21 * ((a12 * a43) - (a13 * a42)))) + (a41 * ((a12 * a23) - (a13 * a22)))); | |
| 43 | double Delta4; | ||
| 44 | 211546 | Delta4 = (((a11 * ((a22 * a33) - (a23 * a32))) - (a21 * ((a12 * a33) - (a13 * a32)))) + (a31 * ((a12 * a23) - (a13 * a22)))); | |
| 45 | double r; | ||
| 46 | 211546 | r = ((((Delta1 * a14) - (Delta2 * a24)) + (Delta3 * a34)) - (Delta4 * a44)); | |
| 47 | double eps; | ||
| 48 | 211546 | double max1 = fabs(a11); | |
| 49 |
2/2✓ Branch 0 taken 82774 times.
✓ Branch 1 taken 128772 times.
|
211546 | if( (max1 < fabs(a21)) ) |
| 50 | { | ||
| 51 | 82774 | max1 = fabs(a21); | |
| 52 | } | ||
| 53 |
2/2✓ Branch 0 taken 56286 times.
✓ Branch 1 taken 155260 times.
|
211546 | if( (max1 < fabs(a31)) ) |
| 54 | { | ||
| 55 | 56286 | max1 = fabs(a31); | |
| 56 | } | ||
| 57 | 211546 | double max2 = fabs(a12); | |
| 58 |
2/2✓ Branch 0 taken 106447 times.
✓ Branch 1 taken 105099 times.
|
211546 | if( (max2 < fabs(a13)) ) |
| 59 | { | ||
| 60 | 106447 | max2 = fabs(a13); | |
| 61 | } | ||
| 62 |
2/2✓ Branch 0 taken 61324 times.
✓ Branch 1 taken 150222 times.
|
211546 | if( (max2 < fabs(a22)) ) |
| 63 | { | ||
| 64 | 61324 | max2 = fabs(a22); | |
| 65 | } | ||
| 66 |
2/2✓ Branch 0 taken 37588 times.
✓ Branch 1 taken 173958 times.
|
211546 | if( (max2 < fabs(a23)) ) |
| 67 | { | ||
| 68 | 37588 | max2 = fabs(a23); | |
| 69 | } | ||
| 70 | 211546 | double max3 = fabs(a22); | |
| 71 |
2/2✓ Branch 0 taken 110999 times.
✓ Branch 1 taken 100547 times.
|
211546 | if( (max3 < fabs(a23)) ) |
| 72 | { | ||
| 73 | 110999 | max3 = fabs(a23); | |
| 74 | } | ||
| 75 |
2/2✓ Branch 0 taken 72797 times.
✓ Branch 1 taken 138749 times.
|
211546 | if( (max3 < fabs(a32)) ) |
| 76 | { | ||
| 77 | 72797 | max3 = fabs(a32); | |
| 78 | } | ||
| 79 |
2/2✓ Branch 0 taken 46382 times.
✓ Branch 1 taken 165164 times.
|
211546 | if( (max3 < fabs(a33)) ) |
| 80 | { | ||
| 81 | 46382 | max3 = fabs(a33); | |
| 82 | } | ||
| 83 | double lower_bound_1; | ||
| 84 | double upper_bound_1; | ||
| 85 | int Delta4_sign; | ||
| 86 | int int_tmp_result; | ||
| 87 | 211546 | lower_bound_1 = max1; | |
| 88 | 211546 | upper_bound_1 = max1; | |
| 89 |
2/2✓ Branch 0 taken 81845 times.
✓ Branch 1 taken 129701 times.
|
211546 | if( (max2 < lower_bound_1) ) |
| 90 | { | ||
| 91 | 81845 | lower_bound_1 = max2; | |
| 92 | } | ||
| 93 | else | ||
| 94 | { | ||
| 95 |
2/2✓ Branch 0 taken 128843 times.
✓ Branch 1 taken 858 times.
|
129701 | if( (max2 > upper_bound_1) ) |
| 96 | { | ||
| 97 | 128843 | upper_bound_1 = max2; | |
| 98 | } | ||
| 99 | } | ||
| 100 |
2/2✓ Branch 0 taken 35420 times.
✓ Branch 1 taken 176126 times.
|
211546 | if( (max3 < lower_bound_1) ) |
| 101 | { | ||
| 102 | 35420 | lower_bound_1 = max3; | |
| 103 | } | ||
| 104 | else | ||
| 105 | { | ||
| 106 |
2/2✓ Branch 0 taken 33553 times.
✓ Branch 1 taken 142573 times.
|
176126 | if( (max3 > upper_bound_1) ) |
| 107 | { | ||
| 108 | 33553 | upper_bound_1 = max3; | |
| 109 | } | ||
| 110 | } | ||
| 111 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 211546 times.
|
211546 | if( (lower_bound_1 < 1.63288018496748314939e-98) ) |
| 112 | { | ||
| 113 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 114 | } | ||
| 115 | else | ||
| 116 | { | ||
| 117 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 211546 times.
|
211546 | if( (upper_bound_1 > 7.23700557733225980357e+75) ) |
| 118 | { | ||
| 119 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 120 | } | ||
| 121 | 211546 | eps = (5.11071278299732992696e-15 * ((max2 * max3) * max1)); | |
| 122 |
1/2✓ Branch 0 taken 211546 times.
✗ Branch 1 not taken.
|
211546 | if( (Delta4 > eps) ) |
| 123 | { | ||
| 124 | 211546 | int_tmp_result = 1; | |
| 125 | } | ||
| 126 | else | ||
| 127 | { | ||
| 128 | ✗ | if( (Delta4 < -eps) ) | |
| 129 | { | ||
| 130 | ✗ | int_tmp_result = -1; | |
| 131 | } | ||
| 132 | else | ||
| 133 | { | ||
| 134 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 135 | } | ||
| 136 | } | ||
| 137 | } | ||
| 138 | 211546 | Delta4_sign = int_tmp_result; | |
| 139 | int int_tmp_result_FFWKCAA; | ||
| 140 | 211546 | double max4 = max1; | |
| 141 |
2/2✓ Branch 0 taken 28945 times.
✓ Branch 1 taken 182601 times.
|
211546 | if( (max4 < fabs(a41)) ) |
| 142 | { | ||
| 143 | 28945 | max4 = fabs(a41); | |
| 144 | } | ||
| 145 | 211546 | double max5 = max2; | |
| 146 |
2/2✓ Branch 0 taken 54702 times.
✓ Branch 1 taken 156844 times.
|
211546 | if( (max5 < max3) ) |
| 147 | { | ||
| 148 | 54702 | max5 = max3; | |
| 149 | } | ||
| 150 | 211546 | double max6 = fabs(a14); | |
| 151 |
2/2✓ Branch 0 taken 101286 times.
✓ Branch 1 taken 110260 times.
|
211546 | if( (max6 < fabs(a24)) ) |
| 152 | { | ||
| 153 | 101286 | max6 = fabs(a24); | |
| 154 | } | ||
| 155 |
2/2✓ Branch 0 taken 74370 times.
✓ Branch 1 taken 137176 times.
|
211546 | if( (max6 < fabs(a34)) ) |
| 156 | { | ||
| 157 | 74370 | max6 = fabs(a34); | |
| 158 | } | ||
| 159 |
2/2✓ Branch 0 taken 34897 times.
✓ Branch 1 taken 176649 times.
|
211546 | if( (max6 < fabs(a44)) ) |
| 160 | { | ||
| 161 | 34897 | max6 = fabs(a44); | |
| 162 | } | ||
| 163 | 211546 | double max7 = max3; | |
| 164 |
2/2✓ Branch 0 taken 22888 times.
✓ Branch 1 taken 188658 times.
|
211546 | if( (max7 < fabs(a42)) ) |
| 165 | { | ||
| 166 | 22888 | max7 = fabs(a42); | |
| 167 | } | ||
| 168 |
2/2✓ Branch 0 taken 15861 times.
✓ Branch 1 taken 195685 times.
|
211546 | if( (max7 < fabs(a43)) ) |
| 169 | { | ||
| 170 | 15861 | max7 = fabs(a43); | |
| 171 | } | ||
| 172 | 211546 | lower_bound_1 = max4; | |
| 173 | 211546 | upper_bound_1 = max4; | |
| 174 |
2/2✓ Branch 0 taken 72138 times.
✓ Branch 1 taken 139408 times.
|
211546 | if( (max5 < lower_bound_1) ) |
| 175 | { | ||
| 176 | 72138 | lower_bound_1 = max5; | |
| 177 | } | ||
| 178 | else | ||
| 179 | { | ||
| 180 |
2/2✓ Branch 0 taken 138264 times.
✓ Branch 1 taken 1144 times.
|
139408 | if( (max5 > upper_bound_1) ) |
| 181 | { | ||
| 182 | 138264 | upper_bound_1 = max5; | |
| 183 | } | ||
| 184 | } | ||
| 185 |
2/2✓ Branch 0 taken 10392 times.
✓ Branch 1 taken 201154 times.
|
211546 | if( (max6 < lower_bound_1) ) |
| 186 | { | ||
| 187 | 10392 | lower_bound_1 = max6; | |
| 188 | } | ||
| 189 | else | ||
| 190 | { | ||
| 191 |
2/2✓ Branch 0 taken 166085 times.
✓ Branch 1 taken 35069 times.
|
201154 | if( (max6 > upper_bound_1) ) |
| 192 | { | ||
| 193 | 166085 | upper_bound_1 = max6; | |
| 194 | } | ||
| 195 | } | ||
| 196 |
2/2✓ Branch 0 taken 25510 times.
✓ Branch 1 taken 186036 times.
|
211546 | if( (max7 < lower_bound_1) ) |
| 197 | { | ||
| 198 | 25510 | lower_bound_1 = max7; | |
| 199 | } | ||
| 200 | else | ||
| 201 | { | ||
| 202 |
2/2✓ Branch 0 taken 3160 times.
✓ Branch 1 taken 182876 times.
|
186036 | if( (max7 > upper_bound_1) ) |
| 203 | { | ||
| 204 | 3160 | upper_bound_1 = max7; | |
| 205 | } | ||
| 206 | } | ||
| 207 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 211546 times.
|
211546 | if( (lower_bound_1 < 2.89273249588395194294e-74) ) |
| 208 | { | ||
| 209 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 210 | } | ||
| 211 | else | ||
| 212 | { | ||
| 213 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 211546 times.
|
211546 | if( (upper_bound_1 > 7.23700557733225980357e+75) ) |
| 214 | { | ||
| 215 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 216 | } | ||
| 217 | 211546 | eps = (3.17768858673611390687e-14 * (((max5 * max7) * max4) * max6)); | |
| 218 |
2/2✓ Branch 0 taken 64244 times.
✓ Branch 1 taken 147302 times.
|
211546 | if( (r > eps) ) |
| 219 | { | ||
| 220 | 64244 | int_tmp_result_FFWKCAA = 1; | |
| 221 | } | ||
| 222 | else | ||
| 223 | { | ||
| 224 |
2/2✓ Branch 0 taken 142034 times.
✓ Branch 1 taken 5268 times.
|
147302 | if( (r < -eps) ) |
| 225 | { | ||
| 226 | 142034 | int_tmp_result_FFWKCAA = -1; | |
| 227 | } | ||
| 228 | else | ||
| 229 | { | ||
| 230 | 5268 | return FPG_UNCERTAIN_VALUE; | |
| 231 | } | ||
| 232 | } | ||
| 233 | } | ||
| 234 | 206278 | return (Delta4_sign * int_tmp_result_FFWKCAA); | |
| 235 | } | ||
| 236 |