Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #include <stdint.h>
00028 #include <stdlib.h>
00029 #include "cvWrapper.h"
00030 #include "oast9_16.h"
00031
00032 using namespace std;
00033 using namespace agast;
00034
00035 void OastDetector9_16::detect(const unsigned char* im, vector<CvPoint>& corners_all)
00036 {
00037 int total=0;
00038 int nExpectedCorners=corners_all.capacity();
00039 CvPoint h;
00040 register int x, y;
00041 register int xsizeB=xsize - 4;
00042 register int ysizeB=ysize - 3;
00043 register int_fast16_t offset0, offset1, offset2, offset3, offset4, offset5, offset6, offset7, offset8, offset9, offset10, offset11, offset12, offset13, offset14, offset15;
00044 register int width;
00045
00046 corners_all.resize(0);
00047
00048 offset0=s_offset0;
00049 offset1=s_offset1;
00050 offset2=s_offset2;
00051 offset3=s_offset3;
00052 offset4=s_offset4;
00053 offset5=s_offset5;
00054 offset6=s_offset6;
00055 offset7=s_offset7;
00056 offset8=s_offset8;
00057 offset9=s_offset9;
00058 offset10=s_offset10;
00059 offset11=s_offset11;
00060 offset12=s_offset12;
00061 offset13=s_offset13;
00062 offset14=s_offset14;
00063 offset15=s_offset15;
00064 width=xsize;
00065
00066 for(y=3; y < ysizeB; y++)
00067 {
00068 x=2;
00069 while(1)
00070 {
00071 x++;
00072 if(x>xsizeB)
00073 break;
00074 else
00075 {
00076 register const unsigned char* const p = im + y*width + x;
00077 register const int cb = *p + b;
00078 register const int c_b = *p - b;
00079 if(p[offset0] > cb)
00080 if(p[offset2] > cb)
00081 if(p[offset4] > cb)
00082 if(p[offset5] > cb)
00083 if(p[offset7] > cb)
00084 if(p[offset3] > cb)
00085 if(p[offset1] > cb)
00086 if(p[offset6] > cb)
00087 if(p[offset8] > cb)
00088 {}
00089 else
00090 if(p[offset15] > cb)
00091 {}
00092 else
00093 continue;
00094 else
00095 if(p[offset13] > cb)
00096 if(p[offset14] > cb)
00097 if(p[offset15] > cb)
00098 {}
00099 else
00100 continue;
00101 else
00102 continue;
00103 else
00104 continue;
00105 else
00106 if(p[offset8] > cb)
00107 if(p[offset9] > cb)
00108 if(p[offset10] > cb)
00109 if(p[offset6] > cb)
00110 {}
00111 else
00112 if(p[offset11] > cb)
00113 if(p[offset12] > cb)
00114 if(p[offset13] > cb)
00115 if(p[offset14] > cb)
00116 if(p[offset15] > cb)
00117 {}
00118 else
00119 continue;
00120 else
00121 continue;
00122 else
00123 continue;
00124 else
00125 continue;
00126 else
00127 continue;
00128 else
00129 continue;
00130 else
00131 continue;
00132 else
00133 continue;
00134 else
00135 if(p[offset10] > cb)
00136 if(p[offset11] > cb)
00137 if(p[offset12] > cb)
00138 if(p[offset8] > cb)
00139 if(p[offset9] > cb)
00140 if(p[offset6] > cb)
00141 {}
00142 else
00143 if(p[offset13] > cb)
00144 if(p[offset14] > cb)
00145 if(p[offset15] > cb)
00146 {}
00147 else
00148 continue;
00149 else
00150 continue;
00151 else
00152 continue;
00153 else
00154 if(p[offset1] > cb)
00155 if(p[offset13] > cb)
00156 if(p[offset14] > cb)
00157 if(p[offset15] > cb)
00158 {}
00159 else
00160 continue;
00161 else
00162 continue;
00163 else
00164 continue;
00165 else
00166 continue;
00167 else
00168 if(p[offset1] > cb)
00169 if(p[offset13] > cb)
00170 if(p[offset14] > cb)
00171 if(p[offset15] > cb)
00172 {}
00173 else
00174 continue;
00175 else
00176 continue;
00177 else
00178 continue;
00179 else
00180 continue;
00181 else
00182 continue;
00183 else
00184 continue;
00185 else
00186 continue;
00187 else if(p[offset7] < c_b)
00188 if(p[offset14] > cb)
00189 if(p[offset15] > cb)
00190 if(p[offset1] > cb)
00191 if(p[offset3] > cb)
00192 if(p[offset6] > cb)
00193 {}
00194 else
00195 if(p[offset13] > cb)
00196 {}
00197 else
00198 continue;
00199 else
00200 if(p[offset10] > cb)
00201 if(p[offset11] > cb)
00202 if(p[offset12] > cb)
00203 if(p[offset13] > cb)
00204 {}
00205 else
00206 continue;
00207 else
00208 continue;
00209 else
00210 continue;
00211 else
00212 continue;
00213 else
00214 if(p[offset8] > cb)
00215 if(p[offset9] > cb)
00216 if(p[offset10] > cb)
00217 if(p[offset11] > cb)
00218 if(p[offset12] > cb)
00219 if(p[offset13] > cb)
00220 {}
00221 else
00222 continue;
00223 else
00224 continue;
00225 else
00226 continue;
00227 else
00228 continue;
00229 else
00230 continue;
00231 else
00232 continue;
00233 else
00234 continue;
00235 else if(p[offset14] < c_b)
00236 if(p[offset8] < c_b)
00237 if(p[offset9] < c_b)
00238 if(p[offset10] < c_b)
00239 if(p[offset11] < c_b)
00240 if(p[offset12] < c_b)
00241 if(p[offset13] < c_b)
00242 if(p[offset6] < c_b)
00243 {}
00244 else
00245 if(p[offset15] < c_b)
00246 {}
00247 else
00248 continue;
00249 else
00250 continue;
00251 else
00252 continue;
00253 else
00254 continue;
00255 else
00256 continue;
00257 else
00258 continue;
00259 else
00260 continue;
00261 else
00262 continue;
00263 else
00264 if(p[offset14] > cb)
00265 if(p[offset15] > cb)
00266 if(p[offset1] > cb)
00267 if(p[offset3] > cb)
00268 if(p[offset6] > cb)
00269 {}
00270 else
00271 if(p[offset13] > cb)
00272 {}
00273 else
00274 continue;
00275 else
00276 if(p[offset10] > cb)
00277 if(p[offset11] > cb)
00278 if(p[offset12] > cb)
00279 if(p[offset13] > cb)
00280 {}
00281 else
00282 continue;
00283 else
00284 continue;
00285 else
00286 continue;
00287 else
00288 continue;
00289 else
00290 if(p[offset8] > cb)
00291 if(p[offset9] > cb)
00292 if(p[offset10] > cb)
00293 if(p[offset11] > cb)
00294 if(p[offset12] > cb)
00295 if(p[offset13] > cb)
00296 {}
00297 else
00298 continue;
00299 else
00300 continue;
00301 else
00302 continue;
00303 else
00304 continue;
00305 else
00306 continue;
00307 else
00308 continue;
00309 else
00310 continue;
00311 else
00312 continue;
00313 else if(p[offset5] < c_b)
00314 if(p[offset12] > cb)
00315 if(p[offset13] > cb)
00316 if(p[offset14] > cb)
00317 if(p[offset15] > cb)
00318 if(p[offset1] > cb)
00319 if(p[offset3] > cb)
00320 {}
00321 else
00322 if(p[offset10] > cb)
00323 if(p[offset11] > cb)
00324 {}
00325 else
00326 continue;
00327 else
00328 continue;
00329 else
00330 if(p[offset8] > cb)
00331 if(p[offset9] > cb)
00332 if(p[offset10] > cb)
00333 if(p[offset11] > cb)
00334 {}
00335 else
00336 continue;
00337 else
00338 continue;
00339 else
00340 continue;
00341 else
00342 continue;
00343 else
00344 if(p[offset6] > cb)
00345 if(p[offset7] > cb)
00346 if(p[offset8] > cb)
00347 if(p[offset9] > cb)
00348 if(p[offset10] > cb)
00349 if(p[offset11] > cb)
00350 {}
00351 else
00352 continue;
00353 else
00354 continue;
00355 else
00356 continue;
00357 else
00358 continue;
00359 else
00360 continue;
00361 else
00362 continue;
00363 else
00364 continue;
00365 else
00366 continue;
00367 else if(p[offset12] < c_b)
00368 if(p[offset7] < c_b)
00369 if(p[offset8] < c_b)
00370 if(p[offset9] < c_b)
00371 if(p[offset10] < c_b)
00372 if(p[offset11] < c_b)
00373 if(p[offset13] < c_b)
00374 if(p[offset6] < c_b)
00375 {}
00376 else
00377 if(p[offset14] < c_b)
00378 if(p[offset15] < c_b)
00379 {}
00380 else
00381 continue;
00382 else
00383 continue;
00384 else
00385 continue;
00386 else
00387 continue;
00388 else
00389 continue;
00390 else
00391 continue;
00392 else
00393 continue;
00394 else
00395 continue;
00396 else
00397 continue;
00398 else
00399 if(p[offset12] > cb)
00400 if(p[offset13] > cb)
00401 if(p[offset14] > cb)
00402 if(p[offset15] > cb)
00403 if(p[offset1] > cb)
00404 if(p[offset3] > cb)
00405 {}
00406 else
00407 if(p[offset10] > cb)
00408 if(p[offset11] > cb)
00409 {}
00410 else
00411 continue;
00412 else
00413 continue;
00414 else
00415 if(p[offset8] > cb)
00416 if(p[offset9] > cb)
00417 if(p[offset10] > cb)
00418 if(p[offset11] > cb)
00419 {}
00420 else
00421 continue;
00422 else
00423 continue;
00424 else
00425 continue;
00426 else
00427 continue;
00428 else
00429 if(p[offset6] > cb)
00430 if(p[offset7] > cb)
00431 if(p[offset8] > cb)
00432 if(p[offset9] > cb)
00433 if(p[offset10] > cb)
00434 if(p[offset11] > cb)
00435 {}
00436 else
00437 continue;
00438 else
00439 continue;
00440 else
00441 continue;
00442 else
00443 continue;
00444 else
00445 continue;
00446 else
00447 continue;
00448 else
00449 continue;
00450 else
00451 continue;
00452 else if(p[offset12] < c_b)
00453 if(p[offset7] < c_b)
00454 if(p[offset8] < c_b)
00455 if(p[offset9] < c_b)
00456 if(p[offset10] < c_b)
00457 if(p[offset11] < c_b)
00458 if(p[offset13] < c_b)
00459 if(p[offset14] < c_b)
00460 if(p[offset6] < c_b)
00461 {}
00462 else
00463 if(p[offset15] < c_b)
00464 {}
00465 else
00466 continue;
00467 else
00468 continue;
00469 else
00470 continue;
00471 else
00472 continue;
00473 else
00474 continue;
00475 else
00476 continue;
00477 else
00478 continue;
00479 else
00480 continue;
00481 else
00482 continue;
00483 else if(p[offset4] < c_b)
00484 if(p[offset11] > cb)
00485 if(p[offset12] > cb)
00486 if(p[offset13] > cb)
00487 if(p[offset10] > cb)
00488 if(p[offset14] > cb)
00489 if(p[offset15] > cb)
00490 if(p[offset1] > cb)
00491 {}
00492 else
00493 if(p[offset8] > cb)
00494 if(p[offset9] > cb)
00495 {}
00496 else
00497 continue;
00498 else
00499 continue;
00500 else
00501 if(p[offset6] > cb)
00502 if(p[offset7] > cb)
00503 if(p[offset8] > cb)
00504 if(p[offset9] > cb)
00505 {}
00506 else
00507 continue;
00508 else
00509 continue;
00510 else
00511 continue;
00512 else
00513 continue;
00514 else
00515 if(p[offset5] > cb)
00516 if(p[offset6] > cb)
00517 if(p[offset7] > cb)
00518 if(p[offset8] > cb)
00519 if(p[offset9] > cb)
00520 {}
00521 else
00522 continue;
00523 else
00524 continue;
00525 else
00526 continue;
00527 else
00528 continue;
00529 else
00530 continue;
00531 else
00532 if(p[offset1] > cb)
00533 if(p[offset3] > cb)
00534 if(p[offset14] > cb)
00535 if(p[offset15] > cb)
00536 {}
00537 else
00538 continue;
00539 else
00540 continue;
00541 else
00542 continue;
00543 else
00544 continue;
00545 else
00546 continue;
00547 else
00548 continue;
00549 else if(p[offset11] < c_b)
00550 if(p[offset7] < c_b)
00551 if(p[offset8] < c_b)
00552 if(p[offset9] < c_b)
00553 if(p[offset10] < c_b)
00554 if(p[offset6] < c_b)
00555 if(p[offset5] < c_b)
00556 if(p[offset3] < c_b)
00557 {}
00558 else
00559 if(p[offset12] < c_b)
00560 {}
00561 else
00562 continue;
00563 else
00564 if(p[offset12] < c_b)
00565 if(p[offset13] < c_b)
00566 if(p[offset14] < c_b)
00567 {}
00568 else
00569 continue;
00570 else
00571 continue;
00572 else
00573 continue;
00574 else
00575 if(p[offset12] < c_b)
00576 if(p[offset13] < c_b)
00577 if(p[offset14] < c_b)
00578 if(p[offset15] < c_b)
00579 {}
00580 else
00581 continue;
00582 else
00583 continue;
00584 else
00585 continue;
00586 else
00587 continue;
00588 else
00589 continue;
00590 else
00591 continue;
00592 else
00593 continue;
00594 else
00595 continue;
00596 else
00597 continue;
00598 else
00599 if(p[offset11] > cb)
00600 if(p[offset12] > cb)
00601 if(p[offset13] > cb)
00602 if(p[offset10] > cb)
00603 if(p[offset14] > cb)
00604 if(p[offset15] > cb)
00605 if(p[offset1] > cb)
00606 {}
00607 else
00608 if(p[offset8] > cb)
00609 if(p[offset9] > cb)
00610 {}
00611 else
00612 continue;
00613 else
00614 continue;
00615 else
00616 if(p[offset6] > cb)
00617 if(p[offset7] > cb)
00618 if(p[offset8] > cb)
00619 if(p[offset9] > cb)
00620 {}
00621 else
00622 continue;
00623 else
00624 continue;
00625 else
00626 continue;
00627 else
00628 continue;
00629 else
00630 if(p[offset5] > cb)
00631 if(p[offset6] > cb)
00632 if(p[offset7] > cb)
00633 if(p[offset8] > cb)
00634 if(p[offset9] > cb)
00635 {}
00636 else
00637 continue;
00638 else
00639 continue;
00640 else
00641 continue;
00642 else
00643 continue;
00644 else
00645 continue;
00646 else
00647 if(p[offset1] > cb)
00648 if(p[offset3] > cb)
00649 if(p[offset14] > cb)
00650 if(p[offset15] > cb)
00651 {}
00652 else
00653 continue;
00654 else
00655 continue;
00656 else
00657 continue;
00658 else
00659 continue;
00660 else
00661 continue;
00662 else
00663 continue;
00664 else if(p[offset11] < c_b)
00665 if(p[offset7] < c_b)
00666 if(p[offset8] < c_b)
00667 if(p[offset9] < c_b)
00668 if(p[offset10] < c_b)
00669 if(p[offset12] < c_b)
00670 if(p[offset13] < c_b)
00671 if(p[offset6] < c_b)
00672 if(p[offset5] < c_b)
00673 {}
00674 else
00675 if(p[offset14] < c_b)
00676 {}
00677 else
00678 continue;
00679 else
00680 if(p[offset14] < c_b)
00681 if(p[offset15] < c_b)
00682 {}
00683 else
00684 continue;
00685 else
00686 continue;
00687 else
00688 continue;
00689 else
00690 continue;
00691 else
00692 continue;
00693 else
00694 continue;
00695 else
00696 continue;
00697 else
00698 continue;
00699 else
00700 continue;
00701 else if(p[offset2] < c_b)
00702 if(p[offset9] > cb)
00703 if(p[offset10] > cb)
00704 if(p[offset11] > cb)
00705 if(p[offset8] > cb)
00706 if(p[offset12] > cb)
00707 if(p[offset13] > cb)
00708 if(p[offset14] > cb)
00709 if(p[offset15] > cb)
00710 {}
00711 else
00712 if(p[offset6] > cb)
00713 if(p[offset7] > cb)
00714 {}
00715 else
00716 continue;
00717 else
00718 continue;
00719 else
00720 if(p[offset5] > cb)
00721 if(p[offset6] > cb)
00722 if(p[offset7] > cb)
00723 {}
00724 else
00725 continue;
00726 else
00727 continue;
00728 else
00729 continue;
00730 else
00731 if(p[offset4] > cb)
00732 if(p[offset5] > cb)
00733 if(p[offset6] > cb)
00734 if(p[offset7] > cb)
00735 {}
00736 else
00737 continue;
00738 else
00739 continue;
00740 else
00741 continue;
00742 else
00743 continue;
00744 else
00745 if(p[offset3] > cb)
00746 if(p[offset4] > cb)
00747 if(p[offset5] > cb)
00748 if(p[offset6] > cb)
00749 if(p[offset7] > cb)
00750 {}
00751 else
00752 continue;
00753 else
00754 continue;
00755 else
00756 continue;
00757 else
00758 continue;
00759 else
00760 continue;
00761 else
00762 if(p[offset1] > cb)
00763 if(p[offset12] > cb)
00764 if(p[offset13] > cb)
00765 if(p[offset14] > cb)
00766 if(p[offset15] > cb)
00767 {}
00768 else
00769 continue;
00770 else
00771 continue;
00772 else
00773 continue;
00774 else
00775 continue;
00776 else
00777 continue;
00778 else
00779 continue;
00780 else
00781 continue;
00782 else if(p[offset9] < c_b)
00783 if(p[offset7] < c_b)
00784 if(p[offset8] < c_b)
00785 if(p[offset6] < c_b)
00786 if(p[offset5] < c_b)
00787 if(p[offset4] < c_b)
00788 if(p[offset3] < c_b)
00789 if(p[offset1] < c_b)
00790 {}
00791 else
00792 if(p[offset10] < c_b)
00793 {}
00794 else
00795 continue;
00796 else
00797 if(p[offset10] < c_b)
00798 if(p[offset11] < c_b)
00799 if(p[offset12] < c_b)
00800 {}
00801 else
00802 continue;
00803 else
00804 continue;
00805 else
00806 continue;
00807 else
00808 if(p[offset10] < c_b)
00809 if(p[offset11] < c_b)
00810 if(p[offset12] < c_b)
00811 if(p[offset13] < c_b)
00812 {}
00813 else
00814 continue;
00815 else
00816 continue;
00817 else
00818 continue;
00819 else
00820 continue;
00821 else
00822 if(p[offset10] < c_b)
00823 if(p[offset11] < c_b)
00824 if(p[offset12] < c_b)
00825 if(p[offset13] < c_b)
00826 if(p[offset14] < c_b)
00827 {}
00828 else
00829 continue;
00830 else
00831 continue;
00832 else
00833 continue;
00834 else
00835 continue;
00836 else
00837 continue;
00838 else
00839 if(p[offset10] < c_b)
00840 if(p[offset11] < c_b)
00841 if(p[offset12] < c_b)
00842 if(p[offset13] < c_b)
00843 if(p[offset14] < c_b)
00844 if(p[offset15] < c_b)
00845 {}
00846 else
00847 continue;
00848 else
00849 continue;
00850 else
00851 continue;
00852 else
00853 continue;
00854 else
00855 continue;
00856 else
00857 continue;
00858 else
00859 continue;
00860 else
00861 continue;
00862 else
00863 continue;
00864 else
00865 if(p[offset9] > cb)
00866 if(p[offset10] > cb)
00867 if(p[offset11] > cb)
00868 if(p[offset8] > cb)
00869 if(p[offset12] > cb)
00870 if(p[offset13] > cb)
00871 if(p[offset14] > cb)
00872 if(p[offset15] > cb)
00873 {}
00874 else
00875 if(p[offset6] > cb)
00876 if(p[offset7] > cb)
00877 {}
00878 else
00879 continue;
00880 else
00881 continue;
00882 else
00883 if(p[offset5] > cb)
00884 if(p[offset6] > cb)
00885 if(p[offset7] > cb)
00886 {}
00887 else
00888 continue;
00889 else
00890 continue;
00891 else
00892 continue;
00893 else
00894 if(p[offset4] > cb)
00895 if(p[offset5] > cb)
00896 if(p[offset6] > cb)
00897 if(p[offset7] > cb)
00898 {}
00899 else
00900 continue;
00901 else
00902 continue;
00903 else
00904 continue;
00905 else
00906 continue;
00907 else
00908 if(p[offset3] > cb)
00909 if(p[offset4] > cb)
00910 if(p[offset5] > cb)
00911 if(p[offset6] > cb)
00912 if(p[offset7] > cb)
00913 {}
00914 else
00915 continue;
00916 else
00917 continue;
00918 else
00919 continue;
00920 else
00921 continue;
00922 else
00923 continue;
00924 else
00925 if(p[offset1] > cb)
00926 if(p[offset12] > cb)
00927 if(p[offset13] > cb)
00928 if(p[offset14] > cb)
00929 if(p[offset15] > cb)
00930 {}
00931 else
00932 continue;
00933 else
00934 continue;
00935 else
00936 continue;
00937 else
00938 continue;
00939 else
00940 continue;
00941 else
00942 continue;
00943 else
00944 continue;
00945 else if(p[offset9] < c_b)
00946 if(p[offset7] < c_b)
00947 if(p[offset8] < c_b)
00948 if(p[offset10] < c_b)
00949 if(p[offset11] < c_b)
00950 if(p[offset6] < c_b)
00951 if(p[offset5] < c_b)
00952 if(p[offset4] < c_b)
00953 if(p[offset3] < c_b)
00954 {}
00955 else
00956 if(p[offset12] < c_b)
00957 {}
00958 else
00959 continue;
00960 else
00961 if(p[offset12] < c_b)
00962 if(p[offset13] < c_b)
00963 {}
00964 else
00965 continue;
00966 else
00967 continue;
00968 else
00969 if(p[offset12] < c_b)
00970 if(p[offset13] < c_b)
00971 if(p[offset14] < c_b)
00972 {}
00973 else
00974 continue;
00975 else
00976 continue;
00977 else
00978 continue;
00979 else
00980 if(p[offset12] < c_b)
00981 if(p[offset13] < c_b)
00982 if(p[offset14] < c_b)
00983 if(p[offset15] < c_b)
00984 {}
00985 else
00986 continue;
00987 else
00988 continue;
00989 else
00990 continue;
00991 else
00992 continue;
00993 else
00994 continue;
00995 else
00996 continue;
00997 else
00998 continue;
00999 else
01000 continue;
01001 else
01002 continue;
01003 else if(p[offset0] < c_b)
01004 if(p[offset2] > cb)
01005 if(p[offset9] > cb)
01006 if(p[offset7] > cb)
01007 if(p[offset8] > cb)
01008 if(p[offset6] > cb)
01009 if(p[offset5] > cb)
01010 if(p[offset4] > cb)
01011 if(p[offset3] > cb)
01012 if(p[offset1] > cb)
01013 {}
01014 else
01015 if(p[offset10] > cb)
01016 {}
01017 else
01018 continue;
01019 else
01020 if(p[offset10] > cb)
01021 if(p[offset11] > cb)
01022 if(p[offset12] > cb)
01023 {}
01024 else
01025 continue;
01026 else
01027 continue;
01028 else
01029 continue;
01030 else
01031 if(p[offset10] > cb)
01032 if(p[offset11] > cb)
01033 if(p[offset12] > cb)
01034 if(p[offset13] > cb)
01035 {}
01036 else
01037 continue;
01038 else
01039 continue;
01040 else
01041 continue;
01042 else
01043 continue;
01044 else
01045 if(p[offset10] > cb)
01046 if(p[offset11] > cb)
01047 if(p[offset12] > cb)
01048 if(p[offset13] > cb)
01049 if(p[offset14] > cb)
01050 {}
01051 else
01052 continue;
01053 else
01054 continue;
01055 else
01056 continue;
01057 else
01058 continue;
01059 else
01060 continue;
01061 else
01062 if(p[offset10] > cb)
01063 if(p[offset11] > cb)
01064 if(p[offset12] > cb)
01065 if(p[offset13] > cb)
01066 if(p[offset14] > cb)
01067 if(p[offset15] > cb)
01068 {}
01069 else
01070 continue;
01071 else
01072 continue;
01073 else
01074 continue;
01075 else
01076 continue;
01077 else
01078 continue;
01079 else
01080 continue;
01081 else
01082 continue;
01083 else
01084 continue;
01085 else if(p[offset9] < c_b)
01086 if(p[offset10] < c_b)
01087 if(p[offset11] < c_b)
01088 if(p[offset8] < c_b)
01089 if(p[offset12] < c_b)
01090 if(p[offset13] < c_b)
01091 if(p[offset14] < c_b)
01092 if(p[offset15] < c_b)
01093 {}
01094 else
01095 if(p[offset6] < c_b)
01096 if(p[offset7] < c_b)
01097 {}
01098 else
01099 continue;
01100 else
01101 continue;
01102 else
01103 if(p[offset5] < c_b)
01104 if(p[offset6] < c_b)
01105 if(p[offset7] < c_b)
01106 {}
01107 else
01108 continue;
01109 else
01110 continue;
01111 else
01112 continue;
01113 else
01114 if(p[offset4] < c_b)
01115 if(p[offset5] < c_b)
01116 if(p[offset6] < c_b)
01117 if(p[offset7] < c_b)
01118 {}
01119 else
01120 continue;
01121 else
01122 continue;
01123 else
01124 continue;
01125 else
01126 continue;
01127 else
01128 if(p[offset3] < c_b)
01129 if(p[offset4] < c_b)
01130 if(p[offset5] < c_b)
01131 if(p[offset6] < c_b)
01132 if(p[offset7] < c_b)
01133 {}
01134 else
01135 continue;
01136 else
01137 continue;
01138 else
01139 continue;
01140 else
01141 continue;
01142 else
01143 continue;
01144 else
01145 if(p[offset1] < c_b)
01146 if(p[offset12] < c_b)
01147 if(p[offset13] < c_b)
01148 if(p[offset14] < c_b)
01149 if(p[offset15] < c_b)
01150 {}
01151 else
01152 continue;
01153 else
01154 continue;
01155 else
01156 continue;
01157 else
01158 continue;
01159 else
01160 continue;
01161 else
01162 continue;
01163 else
01164 continue;
01165 else
01166 continue;
01167 else if(p[offset2] < c_b)
01168 if(p[offset4] > cb)
01169 if(p[offset11] > cb)
01170 if(p[offset7] > cb)
01171 if(p[offset8] > cb)
01172 if(p[offset9] > cb)
01173 if(p[offset10] > cb)
01174 if(p[offset6] > cb)
01175 if(p[offset5] > cb)
01176 if(p[offset3] > cb)
01177 {}
01178 else
01179 if(p[offset12] > cb)
01180 {}
01181 else
01182 continue;
01183 else
01184 if(p[offset12] > cb)
01185 if(p[offset13] > cb)
01186 if(p[offset14] > cb)
01187 {}
01188 else
01189 continue;
01190 else
01191 continue;
01192 else
01193 continue;
01194 else
01195 if(p[offset12] > cb)
01196 if(p[offset13] > cb)
01197 if(p[offset14] > cb)
01198 if(p[offset15] > cb)
01199 {}
01200 else
01201 continue;
01202 else
01203 continue;
01204 else
01205 continue;
01206 else
01207 continue;
01208 else
01209 continue;
01210 else
01211 continue;
01212 else
01213 continue;
01214 else
01215 continue;
01216 else if(p[offset11] < c_b)
01217 if(p[offset12] < c_b)
01218 if(p[offset13] < c_b)
01219 if(p[offset10] < c_b)
01220 if(p[offset14] < c_b)
01221 if(p[offset15] < c_b)
01222 if(p[offset1] < c_b)
01223 {}
01224 else
01225 if(p[offset8] < c_b)
01226 if(p[offset9] < c_b)
01227 {}
01228 else
01229 continue;
01230 else
01231 continue;
01232 else
01233 if(p[offset6] < c_b)
01234 if(p[offset7] < c_b)
01235 if(p[offset8] < c_b)
01236 if(p[offset9] < c_b)
01237 {}
01238 else
01239 continue;
01240 else
01241 continue;
01242 else
01243 continue;
01244 else
01245 continue;
01246 else
01247 if(p[offset5] < c_b)
01248 if(p[offset6] < c_b)
01249 if(p[offset7] < c_b)
01250 if(p[offset8] < c_b)
01251 if(p[offset9] < c_b)
01252 {}
01253 else
01254 continue;
01255 else
01256 continue;
01257 else
01258 continue;
01259 else
01260 continue;
01261 else
01262 continue;
01263 else
01264 if(p[offset1] < c_b)
01265 if(p[offset3] < c_b)
01266 if(p[offset14] < c_b)
01267 if(p[offset15] < c_b)
01268 {}
01269 else
01270 continue;
01271 else
01272 continue;
01273 else
01274 continue;
01275 else
01276 continue;
01277 else
01278 continue;
01279 else
01280 continue;
01281 else
01282 continue;
01283 else if(p[offset4] < c_b)
01284 if(p[offset5] > cb)
01285 if(p[offset12] > cb)
01286 if(p[offset7] > cb)
01287 if(p[offset8] > cb)
01288 if(p[offset9] > cb)
01289 if(p[offset10] > cb)
01290 if(p[offset11] > cb)
01291 if(p[offset13] > cb)
01292 if(p[offset6] > cb)
01293 {}
01294 else
01295 if(p[offset14] > cb)
01296 if(p[offset15] > cb)
01297 {}
01298 else
01299 continue;
01300 else
01301 continue;
01302 else
01303 continue;
01304 else
01305 continue;
01306 else
01307 continue;
01308 else
01309 continue;
01310 else
01311 continue;
01312 else
01313 continue;
01314 else if(p[offset12] < c_b)
01315 if(p[offset13] < c_b)
01316 if(p[offset14] < c_b)
01317 if(p[offset15] < c_b)
01318 if(p[offset1] < c_b)
01319 if(p[offset3] < c_b)
01320 {}
01321 else
01322 if(p[offset10] < c_b)
01323 if(p[offset11] < c_b)
01324 {}
01325 else
01326 continue;
01327 else
01328 continue;
01329 else
01330 if(p[offset8] < c_b)
01331 if(p[offset9] < c_b)
01332 if(p[offset10] < c_b)
01333 if(p[offset11] < c_b)
01334 {}
01335 else
01336 continue;
01337 else
01338 continue;
01339 else
01340 continue;
01341 else
01342 continue;
01343 else
01344 if(p[offset6] < c_b)
01345 if(p[offset7] < c_b)
01346 if(p[offset8] < c_b)
01347 if(p[offset9] < c_b)
01348 if(p[offset10] < c_b)
01349 if(p[offset11] < c_b)
01350 {}
01351 else
01352 continue;
01353 else
01354 continue;
01355 else
01356 continue;
01357 else
01358 continue;
01359 else
01360 continue;
01361 else
01362 continue;
01363 else
01364 continue;
01365 else
01366 continue;
01367 else
01368 continue;
01369 else if(p[offset5] < c_b)
01370 if(p[offset7] > cb)
01371 if(p[offset14] > cb)
01372 if(p[offset8] > cb)
01373 if(p[offset9] > cb)
01374 if(p[offset10] > cb)
01375 if(p[offset11] > cb)
01376 if(p[offset12] > cb)
01377 if(p[offset13] > cb)
01378 if(p[offset6] > cb)
01379 {}
01380 else
01381 if(p[offset15] > cb)
01382 {}
01383 else
01384 continue;
01385 else
01386 continue;
01387 else
01388 continue;
01389 else
01390 continue;
01391 else
01392 continue;
01393 else
01394 continue;
01395 else
01396 continue;
01397 else if(p[offset14] < c_b)
01398 if(p[offset15] < c_b)
01399 if(p[offset1] < c_b)
01400 if(p[offset3] < c_b)
01401 if(p[offset6] < c_b)
01402 {}
01403 else
01404 if(p[offset13] < c_b)
01405 {}
01406 else
01407 continue;
01408 else
01409 if(p[offset10] < c_b)
01410 if(p[offset11] < c_b)
01411 if(p[offset12] < c_b)
01412 if(p[offset13] < c_b)
01413 {}
01414 else
01415 continue;
01416 else
01417 continue;
01418 else
01419 continue;
01420 else
01421 continue;
01422 else
01423 if(p[offset8] < c_b)
01424 if(p[offset9] < c_b)
01425 if(p[offset10] < c_b)
01426 if(p[offset11] < c_b)
01427 if(p[offset12] < c_b)
01428 if(p[offset13] < c_b)
01429 {}
01430 else
01431 continue;
01432 else
01433 continue;
01434 else
01435 continue;
01436 else
01437 continue;
01438 else
01439 continue;
01440 else
01441 continue;
01442 else
01443 continue;
01444 else
01445 continue;
01446 else if(p[offset7] < c_b)
01447 if(p[offset3] < c_b)
01448 if(p[offset1] < c_b)
01449 if(p[offset6] < c_b)
01450 if(p[offset8] < c_b)
01451 {}
01452 else
01453 if(p[offset15] < c_b)
01454 {}
01455 else
01456 continue;
01457 else
01458 if(p[offset13] < c_b)
01459 if(p[offset14] < c_b)
01460 if(p[offset15] < c_b)
01461 {}
01462 else
01463 continue;
01464 else
01465 continue;
01466 else
01467 continue;
01468 else
01469 if(p[offset8] < c_b)
01470 if(p[offset9] < c_b)
01471 if(p[offset10] < c_b)
01472 if(p[offset6] < c_b)
01473 {}
01474 else
01475 if(p[offset11] < c_b)
01476 if(p[offset12] < c_b)
01477 if(p[offset13] < c_b)
01478 if(p[offset14] < c_b)
01479 if(p[offset15] < c_b)
01480 {}
01481 else
01482 continue;
01483 else
01484 continue;
01485 else
01486 continue;
01487 else
01488 continue;
01489 else
01490 continue;
01491 else
01492 continue;
01493 else
01494 continue;
01495 else
01496 continue;
01497 else
01498 if(p[offset10] < c_b)
01499 if(p[offset11] < c_b)
01500 if(p[offset12] < c_b)
01501 if(p[offset8] < c_b)
01502 if(p[offset9] < c_b)
01503 if(p[offset6] < c_b)
01504 {}
01505 else
01506 if(p[offset13] < c_b)
01507 if(p[offset14] < c_b)
01508 if(p[offset15] < c_b)
01509 {}
01510 else
01511 continue;
01512 else
01513 continue;
01514 else
01515 continue;
01516 else
01517 if(p[offset1] < c_b)
01518 if(p[offset13] < c_b)
01519 if(p[offset14] < c_b)
01520 if(p[offset15] < c_b)
01521 {}
01522 else
01523 continue;
01524 else
01525 continue;
01526 else
01527 continue;
01528 else
01529 continue;
01530 else
01531 if(p[offset1] < c_b)
01532 if(p[offset13] < c_b)
01533 if(p[offset14] < c_b)
01534 if(p[offset15] < c_b)
01535 {}
01536 else
01537 continue;
01538 else
01539 continue;
01540 else
01541 continue;
01542 else
01543 continue;
01544 else
01545 continue;
01546 else
01547 continue;
01548 else
01549 continue;
01550 else
01551 if(p[offset14] < c_b)
01552 if(p[offset15] < c_b)
01553 if(p[offset1] < c_b)
01554 if(p[offset3] < c_b)
01555 if(p[offset6] < c_b)
01556 {}
01557 else
01558 if(p[offset13] < c_b)
01559 {}
01560 else
01561 continue;
01562 else
01563 if(p[offset10] < c_b)
01564 if(p[offset11] < c_b)
01565 if(p[offset12] < c_b)
01566 if(p[offset13] < c_b)
01567 {}
01568 else
01569 continue;
01570 else
01571 continue;
01572 else
01573 continue;
01574 else
01575 continue;
01576 else
01577 if(p[offset8] < c_b)
01578 if(p[offset9] < c_b)
01579 if(p[offset10] < c_b)
01580 if(p[offset11] < c_b)
01581 if(p[offset12] < c_b)
01582 if(p[offset13] < c_b)
01583 {}
01584 else
01585 continue;
01586 else
01587 continue;
01588 else
01589 continue;
01590 else
01591 continue;
01592 else
01593 continue;
01594 else
01595 continue;
01596 else
01597 continue;
01598 else
01599 continue;
01600 else
01601 if(p[offset12] > cb)
01602 if(p[offset7] > cb)
01603 if(p[offset8] > cb)
01604 if(p[offset9] > cb)
01605 if(p[offset10] > cb)
01606 if(p[offset11] > cb)
01607 if(p[offset13] > cb)
01608 if(p[offset14] > cb)
01609 if(p[offset6] > cb)
01610 {}
01611 else
01612 if(p[offset15] > cb)
01613 {}
01614 else
01615 continue;
01616 else
01617 continue;
01618 else
01619 continue;
01620 else
01621 continue;
01622 else
01623 continue;
01624 else
01625 continue;
01626 else
01627 continue;
01628 else
01629 continue;
01630 else if(p[offset12] < c_b)
01631 if(p[offset13] < c_b)
01632 if(p[offset14] < c_b)
01633 if(p[offset15] < c_b)
01634 if(p[offset1] < c_b)
01635 if(p[offset3] < c_b)
01636 {}
01637 else
01638 if(p[offset10] < c_b)
01639 if(p[offset11] < c_b)
01640 {}
01641 else
01642 continue;
01643 else
01644 continue;
01645 else
01646 if(p[offset8] < c_b)
01647 if(p[offset9] < c_b)
01648 if(p[offset10] < c_b)
01649 if(p[offset11] < c_b)
01650 {}
01651 else
01652 continue;
01653 else
01654 continue;
01655 else
01656 continue;
01657 else
01658 continue;
01659 else
01660 if(p[offset6] < c_b)
01661 if(p[offset7] < c_b)
01662 if(p[offset8] < c_b)
01663 if(p[offset9] < c_b)
01664 if(p[offset10] < c_b)
01665 if(p[offset11] < c_b)
01666 {}
01667 else
01668 continue;
01669 else
01670 continue;
01671 else
01672 continue;
01673 else
01674 continue;
01675 else
01676 continue;
01677 else
01678 continue;
01679 else
01680 continue;
01681 else
01682 continue;
01683 else
01684 continue;
01685 else
01686 if(p[offset11] > cb)
01687 if(p[offset7] > cb)
01688 if(p[offset8] > cb)
01689 if(p[offset9] > cb)
01690 if(p[offset10] > cb)
01691 if(p[offset12] > cb)
01692 if(p[offset13] > cb)
01693 if(p[offset6] > cb)
01694 if(p[offset5] > cb)
01695 {}
01696 else
01697 if(p[offset14] > cb)
01698 {}
01699 else
01700 continue;
01701 else
01702 if(p[offset14] > cb)
01703 if(p[offset15] > cb)
01704 {}
01705 else
01706 continue;
01707 else
01708 continue;
01709 else
01710 continue;
01711 else
01712 continue;
01713 else
01714 continue;
01715 else
01716 continue;
01717 else
01718 continue;
01719 else
01720 continue;
01721 else if(p[offset11] < c_b)
01722 if(p[offset12] < c_b)
01723 if(p[offset13] < c_b)
01724 if(p[offset10] < c_b)
01725 if(p[offset14] < c_b)
01726 if(p[offset15] < c_b)
01727 if(p[offset1] < c_b)
01728 {}
01729 else
01730 if(p[offset8] < c_b)
01731 if(p[offset9] < c_b)
01732 {}
01733 else
01734 continue;
01735 else
01736 continue;
01737 else
01738 if(p[offset6] < c_b)
01739 if(p[offset7] < c_b)
01740 if(p[offset8] < c_b)
01741 if(p[offset9] < c_b)
01742 {}
01743 else
01744 continue;
01745 else
01746 continue;
01747 else
01748 continue;
01749 else
01750 continue;
01751 else
01752 if(p[offset5] < c_b)
01753 if(p[offset6] < c_b)
01754 if(p[offset7] < c_b)
01755 if(p[offset8] < c_b)
01756 if(p[offset9] < c_b)
01757 {}
01758 else
01759 continue;
01760 else
01761 continue;
01762 else
01763 continue;
01764 else
01765 continue;
01766 else
01767 continue;
01768 else
01769 if(p[offset1] < c_b)
01770 if(p[offset3] < c_b)
01771 if(p[offset14] < c_b)
01772 if(p[offset15] < c_b)
01773 {}
01774 else
01775 continue;
01776 else
01777 continue;
01778 else
01779 continue;
01780 else
01781 continue;
01782 else
01783 continue;
01784 else
01785 continue;
01786 else
01787 continue;
01788 else
01789 if(p[offset9] > cb)
01790 if(p[offset7] > cb)
01791 if(p[offset8] > cb)
01792 if(p[offset10] > cb)
01793 if(p[offset11] > cb)
01794 if(p[offset6] > cb)
01795 if(p[offset5] > cb)
01796 if(p[offset4] > cb)
01797 if(p[offset3] > cb)
01798 {}
01799 else
01800 if(p[offset12] > cb)
01801 {}
01802 else
01803 continue;
01804 else
01805 if(p[offset12] > cb)
01806 if(p[offset13] > cb)
01807 {}
01808 else
01809 continue;
01810 else
01811 continue;
01812 else
01813 if(p[offset12] > cb)
01814 if(p[offset13] > cb)
01815 if(p[offset14] > cb)
01816 {}
01817 else
01818 continue;
01819 else
01820 continue;
01821 else
01822 continue;
01823 else
01824 if(p[offset12] > cb)
01825 if(p[offset13] > cb)
01826 if(p[offset14] > cb)
01827 if(p[offset15] > cb)
01828 {}
01829 else
01830 continue;
01831 else
01832 continue;
01833 else
01834 continue;
01835 else
01836 continue;
01837 else
01838 continue;
01839 else
01840 continue;
01841 else
01842 continue;
01843 else
01844 continue;
01845 else if(p[offset9] < c_b)
01846 if(p[offset10] < c_b)
01847 if(p[offset11] < c_b)
01848 if(p[offset8] < c_b)
01849 if(p[offset12] < c_b)
01850 if(p[offset13] < c_b)
01851 if(p[offset14] < c_b)
01852 if(p[offset15] < c_b)
01853 {}
01854 else
01855 if(p[offset6] < c_b)
01856 if(p[offset7] < c_b)
01857 {}
01858 else
01859 continue;
01860 else
01861 continue;
01862 else
01863 if(p[offset5] < c_b)
01864 if(p[offset6] < c_b)
01865 if(p[offset7] < c_b)
01866 {}
01867 else
01868 continue;
01869 else
01870 continue;
01871 else
01872 continue;
01873 else
01874 if(p[offset4] < c_b)
01875 if(p[offset5] < c_b)
01876 if(p[offset6] < c_b)
01877 if(p[offset7] < c_b)
01878 {}
01879 else
01880 continue;
01881 else
01882 continue;
01883 else
01884 continue;
01885 else
01886 continue;
01887 else
01888 if(p[offset3] < c_b)
01889 if(p[offset4] < c_b)
01890 if(p[offset5] < c_b)
01891 if(p[offset6] < c_b)
01892 if(p[offset7] < c_b)
01893 {}
01894 else
01895 continue;
01896 else
01897 continue;
01898 else
01899 continue;
01900 else
01901 continue;
01902 else
01903 continue;
01904 else
01905 if(p[offset1] < c_b)
01906 if(p[offset12] < c_b)
01907 if(p[offset13] < c_b)
01908 if(p[offset14] < c_b)
01909 if(p[offset15] < c_b)
01910 {}
01911 else
01912 continue;
01913 else
01914 continue;
01915 else
01916 continue;
01917 else
01918 continue;
01919 else
01920 continue;
01921 else
01922 continue;
01923 else
01924 continue;
01925 else
01926 continue;
01927 else
01928 if(p[offset7] > cb)
01929 if(p[offset8] > cb)
01930 if(p[offset9] > cb)
01931 if(p[offset6] > cb)
01932 if(p[offset5] > cb)
01933 if(p[offset4] > cb)
01934 if(p[offset3] > cb)
01935 if(p[offset2] > cb)
01936 if(p[offset1] > cb)
01937 {}
01938 else
01939 if(p[offset10] > cb)
01940 {}
01941 else
01942 continue;
01943 else
01944 if(p[offset10] > cb)
01945 if(p[offset11] > cb)
01946 {}
01947 else
01948 continue;
01949 else
01950 continue;
01951 else
01952 if(p[offset10] > cb)
01953 if(p[offset11] > cb)
01954 if(p[offset12] > cb)
01955 {}
01956 else
01957 continue;
01958 else
01959 continue;
01960 else
01961 continue;
01962 else
01963 if(p[offset10] > cb)
01964 if(p[offset11] > cb)
01965 if(p[offset12] > cb)
01966 if(p[offset13] > cb)
01967 {}
01968 else
01969 continue;
01970 else
01971 continue;
01972 else
01973 continue;
01974 else
01975 continue;
01976 else
01977 if(p[offset10] > cb)
01978 if(p[offset11] > cb)
01979 if(p[offset12] > cb)
01980 if(p[offset13] > cb)
01981 if(p[offset14] > cb)
01982 {}
01983 else
01984 continue;
01985 else
01986 continue;
01987 else
01988 continue;
01989 else
01990 continue;
01991 else
01992 continue;
01993 else
01994 if(p[offset10] > cb)
01995 if(p[offset11] > cb)
01996 if(p[offset12] > cb)
01997 if(p[offset13] > cb)
01998 if(p[offset14] > cb)
01999 if(p[offset15] > cb)
02000 {}
02001 else
02002 continue;
02003 else
02004 continue;
02005 else
02006 continue;
02007 else
02008 continue;
02009 else
02010 continue;
02011 else
02012 continue;
02013 else
02014 continue;
02015 else
02016 continue;
02017 else if(p[offset7] < c_b)
02018 if(p[offset8] < c_b)
02019 if(p[offset9] < c_b)
02020 if(p[offset6] < c_b)
02021 if(p[offset5] < c_b)
02022 if(p[offset4] < c_b)
02023 if(p[offset3] < c_b)
02024 if(p[offset2] < c_b)
02025 if(p[offset1] < c_b)
02026 {}
02027 else
02028 if(p[offset10] < c_b)
02029 {}
02030 else
02031 continue;
02032 else
02033 if(p[offset10] < c_b)
02034 if(p[offset11] < c_b)
02035 {}
02036 else
02037 continue;
02038 else
02039 continue;
02040 else
02041 if(p[offset10] < c_b)
02042 if(p[offset11] < c_b)
02043 if(p[offset12] < c_b)
02044 {}
02045 else
02046 continue;
02047 else
02048 continue;
02049 else
02050 continue;
02051 else
02052 if(p[offset10] < c_b)
02053 if(p[offset11] < c_b)
02054 if(p[offset12] < c_b)
02055 if(p[offset13] < c_b)
02056 {}
02057 else
02058 continue;
02059 else
02060 continue;
02061 else
02062 continue;
02063 else
02064 continue;
02065 else
02066 if(p[offset10] < c_b)
02067 if(p[offset11] < c_b)
02068 if(p[offset12] < c_b)
02069 if(p[offset13] < c_b)
02070 if(p[offset14] < c_b)
02071 {}
02072 else
02073 continue;
02074 else
02075 continue;
02076 else
02077 continue;
02078 else
02079 continue;
02080 else
02081 continue;
02082 else
02083 if(p[offset10] < c_b)
02084 if(p[offset11] < c_b)
02085 if(p[offset12] < c_b)
02086 if(p[offset13] < c_b)
02087 if(p[offset14] < c_b)
02088 if(p[offset15] < c_b)
02089 {}
02090 else
02091 continue;
02092 else
02093 continue;
02094 else
02095 continue;
02096 else
02097 continue;
02098 else
02099 continue;
02100 else
02101 continue;
02102 else
02103 continue;
02104 else
02105 continue;
02106 else
02107 continue;
02108 }
02109 if(total == nExpectedCorners)
02110 {
02111 if(nExpectedCorners==0)
02112 {
02113 nExpectedCorners=512;
02114 corners_all.reserve(nExpectedCorners);
02115 }
02116 else
02117 {
02118 nExpectedCorners *=2;
02119 corners_all.reserve(nExpectedCorners);
02120 }
02121 }
02122 h.x=x;
02123 h.y=y;
02124 corners_all.push_back(h);
02125 total++;
02126 }
02127 }
02128 }
02129
02130