| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /* Automatically generated code, do not edit */ | ||
| 2 | /* Generated from source file: side4h.pck */ | ||
| 3 | |||
| 4 | 209787 | 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 | 209787 | a11 = (p1[0] - p0[0]); | |
| 7 | double a12; | ||
| 8 | 209787 | a12 = (p1[1] - p0[1]); | |
| 9 | double a13; | ||
| 10 | 209787 | a13 = (p1[2] - p0[2]); | |
| 11 | double a14; | ||
| 12 | 209787 | a14 = (h0 - h1); | |
| 13 | double a21; | ||
| 14 | 209787 | a21 = (p2[0] - p0[0]); | |
| 15 | double a22; | ||
| 16 | 209787 | a22 = (p2[1] - p0[1]); | |
| 17 | double a23; | ||
| 18 | 209787 | a23 = (p2[2] - p0[2]); | |
| 19 | double a24; | ||
| 20 | 209787 | a24 = (h0 - h2); | |
| 21 | double a31; | ||
| 22 | 209787 | a31 = (p3[0] - p0[0]); | |
| 23 | double a32; | ||
| 24 | 209787 | a32 = (p3[1] - p0[1]); | |
| 25 | double a33; | ||
| 26 | 209787 | a33 = (p3[2] - p0[2]); | |
| 27 | double a34; | ||
| 28 | 209787 | a34 = (h0 - h3); | |
| 29 | double a41; | ||
| 30 | 209787 | a41 = (p4[0] - p0[0]); | |
| 31 | double a42; | ||
| 32 | 209787 | a42 = (p4[1] - p0[1]); | |
| 33 | double a43; | ||
| 34 | 209787 | a43 = (p4[2] - p0[2]); | |
| 35 | double a44; | ||
| 36 | 209787 | a44 = (h0 - h4); | |
| 37 | double Delta1; | ||
| 38 | 209787 | Delta1 = (((a21 * ((a32 * a43) - (a33 * a42))) - (a31 * ((a22 * a43) - (a23 * a42)))) + (a41 * ((a22 * a33) - (a23 * a32)))); | |
| 39 | double Delta2; | ||
| 40 | 209787 | Delta2 = (((a11 * ((a32 * a43) - (a33 * a42))) - (a31 * ((a12 * a43) - (a13 * a42)))) + (a41 * ((a12 * a33) - (a13 * a32)))); | |
| 41 | double Delta3; | ||
| 42 | 209787 | Delta3 = (((a11 * ((a22 * a43) - (a23 * a42))) - (a21 * ((a12 * a43) - (a13 * a42)))) + (a41 * ((a12 * a23) - (a13 * a22)))); | |
| 43 | double Delta4; | ||
| 44 | 209787 | Delta4 = (((a11 * ((a22 * a33) - (a23 * a32))) - (a21 * ((a12 * a33) - (a13 * a32)))) + (a31 * ((a12 * a23) - (a13 * a22)))); | |
| 45 | double r; | ||
| 46 | 209787 | r = ((((Delta1 * a14) - (Delta2 * a24)) + (Delta3 * a34)) - (Delta4 * a44)); | |
| 47 | double eps; | ||
| 48 | 209787 | double max1 = fabs(a11); | |
| 49 |
2/2✓ Branch 0 taken 82329 times.
✓ Branch 1 taken 127458 times.
|
209787 | if( (max1 < fabs(a21)) ) |
| 50 | { | ||
| 51 | 82329 | max1 = fabs(a21); | |
| 52 | } | ||
| 53 |
2/2✓ Branch 0 taken 56121 times.
✓ Branch 1 taken 153666 times.
|
209787 | if( (max1 < fabs(a31)) ) |
| 54 | { | ||
| 55 | 56121 | max1 = fabs(a31); | |
| 56 | } | ||
| 57 | 209787 | double max2 = fabs(a12); | |
| 58 |
2/2✓ Branch 0 taken 105176 times.
✓ Branch 1 taken 104611 times.
|
209787 | if( (max2 < fabs(a13)) ) |
| 59 | { | ||
| 60 | 105176 | max2 = fabs(a13); | |
| 61 | } | ||
| 62 |
2/2✓ Branch 0 taken 60970 times.
✓ Branch 1 taken 148817 times.
|
209787 | if( (max2 < fabs(a22)) ) |
| 63 | { | ||
| 64 | 60970 | max2 = fabs(a22); | |
| 65 | } | ||
| 66 |
2/2✓ Branch 0 taken 37091 times.
✓ Branch 1 taken 172696 times.
|
209787 | if( (max2 < fabs(a23)) ) |
| 67 | { | ||
| 68 | 37091 | max2 = fabs(a23); | |
| 69 | } | ||
| 70 | 209787 | double max3 = fabs(a22); | |
| 71 |
2/2✓ Branch 0 taken 109727 times.
✓ Branch 1 taken 100060 times.
|
209787 | if( (max3 < fabs(a23)) ) |
| 72 | { | ||
| 73 | 109727 | max3 = fabs(a23); | |
| 74 | } | ||
| 75 |
2/2✓ Branch 0 taken 72137 times.
✓ Branch 1 taken 137650 times.
|
209787 | if( (max3 < fabs(a32)) ) |
| 76 | { | ||
| 77 | 72137 | max3 = fabs(a32); | |
| 78 | } | ||
| 79 |
2/2✓ Branch 0 taken 45707 times.
✓ Branch 1 taken 164080 times.
|
209787 | if( (max3 < fabs(a33)) ) |
| 80 | { | ||
| 81 | 45707 | max3 = fabs(a33); | |
| 82 | } | ||
| 83 | double lower_bound_1; | ||
| 84 | double upper_bound_1; | ||
| 85 | int Delta4_sign; | ||
| 86 | int int_tmp_result; | ||
| 87 | 209787 | lower_bound_1 = max1; | |
| 88 | 209787 | upper_bound_1 = max1; | |
| 89 |
2/2✓ Branch 0 taken 80704 times.
✓ Branch 1 taken 129083 times.
|
209787 | if( (max2 < lower_bound_1) ) |
| 90 | { | ||
| 91 | 80704 | lower_bound_1 = max2; | |
| 92 | } | ||
| 93 | else | ||
| 94 | { | ||
| 95 |
2/2✓ Branch 0 taken 128225 times.
✓ Branch 1 taken 858 times.
|
129083 | if( (max2 > upper_bound_1) ) |
| 96 | { | ||
| 97 | 128225 | upper_bound_1 = max2; | |
| 98 | } | ||
| 99 | } | ||
| 100 |
2/2✓ Branch 0 taken 35072 times.
✓ Branch 1 taken 174715 times.
|
209787 | if( (max3 < lower_bound_1) ) |
| 101 | { | ||
| 102 | 35072 | lower_bound_1 = max3; | |
| 103 | } | ||
| 104 | else | ||
| 105 | { | ||
| 106 |
2/2✓ Branch 0 taken 33235 times.
✓ Branch 1 taken 141480 times.
|
174715 | if( (max3 > upper_bound_1) ) |
| 107 | { | ||
| 108 | 33235 | upper_bound_1 = max3; | |
| 109 | } | ||
| 110 | } | ||
| 111 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 209787 times.
|
209787 | 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 209787 times.
|
209787 | if( (upper_bound_1 > 7.23700557733225980357e+75) ) |
| 118 | { | ||
| 119 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 120 | } | ||
| 121 | 209787 | eps = (5.11071278299732992696e-15 * ((max2 * max3) * max1)); | |
| 122 |
1/2✓ Branch 0 taken 209787 times.
✗ Branch 1 not taken.
|
209787 | if( (Delta4 > eps) ) |
| 123 | { | ||
| 124 | 209787 | 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 | 209787 | Delta4_sign = int_tmp_result; | |
| 139 | int int_tmp_result_FFWKCAA; | ||
| 140 | 209787 | double max4 = max1; | |
| 141 |
2/2✓ Branch 0 taken 28655 times.
✓ Branch 1 taken 181132 times.
|
209787 | if( (max4 < fabs(a41)) ) |
| 142 | { | ||
| 143 | 28655 | max4 = fabs(a41); | |
| 144 | } | ||
| 145 | 209787 | double max5 = max2; | |
| 146 |
2/2✓ Branch 0 taken 54070 times.
✓ Branch 1 taken 155717 times.
|
209787 | if( (max5 < max3) ) |
| 147 | { | ||
| 148 | 54070 | max5 = max3; | |
| 149 | } | ||
| 150 | 209787 | double max6 = fabs(a14); | |
| 151 |
2/2✓ Branch 0 taken 100621 times.
✓ Branch 1 taken 109166 times.
|
209787 | if( (max6 < fabs(a24)) ) |
| 152 | { | ||
| 153 | 100621 | max6 = fabs(a24); | |
| 154 | } | ||
| 155 |
2/2✓ Branch 0 taken 73791 times.
✓ Branch 1 taken 135996 times.
|
209787 | if( (max6 < fabs(a34)) ) |
| 156 | { | ||
| 157 | 73791 | max6 = fabs(a34); | |
| 158 | } | ||
| 159 |
2/2✓ Branch 0 taken 34804 times.
✓ Branch 1 taken 174983 times.
|
209787 | if( (max6 < fabs(a44)) ) |
| 160 | { | ||
| 161 | 34804 | max6 = fabs(a44); | |
| 162 | } | ||
| 163 | 209787 | double max7 = max3; | |
| 164 |
2/2✓ Branch 0 taken 22917 times.
✓ Branch 1 taken 186870 times.
|
209787 | if( (max7 < fabs(a42)) ) |
| 165 | { | ||
| 166 | 22917 | max7 = fabs(a42); | |
| 167 | } | ||
| 168 |
2/2✓ Branch 0 taken 15720 times.
✓ Branch 1 taken 194067 times.
|
209787 | if( (max7 < fabs(a43)) ) |
| 169 | { | ||
| 170 | 15720 | max7 = fabs(a43); | |
| 171 | } | ||
| 172 | 209787 | lower_bound_1 = max4; | |
| 173 | 209787 | upper_bound_1 = max4; | |
| 174 |
2/2✓ Branch 0 taken 71072 times.
✓ Branch 1 taken 138715 times.
|
209787 | if( (max5 < lower_bound_1) ) |
| 175 | { | ||
| 176 | 71072 | lower_bound_1 = max5; | |
| 177 | } | ||
| 178 | else | ||
| 179 | { | ||
| 180 |
2/2✓ Branch 0 taken 137571 times.
✓ Branch 1 taken 1144 times.
|
138715 | if( (max5 > upper_bound_1) ) |
| 181 | { | ||
| 182 | 137571 | upper_bound_1 = max5; | |
| 183 | } | ||
| 184 | } | ||
| 185 |
2/2✓ Branch 0 taken 10384 times.
✓ Branch 1 taken 199403 times.
|
209787 | if( (max6 < lower_bound_1) ) |
| 186 | { | ||
| 187 | 10384 | lower_bound_1 = max6; | |
| 188 | } | ||
| 189 | else | ||
| 190 | { | ||
| 191 |
2/2✓ Branch 0 taken 164361 times.
✓ Branch 1 taken 35042 times.
|
199403 | if( (max6 > upper_bound_1) ) |
| 192 | { | ||
| 193 | 164361 | upper_bound_1 = max6; | |
| 194 | } | ||
| 195 | } | ||
| 196 |
2/2✓ Branch 0 taken 25170 times.
✓ Branch 1 taken 184617 times.
|
209787 | if( (max7 < lower_bound_1) ) |
| 197 | { | ||
| 198 | 25170 | lower_bound_1 = max7; | |
| 199 | } | ||
| 200 | else | ||
| 201 | { | ||
| 202 |
2/2✓ Branch 0 taken 3145 times.
✓ Branch 1 taken 181472 times.
|
184617 | if( (max7 > upper_bound_1) ) |
| 203 | { | ||
| 204 | 3145 | upper_bound_1 = max7; | |
| 205 | } | ||
| 206 | } | ||
| 207 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 209787 times.
|
209787 | 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 209787 times.
|
209787 | if( (upper_bound_1 > 7.23700557733225980357e+75) ) |
| 214 | { | ||
| 215 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 216 | } | ||
| 217 | 209787 | eps = (3.17768858673611390687e-14 * (((max5 * max7) * max4) * max6)); | |
| 218 |
2/2✓ Branch 0 taken 63790 times.
✓ Branch 1 taken 145997 times.
|
209787 | if( (r > eps) ) |
| 219 | { | ||
| 220 | 63790 | int_tmp_result_FFWKCAA = 1; | |
| 221 | } | ||
| 222 | else | ||
| 223 | { | ||
| 224 |
2/2✓ Branch 0 taken 140735 times.
✓ Branch 1 taken 5262 times.
|
145997 | if( (r < -eps) ) |
| 225 | { | ||
| 226 | 140735 | int_tmp_result_FFWKCAA = -1; | |
| 227 | } | ||
| 228 | else | ||
| 229 | { | ||
| 230 | 5262 | return FPG_UNCERTAIN_VALUE; | |
| 231 | } | ||
| 232 | } | ||
| 233 | } | ||
| 234 | 204525 | return (Delta4_sign * int_tmp_result_FFWKCAA); | |
| 235 | } | ||
| 236 |