Commit 66e940bb55f529b6d601b4134d246ad615253a4a
Merge branch 'master' of https://github.com/biometrics/openbr
Showing
2 changed files
with
10 additions
and
5 deletions
3rdparty/http-parser-2.1/http_parser.c
| @@ -2004,21 +2004,21 @@ http_parse_host(const char * buf, struct http_parser_url *u, int found_at) { | @@ -2004,21 +2004,21 @@ http_parse_host(const char * buf, struct http_parser_url *u, int found_at) { | ||
| 2004 | switch(new_s) { | 2004 | switch(new_s) { |
| 2005 | case s_http_host: | 2005 | case s_http_host: |
| 2006 | if (s != s_http_host) { | 2006 | if (s != s_http_host) { |
| 2007 | - u->field_data[UF_HOST].off = p - buf; | 2007 | + u->field_data[UF_HOST].off = (uint16_t) (p - buf); |
| 2008 | } | 2008 | } |
| 2009 | u->field_data[UF_HOST].len++; | 2009 | u->field_data[UF_HOST].len++; |
| 2010 | break; | 2010 | break; |
| 2011 | 2011 | ||
| 2012 | case s_http_host_v6: | 2012 | case s_http_host_v6: |
| 2013 | if (s != s_http_host_v6) { | 2013 | if (s != s_http_host_v6) { |
| 2014 | - u->field_data[UF_HOST].off = p - buf; | 2014 | + u->field_data[UF_HOST].off = (uint16_t) (p - buf); |
| 2015 | } | 2015 | } |
| 2016 | u->field_data[UF_HOST].len++; | 2016 | u->field_data[UF_HOST].len++; |
| 2017 | break; | 2017 | break; |
| 2018 | 2018 | ||
| 2019 | case s_http_host_port: | 2019 | case s_http_host_port: |
| 2020 | if (s != s_http_host_port) { | 2020 | if (s != s_http_host_port) { |
| 2021 | - u->field_data[UF_PORT].off = p - buf; | 2021 | + u->field_data[UF_PORT].off = (uint16_t) (p - buf); |
| 2022 | u->field_data[UF_PORT].len = 0; | 2022 | u->field_data[UF_PORT].len = 0; |
| 2023 | u->field_set |= (1 << UF_PORT); | 2023 | u->field_set |= (1 << UF_PORT); |
| 2024 | } | 2024 | } |
| @@ -2027,7 +2027,7 @@ http_parse_host(const char * buf, struct http_parser_url *u, int found_at) { | @@ -2027,7 +2027,7 @@ http_parse_host(const char * buf, struct http_parser_url *u, int found_at) { | ||
| 2027 | 2027 | ||
| 2028 | case s_http_userinfo: | 2028 | case s_http_userinfo: |
| 2029 | if (s != s_http_userinfo) { | 2029 | if (s != s_http_userinfo) { |
| 2030 | - u->field_data[UF_USERINFO].off = p - buf ; | 2030 | + u->field_data[UF_USERINFO].off = (uint16_t) (p - buf) ; |
| 2031 | u->field_data[UF_USERINFO].len = 0; | 2031 | u->field_data[UF_USERINFO].len = 0; |
| 2032 | u->field_set |= (1 << UF_USERINFO); | 2032 | u->field_set |= (1 << UF_USERINFO); |
| 2033 | } | 2033 | } |
| @@ -2120,7 +2120,7 @@ http_parser_parse_url(const char *buf, size_t buflen, int is_connect, | @@ -2120,7 +2120,7 @@ http_parser_parse_url(const char *buf, size_t buflen, int is_connect, | ||
| 2120 | continue; | 2120 | continue; |
| 2121 | } | 2121 | } |
| 2122 | 2122 | ||
| 2123 | - u->field_data[uf].off = p - buf; | 2123 | + u->field_data[uf].off = (uint16_t) (p - buf); |
| 2124 | u->field_data[uf].len = 1; | 2124 | u->field_data[uf].len = 1; |
| 2125 | 2125 | ||
| 2126 | u->field_set |= (1 << uf); | 2126 | u->field_set |= (1 << uf); |
openbr/plugins/algorithms.cpp
| @@ -45,6 +45,11 @@ class AlgorithmsInitializer : public Initializer | @@ -45,6 +45,11 @@ class AlgorithmsInitializer : public Initializer | ||
| 45 | Globals->abbreviations.insert("FaceRecognition2", "{PP5Register+Affine(128,128,0.25,0.35)+Cvt(Gray)}+(Gradient+Bin(0,360,9,true))/(Blur(1)+Gamma(0.2)+DoG(1,2)+ContrastEq(0.1,10)+LBP(1,2,true)+Bin(0,10,10,true))+Merge+Integral+RecursiveIntegralSampler(4,2,8,LDA(.98)+Normalize(L1))+Cat+PCA(768)+Normalize(L1)+Quantize:UCharL1"); | 45 | Globals->abbreviations.insert("FaceRecognition2", "{PP5Register+Affine(128,128,0.25,0.35)+Cvt(Gray)}+(Gradient+Bin(0,360,9,true))/(Blur(1)+Gamma(0.2)+DoG(1,2)+ContrastEq(0.1,10)+LBP(1,2,true)+Bin(0,10,10,true))+Merge+Integral+RecursiveIntegralSampler(4,2,8,LDA(.98)+Normalize(L1))+Cat+PCA(768)+Normalize(L1)+Quantize:UCharL1"); |
| 46 | Globals->abbreviations.insert("CropFace", "Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.25,0.35)"); | 46 | Globals->abbreviations.insert("CropFace", "Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.25,0.35)"); |
| 47 | 47 | ||
| 48 | + // Video | ||
| 49 | + Globals->abbreviations.insert("DisplayVideo", "Stream([Show(false)+Discard])"); | ||
| 50 | + Globals->abbreviations.insert("PerFrameDetection", "Stream([SaveMat(original)+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+RestoreMat(original)+Draw(inPlace=true),Show(false)+Discard])"); | ||
| 51 | + Globals->abbreviations.insert("AgeGenderDemo", "Stream([SaveMat(original)+Cvt(Gray)+Cascade(FrontalFace)+Expand+<FaceClassificationRegistration>+<FaceClassificationExtraction>+(<AgeRegressor>+Rename(Subject,Age)+Discard)/(<GenderClassifier>+Rename(Subject,Gender)+Discard)+RestoreMat(original)+Draw(inPlace=true)+DrawPropertiesPoint([Age,Gender],Affine_0,inPlace=true)+SaveMat(original)+Discard+Contract,RestoreMat(original)+FPSCalc+Show(false,[AvgFPS,Age,Gender])+Discard])"); | ||
| 52 | + | ||
| 48 | // Generic Image Processing | 53 | // Generic Image Processing |
| 49 | Globals->abbreviations.insert("SIFT", "Open+KeyPointDetector(SIFT)+KeyPointDescriptor(SIFT):KeyPointMatcher(BruteForce)"); | 54 | Globals->abbreviations.insert("SIFT", "Open+KeyPointDetector(SIFT)+KeyPointDescriptor(SIFT):KeyPointMatcher(BruteForce)"); |
| 50 | Globals->abbreviations.insert("SURF", "Open+KeyPointDetector(SURF)+KeyPointDescriptor(SURF):KeyPointMatcher(BruteForce)"); | 55 | Globals->abbreviations.insert("SURF", "Open+KeyPointDetector(SURF)+KeyPointDescriptor(SURF):KeyPointMatcher(BruteForce)"); |