zoukankan      html  css  js  c++  java
  • 二维码限制扫描区域

      //scopeRect:限制的扫描区域范围

     _metadataOutput.rectOfInterest = [self rectOfInterestByScanViewRect:scopeRect];

      

    }

     

    - (CGRect)rectOfInterestByScanViewRect:(CGRect)rect {

        

        CGFloat width = SCREEN_WIDTH;

        CGFloat height = SCREEN_HEIGHT;

        

        CGFloat x = rect.origin.y/ height;

        CGFloat y = rect.origin.x/ width;

        

        CGFloat w = CGRectGetHeight(rect) / height;

        CGFloat h = CGRectGetWidth(rect) / width;

        

        return CGRectMake(x, y, w, h);

    }

  • 相关阅读:
    43前端
    42 前端
    python 列表
    python 字符串方法
    python while语句
    zhy2_rehat6_mysql02
    zhy2_rehat6_mysql01
    bay——安装_Oracle 12C-RAC-Centos7.txt
    bay——RAC_ASM ORA-15001 diskgroup DATA does not exist or is not mounted.docx
    bay——Oracle RAC集群体系结构.docx
  • 原文地址:https://www.cnblogs.com/pioneerMax/p/11171802.html
Copyright © 2011-2022 走看看