亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? scanner.cpp

?? tracciatore di mani con webcam
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
/**  * cubicles  *  * This is an implementation of the Viola-Jones object detection   * method and some extensions.  The code is mostly platform-  * independent and uses only standard C and C++ libraries.  It  * can make use of MPI for parallel training and a few Windows  * MFC functions for classifier display.  *  * Mathias Kolsch, matz@cs.ucsb.edu  *  * $Id: Scanner.cpp,v 1.48 2004/11/11 01:58:58 matz Exp $**/// Scanner scans across an image and finds matches for the // classifier cascade.  There's also a Scanner_Train.cpp// implementation file that for training-only functions.////////////////////////////////////////////////////////////////////////// By downloading, copying, installing or using the software you // agree to this license.  If you do not agree to this license, // do not download, install, copy or use the software.//// Copyright (C) 2004, Mathias Kolsch, all rights reserved.// Third party copyrights are property of their respective owners.//// Redistribution and use in binary form, with or without // modification, is permitted for non-commercial purposes only.// Redistribution in source, with or without modification, is // prohibited without prior written permission.// If granted in writing in another document, personal use and // modification are permitted provided that the following two// conditions are met://// 1.Any modification of source code must retain the above //   copyright notice, this list of conditions and the following //   disclaimer.//// 2.Redistribution's in binary form must reproduce the above //   copyright notice, this list of conditions and the following //   disclaimer in the documentation and/or other materials provided//   with the distribution.//// This software is provided by the copyright holders and // contributors "as is" and any express or implied warranties, // including, but not limited to, the implied warranties of // merchantability and fitness for a particular purpose are // disclaimed.  In no event shall the copyright holder or // contributors be liable for any direct, indirect, incidental, // special, exemplary, or consequential damages (including, but not // limited to, procurement of substitute goods or services; loss of // use, data, or profits; or business interruption) however caused// and on any theory of liability, whether in contract, strict // liability, or tort (including negligence or otherwise) arising // in any way out of the use of this software, even if advised of // the possibility of such damage.//////////////////////////////////////////////////////////////////////#include "cubicles.hpp"#include "Scanner.h"#include "Cascade.h"#include <math.h>#include <iostream>#ifdef _DEBUG#ifdef USE_MFC#define new DEBUG_NEW#undef THIS_FILEstatic char THIS_FILE[] = __FILE__;#endif // USE_MFC#endif // _DEBUG// ----------------------------------------------------------------------// class CImageScanner// ----------------------------------------------------------------------CImageScanner::CImageScanner() : m_is_active(true),  m_post_process(false){  SetScanParameters();}CImageScanner::CImageScanner(const CImageScanner& src) : m_is_active(src.m_is_active),  m_start_scale(src.m_start_scale),  m_stop_scale(src.m_stop_scale),  m_scale_inc_factor(src.m_scale_inc_factor),  m_translation_inc_x(src.m_translation_inc_x),  m_translation_inc_y(src.m_translation_inc_y),  m_scan_area(src.m_scan_area),  m_post_process(src.m_post_process),  m_min_scaled_template_width(-1),  m_max_scaled_template_width(-1),  m_min_scaled_template_height(-1),  m_max_scaled_template_height(-1),  m_integral(src.m_integral),  m_squared_integral(src.m_squared_integral){}void CImageScanner::SetScanParameters(                                      double start_scale /* = 1.0 */,                                      double stop_scale /* = DBL_MAX */,                                      double scale_inc_factor /* = 1.25 */,                                      double translation_inc_x /* = 1.0 */,                                      double translation_inc_y /* = 1.0 */,                                      CRect scan_area /* = CRect(0, 0, INT_MAX, INT_MAX) */                                      ){  SetScanScales(start_scale, stop_scale);  m_scale_inc_factor = scale_inc_factor;  m_translation_inc_x = translation_inc_x;  m_translation_inc_y = translation_inc_y;  m_scan_area = scan_area;  m_min_scaled_template_width = -1;  m_max_scaled_template_width = -1;  m_min_scaled_template_height = -1;  m_max_scaled_template_height = -1;}void CImageScanner::GetScanParameters(    double* pStart_scale,    double* pStop_scale,    double* pScale_inc_factor,    double* pTranslation_inc_x,    double* pTranslation_inc_y,    CRect& scan_area,    bool* pPostProcessing,    bool* pIsActive    ) const{  *pStart_scale = m_start_scale;  *pStop_scale = m_stop_scale;  *pScale_inc_factor = m_scale_inc_factor;  *pTranslation_inc_x = m_translation_inc_x;  *pTranslation_inc_y = m_translation_inc_y;  *pPostProcessing = m_post_process;  *pIsActive = m_is_active;  scan_area = m_scan_area;}void CImageScanner::SetScanArea(const CRect& scan_area){  m_scan_area = scan_area;}void CImageScanner::SetScanScales(double start_scale, double stop_scale){  m_start_scale = start_scale;  m_stop_scale = stop_scale;  m_min_scaled_template_width = -1;  m_max_scaled_template_width = -1;  m_min_scaled_template_height = -1;  m_max_scaled_template_height = -1;}// must be called after the actual scan, and the behavior with// multiple active scanners is somewhat undeterminedvoid CImageScanner::GetScaleSizes(int* min_width, int* max_width,				  int* min_height, int* max_height) const{  *min_width = m_min_scaled_template_width;  *max_width = m_max_scaled_template_width;  *min_height = m_min_scaled_template_height;  *max_height = m_max_scaled_template_height;}void CImageScanner::SetAutoPostProcessing(bool on /*=true*/){  m_post_process = on;}const CRect& CImageScanner::GetScanArea() const{  return m_scan_area;}intCImageScanner::Scan(const CClassifierCascade& cascade,		    const CByteImage& image, CScanMatchVector& posClsfd) const{  if (!m_is_active) return -1;  // make integral of regular and squared image  CIntegralImage::CreateSimpleNSquaredFrom(image, m_integral,					   m_squared_integral, m_scan_area);  return Scan(cascade, m_integral, m_squared_integral, posClsfd);}intCImageScanner::Scan(const CClassifierCascade& cascade,		    const CIntegralImage& integral,                    const CIntegralImage& squared_integral,                    CScanMatchVector& posClsfd) const{  if (!m_is_active) return -1;  posClsfd.clear();    CScaleParams sclprms;  InitScaleParams(cascade, sclprms);  m_min_scaled_template_width = sclprms.scaled_template_width;  m_min_scaled_template_height = sclprms.scaled_template_height;  double N = sclprms.scaled_template_width * sclprms.scaled_template_height;    int width = integral.GetWidth();  int height = integral.GetHeight();    CStringVector matches;  int scancnt=0;  while (sclprms.scaled_template_width<width && sclprms.scaled_template_height<height    && sclprms.base_scale<m_stop_scale)   {    cascade.ScaleFeaturesEvenly(sclprms.actual_scale_x, 				sclprms.actual_scale_y,				sclprms.scaled_template_width, 				sclprms.scaled_template_height);    // for each y-location in the image    int top_stop = min(m_scan_area.bottom, height)-sclprms.scaled_template_height;    for (int top=max(0, m_scan_area.top); top<top_stop; top+=(int)sclprms.translation_inc_y) {      int bottom = top+sclprms.scaled_template_height;      // for each x-location in the image      int left_stop = min(m_scan_area.right, width)-sclprms.scaled_template_width;      for (int left=max(0, m_scan_area.left); left<left_stop; left+=(int)sclprms.translation_inc_x) {        int right = left+sclprms.scaled_template_width;        double sum_x =           integral.GetElement(right-1, bottom-1)           - integral.GetElement(right-1, top-1)          - integral.GetElement(left-1, bottom-1)          + integral.GetElement(left-1, top-1);        double mean =          sum_x / N;        double sum_x2 =           squared_integral.GetElement(right-1, bottom-1)           - squared_integral.GetElement(right-1, top-1)          - squared_integral.GetElement(left-1, bottom-1)          + squared_integral.GetElement(left-1, top-1);        double stddev = sqrt(fabs(mean*mean - sum_x2/N));        //  double stddev_equal = sqrt(fabs(mean*mean - 2.0*sum_x*mean/N + sum_x2/N));        bool is_positive =          cascade.Evaluate(integral, mean, stddev, left, top, matches);        if (is_positive) {          for (int m=0; m<(int)matches.size(); m++) {            posClsfd.push_back(CScanMatch(left, top, right, bottom,                                          sclprms.base_scale,

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成人精品一区二区三区中文字幕| 亚洲国产精品久久不卡毛片 | 免费高清在线一区| 九色porny丨国产精品| 波多野结衣中文字幕一区二区三区| 色综合久久88色综合天天| 4438x成人网最大色成网站| 欧美r级在线观看| 国产精品国产精品国产专区不蜜 | 91精品国产高清一区二区三区| 日韩欧美国产系列| 中文字幕在线观看一区二区| 亚洲gay无套男同| 懂色av一区二区夜夜嗨| 欧美日本国产视频| 喷水一区二区三区| 国产精品66部| 欧美日韩在线播放一区| 久久免费电影网| 亚洲国产综合人成综合网站| 国产一区二区在线视频| 欧美在线一区二区三区| 国产亚洲综合在线| 亚洲va在线va天堂| 99久久久免费精品国产一区二区 | 久久99精品久久久久婷婷| 97久久人人超碰| 日韩免费观看高清完整版 | 欧洲精品在线观看| 久久夜色精品一区| 亚洲无线码一区二区三区| 国产成a人亚洲精| 日韩一区二区三区在线| 一区二区三区欧美激情| 国产成人自拍在线| 日韩一级高清毛片| 亚洲欧美一区二区久久| 国产成人av一区二区三区在线观看| 欧美美女黄视频| 亚洲在线一区二区三区| jlzzjlzz欧美大全| 久久精品人人爽人人爽| 日韩va亚洲va欧美va久久| 99麻豆久久久国产精品免费优播| 日韩精品成人一区二区三区| www.成人在线| 国产日韩高清在线| 捆绑紧缚一区二区三区视频| 91福利在线免费观看| 国产精品毛片无遮挡高清| 精品亚洲免费视频| 欧美一卡二卡三卡| 日韩影院免费视频| 欧美日韩一二三区| 亚洲午夜影视影院在线观看| av不卡在线播放| 国产精品乱码一区二三区小蝌蚪| 国产精品一区二区久久精品爱涩 | 成av人片一区二区| 精品国产区一区| 三级不卡在线观看| 欧美日韩亚洲不卡| 亚洲国产精品一区二区尤物区| 韩国一区二区视频| 欧美一区二区三区喷汁尤物| 久久99蜜桃精品| 国产精品乱人伦中文| 欧美综合欧美视频| 美女国产一区二区| 日本一二三四高清不卡| 成人黄色在线网站| 樱桃国产成人精品视频| 91精品国产高清一区二区三区| 国产一区二区福利| 中文字幕在线一区免费| 欧美日韩一区二区三区四区五区| 蜜桃在线一区二区三区| 中文字幕av一区二区三区| 欧美体内she精高潮| 久久精品72免费观看| 国产精品婷婷午夜在线观看| 欧美视频中文一区二区三区在线观看| 日本特黄久久久高潮| 国产精品午夜在线| 欧美欧美欧美欧美首页| 国产成人久久精品77777最新版本| 中文字幕一区二区三区四区不卡| 欧美精品日韩综合在线| 高清国产一区二区| 亚洲国产成人av网| 久久久精品免费免费| 精品视频一区 二区 三区| 国产精品一区2区| 亚洲一二三区视频在线观看| 久久影院午夜片一区| 日本精品一区二区三区四区的功能| 奇米一区二区三区| 亚洲色图视频网| 精品国产乱码久久久久久蜜臀| www.久久精品| 国产在线精品免费| 艳妇臀荡乳欲伦亚洲一区| 久久人人97超碰com| 欧美亚洲高清一区| 成人综合婷婷国产精品久久免费| 日韩制服丝袜先锋影音| 最近中文字幕一区二区三区| 日韩免费一区二区| 欧美日韩亚洲丝袜制服| 欧美xxxx老人做受| 欧美午夜精品久久久久久孕妇 | 三级在线观看一区二区| 国产精品污网站| 精品久久人人做人人爱| 欧美制服丝袜第一页| 成人h动漫精品一区二| 久久成人精品无人区| 亚洲一区二区中文在线| 国产精品久线观看视频| 欧美成人福利视频| 欧美日本一区二区在线观看| 91美女在线看| 国产成人av影院| 精品一二线国产| 日韩va欧美va亚洲va久久| 夜夜夜精品看看| 国产精品传媒视频| 国产日韩综合av| 欧美成人性福生活免费看| 56国语精品自产拍在线观看| 色综合久久中文综合久久牛| 成人开心网精品视频| 国产一区二区三区视频在线播放| 美女国产一区二区| 日本欧美加勒比视频| 亚洲午夜电影网| 亚洲国产日韩a在线播放性色| 亚洲精品视频免费观看| 中文字幕一区av| 中文字幕一区二区三区四区不卡| 中文字幕av一区二区三区| 久久精品一区二区| 久久久蜜臀国产一区二区| 日韩欧美中文字幕精品| 制服丝袜日韩国产| 91精品国产高清一区二区三区蜜臀| 精品视频在线视频| 欧美日本在线一区| 在线不卡一区二区| 9191成人精品久久| 在线不卡免费av| 日韩一区二区三区四区| 欧美刺激午夜性久久久久久久 | 99re66热这里只有精品3直播 | 国产精品一区二区三区网站| 国产在线一区二区综合免费视频| 久久99久久99小草精品免视看| 裸体健美xxxx欧美裸体表演| 蜜臀av亚洲一区中文字幕| 美女视频黄频大全不卡视频在线播放| 蜜臀91精品一区二区三区| 久久99国产精品久久| 国内一区二区在线| 国产传媒一区在线| 国产成人aaa| 91视频观看视频| 色94色欧美sute亚洲线路一ni| 91成人国产精品| 欧美三级电影在线观看| 欧美一级淫片007| 久久午夜电影网| 国产精品久久久久影院老司| 亚洲人成伊人成综合网小说| 亚洲国产综合91精品麻豆| 五月婷婷色综合| 精品一区二区三区视频| 国产成人精品免费视频网站| 94-欧美-setu| 欧美日韩国产小视频| 日韩激情视频网站| 精品在线你懂的| 成人黄色电影在线 | 国产福利一区二区三区视频| www..com久久爱| 在线亚洲+欧美+日本专区| 欧美日韩www| 久久久亚洲综合| 亚洲欧美在线观看| 五月婷婷色综合| 国产电影一区二区三区| 色播五月激情综合网| 51精品视频一区二区三区| 久久久久青草大香线综合精品| 亚洲婷婷综合久久一本伊一区| 午夜精品久久久久久久| 国产精品123区| 欧美日韩一区二区三区在线看 | 制服丝袜亚洲精品中文字幕| 久久美女艺术照精彩视频福利播放 | 成人黄色软件下载|