Unlock instant, AI-driven research and patent intelligence for your innovation.

Method and device for scanning two-dimensional code

A technology of two-dimensional codes and scanning frames, applied in the field of scanning two-dimensional codes, can solve the problems of low decoding efficiency and long time consumption, and achieve the effect of improving decoding efficiency

Inactive Publication Date: 2016-09-07
FEITIAN TECHNOLOGIES
View PDF2 Cites 5 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] In the prior art, when scanning a two-dimensional code, the user is required to place the two-dimensional code image in the preview frame of the camera, and the image acquired through the preview frame of the camera includes the two-dimensional code image and the image other than the two-dimensional code image. Other images; when parsing images, it is necessary to parse all the images obtained through the preview frame of the camera, making the decoding efficiency low and time-consuming

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for scanning two-dimensional code
  • Method and device for scanning two-dimensional code
  • Method and device for scanning two-dimensional code

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0022] Embodiment 1 of the present invention provides a method for scanning a two-dimensional code, such as figure 1 shown, including:

[0023] Step S1: the application starts the system camera;

[0024] Step S1 specifically includes:

[0025] The application sets the callback of the interface controller, and the application creates a camera object; the application obtains the current camera parameters according to the created camera object; the application starts the camera preview frame of the system camera according to the camera object.

[0026] Step S2: The application obtains the camera image through the camera preview frame of the system camera, rotates the camera image, and obtains the corresponding image in the rotated camera image according to the position of the rotated camera image and the scanning frame image in the rotated camera image. The scan frame image corresponding to the scan frame;

[0027] Step S3: The application decodes the acquired scanning frame i...

Embodiment 2

[0063] Embodiment 2 of the present invention provides a method for scanning a two-dimensional code, such as figure 2 and image 3 shown, including:

[0064] Step 101: The application obtains the object of the parent layout of the current application according to the preset object ID of the parent layout of the current application, obtains the object of the scan frame layout according to the preset object ID of the scan frame layout, and obtains the object of the scan frame layout according to the preset interface view control ID. Controls of the interface view class, that is, interface view objects;

[0065] Specifically, the application calls the system method findViewById method to obtain the object mContainer of the current application parent layout according to the preset object ID of the current application parent layout; according to the preset object ID of the scan frame layout, calls the system method findViewById method to obtain the scan frame layout The object mC...

Embodiment 3

[0175] This embodiment provides a device for scanning two-dimensional codes, such as Figure 5 As shown, it includes: a startup module 01, a first acquisition module 02 and a decoding module 03;

[0176] Start module 01, used to start the system camera;

[0177] Wherein, the startup module 01 includes an interface control submodule, a first creation submodule, a first startup submodule and a fifth acquisition submodule;

[0178] The interface control sub-module is used to set the callback of the interface controller;

[0179] First create a sub-module, which is used to create a camera object after the interface control sub-module sets the callback of the interface controller;

[0180] The fifth obtaining sub-module is used to obtain the current camera parameters according to the camera object created by the first creating sub-module;

[0181] The first launching submodule is configured to start the camera preview frame of the system camera according to the camera object cre...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The present invention discloses a method and device for scanning a two-dimensional code. The method comprises the steps that an application starts a system camera; the application obtains a camera image through the camera preview frame of the system camera, rotates the camera image, and obtains a scanning frame image corresponding to a scanning frame in the rotated camera image according to the rotated camera image and the position of a scanning frame image in the rotated camera image; and the application decodes the obtained scanning frame image. According to the invention, only the scanning frame image which comprises a two-dimensional code image corresponding to the scanning frame in the camera preview frame is analyzed, the analysis of other images outside the scanning frame is not needed, and the decoding efficiency is improved.

Description

technical field [0001] The present invention relates to the communication field, in particular to a method and device for scanning two-dimensional codes. Background technique [0002] Two-dimensional bar code / two-dimensional bar code (2-dimensional bar code) is a black and white graphic distributed on a plane (two-dimensional direction) with a specific geometric figure according to certain rules. It can be used to record data symbol information and has high Density coding, large information capacity, wide coding range and so on. [0003] In the prior art, when scanning a two-dimensional code, the user is required to place the two-dimensional code image in the preview frame of the camera, and the image acquired through the preview frame of the camera includes the two-dimensional code image and the image other than the two-dimensional code image. Other images; when parsing an image, it is necessary to parse all the images obtained through the preview frame of the camera, whic...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06K7/10G06K7/14
CPCG06K7/10722G06K7/1417
Inventor 陆舟于华章
Owner FEITIAN TECHNOLOGIES