| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /* Automatically generated code, do not edit */ | ||
| 2 | /* Generated from source file: det3d.pck */ | ||
| 3 | |||
| 4 | 145176 | inline int det_3d_filter( const double* p0, const double* p1, const double* p2) { | |
| 5 | double Delta; | ||
| 6 | 145176 | Delta = (((p0[0] * ((p1[1] * p2[2]) - (p1[2] * p2[1]))) - (p1[0] * ((p0[1] * p2[2]) - (p0[2] * p2[1])))) + (p2[0] * ((p0[1] * p1[2]) - (p0[2] * p1[1])))); | |
| 7 | int int_tmp_result; | ||
| 8 | double eps; | ||
| 9 | 145176 | double max1 = fabs(p0[0]); | |
| 10 |
2/2✓ Branch 0 taken 28414 times.
✓ Branch 1 taken 116762 times.
|
145176 | if( (max1 < fabs(p1[0])) ) |
| 11 | { | ||
| 12 | 28414 | max1 = fabs(p1[0]); | |
| 13 | } | ||
| 14 |
2/2✓ Branch 0 taken 24094 times.
✓ Branch 1 taken 121082 times.
|
145176 | if( (max1 < fabs(p2[0])) ) |
| 15 | { | ||
| 16 | 24094 | max1 = fabs(p2[0]); | |
| 17 | } | ||
| 18 | 145176 | double max2 = fabs(p0[1]); | |
| 19 |
2/2✓ Branch 0 taken 63744 times.
✓ Branch 1 taken 81432 times.
|
145176 | if( (max2 < fabs(p0[2])) ) |
| 20 | { | ||
| 21 | 63744 | max2 = fabs(p0[2]); | |
| 22 | } | ||
| 23 |
2/2✓ Branch 0 taken 17000 times.
✓ Branch 1 taken 128176 times.
|
145176 | if( (max2 < fabs(p1[1])) ) |
| 24 | { | ||
| 25 | 17000 | max2 = fabs(p1[1]); | |
| 26 | } | ||
| 27 |
2/2✓ Branch 0 taken 5578 times.
✓ Branch 1 taken 139598 times.
|
145176 | if( (max2 < fabs(p1[2])) ) |
| 28 | { | ||
| 29 | 5578 | max2 = fabs(p1[2]); | |
| 30 | } | ||
| 31 | 145176 | double max3 = fabs(p1[1]); | |
| 32 |
2/2✓ Branch 0 taken 63744 times.
✓ Branch 1 taken 81432 times.
|
145176 | if( (max3 < fabs(p1[2])) ) |
| 33 | { | ||
| 34 | 63744 | max3 = fabs(p1[2]); | |
| 35 | } | ||
| 36 |
2/2✓ Branch 0 taken 24872 times.
✓ Branch 1 taken 120304 times.
|
145176 | if( (max3 < fabs(p2[1])) ) |
| 37 | { | ||
| 38 | 24872 | max3 = fabs(p2[1]); | |
| 39 | } | ||
| 40 |
2/2✓ Branch 0 taken 10460 times.
✓ Branch 1 taken 134716 times.
|
145176 | if( (max3 < fabs(p2[2])) ) |
| 41 | { | ||
| 42 | 10460 | max3 = fabs(p2[2]); | |
| 43 | } | ||
| 44 | double lower_bound_1; | ||
| 45 | double upper_bound_1; | ||
| 46 | 145176 | lower_bound_1 = max1; | |
| 47 | 145176 | upper_bound_1 = max1; | |
| 48 |
2/2✓ Branch 0 taken 59812 times.
✓ Branch 1 taken 85364 times.
|
145176 | if( (max2 < lower_bound_1) ) |
| 49 | { | ||
| 50 | 59812 | lower_bound_1 = max2; | |
| 51 | } | ||
| 52 | else | ||
| 53 | { | ||
| 54 |
2/2✓ Branch 0 taken 75602 times.
✓ Branch 1 taken 9762 times.
|
85364 | if( (max2 > upper_bound_1) ) |
| 55 | { | ||
| 56 | 75602 | upper_bound_1 = max2; | |
| 57 | } | ||
| 58 | } | ||
| 59 |
2/2✓ Branch 0 taken 6728 times.
✓ Branch 1 taken 138448 times.
|
145176 | if( (max3 < lower_bound_1) ) |
| 60 | { | ||
| 61 | 6728 | lower_bound_1 = max3; | |
| 62 | } | ||
| 63 | else | ||
| 64 | { | ||
| 65 |
2/2✓ Branch 0 taken 9058 times.
✓ Branch 1 taken 129390 times.
|
138448 | if( (max3 > upper_bound_1) ) |
| 66 | { | ||
| 67 | 9058 | upper_bound_1 = max3; | |
| 68 | } | ||
| 69 | } | ||
| 70 |
2/2✓ Branch 0 taken 904 times.
✓ Branch 1 taken 144272 times.
|
145176 | if( (lower_bound_1 < 1.92663387981871579179e-98) ) |
| 71 | { | ||
| 72 | 904 | return FPG_UNCERTAIN_VALUE; | |
| 73 | } | ||
| 74 | else | ||
| 75 | { | ||
| 76 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 144272 times.
|
144272 | if( (upper_bound_1 > 1.11987237108890185662e+102) ) |
| 77 | { | ||
| 78 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 79 | } | ||
| 80 | 144272 | eps = (3.11133555671680765034e-15 * ((max2 * max3) * max1)); | |
| 81 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 144272 times.
|
144272 | if( (Delta > eps) ) |
| 82 | { | ||
| 83 | ✗ | int_tmp_result = 1; | |
| 84 | } | ||
| 85 | else | ||
| 86 | { | ||
| 87 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 144272 times.
|
144272 | if( (Delta < -eps) ) |
| 88 | { | ||
| 89 | ✗ | int_tmp_result = -1; | |
| 90 | } | ||
| 91 | else | ||
| 92 | { | ||
| 93 | 144272 | return FPG_UNCERTAIN_VALUE; | |
| 94 | } | ||
| 95 | } | ||
| 96 | } | ||
| 97 | ✗ | return int_tmp_result; | |
| 98 | } | ||
| 99 |