CN107818283A - Quick Response Code image pickup method, mobile terminal and computer-readable recording medium - Google Patents
Quick Response Code image pickup method, mobile terminal and computer-readable recording medium Download PDFInfo
- Publication number
- CN107818283A CN107818283A CN201711066951.9A CN201711066951A CN107818283A CN 107818283 A CN107818283 A CN 107818283A CN 201711066951 A CN201711066951 A CN 201711066951A CN 107818283 A CN107818283 A CN 107818283A
- Authority
- CN
- China
- Prior art keywords
- code
- image
- mobile terminal
- quick response
- response code
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Withdrawn
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/70—Circuitry for compensating brightness variation in the scene
- H04N23/74—Circuitry for compensating brightness variation in the scene by influencing the scene brightness using illuminating means
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06K—GRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
- G06K7/00—Methods or arrangements for sensing record carriers, e.g. for reading patterns
- G06K7/10—Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation
- G06K7/14—Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation using light without selection of wavelength, e.g. sensing reflected white light
- G06K7/1404—Methods for optical code recognition
- G06K7/146—Methods for optical code recognition the method including quality enhancement steps
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/50—Image enhancement or restoration by the use of more than one image, e.g. averaging, subtraction
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/70—Circuitry for compensating brightness variation in the scene
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20212—Image combination
- G06T2207/20221—Image fusion; Image merging
Abstract
The invention discloses a kind of Quick Response Code image pickup method, this method includes:When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling the flash lamp of the mobile terminal;When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;The shooting exposure of the mobile terminal camera is reduced, the second image in 2 D code is collected according to the shooting exposure after reduction;Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target image in 2 D code.The invention also discloses a kind of mobile terminal and a kind of computer-readable recording medium.The present invention can solve the problem that the technical problem that night Quick Response Code can not be identified normally caused by reflective.
Description
Technical field
The present invention relates to technical field of mobile terminals, more particularly to Quick Response Code image pickup method, mobile terminal and computer can
Read storage medium.
Background technology
At present, for user using mobile phone when scanning Quick Response Code at night, it is at night that mobile phone, which detects, it will usually is enabled automatically
Flash lamp with help camera obtain Quick Response Code information.However, because the light of flash lamp is stronger, can be formed on Quick Response Code anti-
Light, cause the part of Quick Response Code that a white portion occurs so that the two-dimensional code data in the region can not be by handset identity, pin
To such case, the angle that user would typically attempt to adjust mobile phone shoots Quick Response Code, until reflective white portion is without that
It is obvious, whole Quick Response Code exposure all than it is more uniform when, camera can just recognize Quick Response Code, and operation is very inconvenient, use
Family experience is poor.
The content of the invention
It is a primary object of the present invention to propose a kind of Quick Response Code image pickup method, mobile terminal and computer-readable storage medium
Matter, it is intended to solve the technical problem that night Quick Response Code can not be identified normally caused by reflective.
To achieve the above object, the present invention provides a kind of Quick Response Code image pickup method, and the Quick Response Code image pickup method is included such as
Lower step:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling
The flash lamp of the mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, is collected according to the shooting exposure after reduction
Second image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target Quick Response Code figure
Picture.
Alternatively, the shooting exposure for reducing the mobile terminal camera, exposes according to the shooting after reduction
Before luminosity collects the step of the second image in 2 D code, in addition to:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:Reduce the shooting exposure of the mobile terminal camera, root
The second image in 2 D code is collected according to the shooting exposure after reduction.
Alternatively, the shooting exposure for reducing the mobile terminal camera, exposes according to the shooting after reduction
Luminosity, which collects the step of the second image in 2 D code, to be included:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, with drop
The shooting exposure of the low mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
It is described that processing is overlapped to first image in 2 D code and second image in 2 D code, obtain target two dimension
The step of code image, includes:
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target
Image in 2 D code.
Alternatively, it is described that the exposure value of the mobile terminal camera and the flash lamp are adjusted according to the highlight area
Brightness, included with reducing the step of the shooting exposure of the mobile terminal camera:
Reduce exposure value of the mobile terminal camera in the highlight area, and during exposure value reduction
Whether the shooting exposure for detecting the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the sudden strain of a muscle is reduced
The brightness of light lamp is until the shooting exposure of the mobile terminal camera meets preparatory condition.
Alternatively, the Quick Response Code image pickup method also includes:
Identify the Quick Response Code in the target image in 2 D code.
In addition, to achieve the above object, the present invention also provides a kind of mobile terminal, and the mobile terminal includes:Memory,
Processor and the Quick Response Code photographing program that can be run on the memory and on the processor is stored in, the Quick Response Code is clapped
Following steps are realized when taking the photograph program by the computing device:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling
The flash lamp of the mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, is collected according to the shooting exposure after reduction
Second image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target Quick Response Code figure
Picture.
Alternatively, the Quick Response Code photographing program by the computing device when also realize following steps:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:Reduce the shooting exposure of the mobile terminal camera, root
The second image in 2 D code is collected according to the shooting exposure after reduction.
Alternatively, the Quick Response Code photographing program by the computing device when also realize following steps:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, with drop
The shooting exposure of the low mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target
Image in 2 D code.
Alternatively, the Quick Response Code photographing program by the computing device when also realize following steps:
Reduce exposure value of the mobile terminal camera in the highlight area, and during exposure value reduction
Whether the shooting exposure for detecting the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the sudden strain of a muscle is reduced
The brightness of light lamp is until the shooting exposure of the mobile terminal camera meets preparatory condition.
In addition, to achieve the above object, the present invention also provides a kind of computer-readable recording medium, described computer-readable
Quick Response Code photographing program is stored with storage medium, is realized when the Quick Response Code photographing program is executed by processor as described above
The step of Quick Response Code image pickup method.
The present invention judges whether mobile terminal is in shooting at night state when receiving Quick Response Code shooting instruction, if so,
Then enable the flash lamp of the mobile terminal;When the Quick Response Code being taken is illuminated by the flash lamp, the one or two is collected
Tie up code image;The shooting exposure of the mobile terminal camera is reduced, is gathered according to the shooting exposure after reduction
To the second image in 2 D code;Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains mesh
Mark image in 2 D code.The present invention adjusts the shooting exposure of mobile terminal camera by dynamic and gathers the front and rear two dimension of adjustment
Code image, and then the image in 2 D code collected is overlapped, the image in 2 D code after the superposition can be identified normally,
So as to solve the technical problem that night Quick Response Code can not be identified normally caused by reflective, Consumer's Experience is improved.
Brief description of the drawings
Fig. 1 is the device structure schematic diagram for the hardware running environment that scheme of the embodiment of the present invention is related to;
Fig. 2 is the schematic flow sheet of Quick Response Code image pickup method first embodiment of the present invention;
Fig. 3 is the schematic diagram of the first image in 2 D code in the embodiment of the present invention;
Fig. 4 is the schematic flow sheet of Quick Response Code image pickup method second embodiment of the present invention;
Fig. 5 is the region division schematic diagram of the first image in 2 D code in the embodiment of the present invention.
The realization, functional characteristics and advantage of the object of the invention will be described further referring to the drawings in conjunction with the embodiments.
Embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The primary solutions of the embodiment of the present invention are:When receiving Quick Response Code shooting instruction, judge that mobile terminal is
It is no to be in shooting at night state, if so, then enabling the flash lamp of the mobile terminal;When the Quick Response Code being taken is by the flash of light
When lamp illuminates, the first image in 2 D code is collected;The shooting exposure of the mobile terminal camera is reduced, after reduction
The shooting exposure collect the second image in 2 D code;To first image in 2 D code and the second Quick Response Code figure
As being overlapped processing, target image in 2 D code is obtained.
At present, for user using mobile phone when scanning Quick Response Code at night, it is at night that mobile phone, which detects, it will usually is enabled automatically
Flash lamp with help camera obtain Quick Response Code information.However, because the light of flash lamp is stronger, can be formed on Quick Response Code anti-
Light, cause the part of Quick Response Code that a white portion occurs so that the two-dimensional code data in the region can not be by handset identity, pin
To such case, the angle that user would typically attempt to adjust mobile phone shoots Quick Response Code, until reflective white portion is without that
It is obvious, whole Quick Response Code exposure all than it is more uniform when, camera can just recognize Quick Response Code, and operation is very inconvenient, use
Family experience is poor.
The present invention adjusts the shooting exposure of mobile terminal camera by dynamic and gathers the front and rear Quick Response Code figure of adjustment
Picture, and then the image in 2 D code collected is overlapped, the image in 2 D code after the superposition can be identified normally, so as to
Solve the technical problem that night Quick Response Code can not be identified normally caused by reflective, improve Consumer's Experience.
The present invention provides a kind of Quick Response Code image pickup method.
As shown in figure 1, Fig. 1 is the device structure schematic diagram for the hardware running environment that scheme of the embodiment of the present invention is related to.
Mobile terminal of the embodiment of the present invention can be that smart mobile phone, tablet personal computer, pocket computer etc. have shoot function
Packaged type terminal device.
As shown in figure 1, the mobile terminal can include:Processor 1001, such as CPU, network interface 1004, memory
1005, communication bus 1002.Wherein, communication bus 1002 is used to realize the connection communication between these components.Network interface
1004 can optionally include wireline interface, the wave point (such as WI-FI interfaces) of standard.Memory 1005 can be at a high speed
RAM memory or stable memory (non-volatile memory), such as magnetic disk storage.Memory 1005
The optional storage device that can also be independently of aforementioned processor 1001.
Alternatively, mobile terminal can also include camera, RF (Radio Frequency, radio frequency) circuit, sensor,
Voicefrequency circuit, WiFi module etc..Wherein, sensor ratio such as optical sensor, motion sensor and other sensors.Specifically
Ground, optical sensor may include ambient light sensor and proximity transducer, wherein, ambient light sensor can be according to the bright of ambient light
Secretly adjust the brightness of display screen, proximity transducer can close display screen and/or backlight when mobile terminal is moved in one's ear.
As one kind of motion sensor, gravity accelerometer can detect in all directions the big of (generally three axles) acceleration
It is small, size and the direction of gravity are can detect that when static, (for example horizontal/vertical screen is cut available for the application of identification mobile terminal posture
Change, dependent game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, tap) etc.;Certainly, mobile terminal
The other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared ray sensor are can also configure, will not be repeated here.
It will be understood by those skilled in the art that the restriction of the mobile terminal structure shown in Fig. 1 not structure paired terminal, can
With including than illustrating more or less parts, either combining some parts or different parts arrangement.
As shown in figure 1, it can lead to as in a kind of memory 1005 of computer-readable storage medium including operating system, network
Believe module, Subscriber Interface Module SIM and Quick Response Code photographing program.
In the mobile terminal shown in Fig. 1, network interface 1004 is mainly used in connecting background server, with background server
Enter row data communication;Processor 1001 can be used for calling the Quick Response Code photographing program that stores in memory 1005, and perform with
Lower operation:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling
The flash lamp of the mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, is collected according to the shooting exposure after reduction
Second image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target Quick Response Code figure
Picture.
Further, processor 1001 can call the Quick Response Code photographing program stored in memory 1005, also perform with
Lower operation:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:Reduce the shooting exposure of the mobile terminal camera, root
The second image in 2 D code is collected according to the shooting exposure after reduction.
Further, processor 1001 can call the Quick Response Code photographing program stored in memory 1005, also perform with
Lower operation:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, with drop
The shooting exposure of the low mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target
Image in 2 D code.
Further, processor 1001 can call the Quick Response Code photographing program stored in memory 1005, also perform with
Lower operation:
Reduce exposure value of the mobile terminal camera in the highlight area, and during exposure value reduction
Whether the shooting exposure for detecting the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the sudden strain of a muscle is reduced
The brightness of light lamp is until the shooting exposure of the mobile terminal camera meets preparatory condition.
Further, processor 1001 can call the Quick Response Code photographing program stored in memory 1005, also perform with
Lower operation:
Identify the Quick Response Code in the target image in 2 D code.
Each specific embodiment of the specific embodiment of mobile terminal of the present invention and following Quick Response Code image pickup methods is essentially identical,
Therefore not to repeat here.
Based on above-mentioned hardware configuration, Quick Response Code image pickup method embodiment of the present invention is proposed.
Reference picture 2, Fig. 2 are the schematic flow sheet of Quick Response Code image pickup method first embodiment of the present invention, and methods described includes:
Step S10, when receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if
It is then to enable the flash lamp of the mobile terminal;
The present embodiment Quick Response Code image pickup method is applied to mobile terminal, and the mobile terminal can be smart mobile phone, flat board electricity
Brain, pocket computer etc. have the packaged type terminal device of shoot function, are illustrated below by taking smart mobile phone as an example.
At present, the operation scenario that many users scan Quick Response Code using mobile phone is at night, at this moment has one and opens and dodges
Light lamp illuminates Quick Response Code and scans the process of Quick Response Code, but flash lamp can also produce while Quick Response Code is illuminated on Quick Response Code
Life is reflective, and ultimately resulting in Quick Response Code can not be identified, therefore, the present embodiment proposes the Quick Response Code shooting side under a kind of night scenes
Method.
First, when user needs to shoot and identifies a certain image in 2 D code, the related control of mobile terminal can be passed through
Quick Response Code shooting instruction is triggered, when mobile terminal receives Quick Response Code shooting instruction, whether judgement is currently in shooting at night
State, the mode of judgement can be:The image brightness values in current view-finder are detected, when image brightness values are less than default brightness
During value, then judge that mobile terminal is in shooting at night state;Now, mobile terminal enables flash lamp and keeps flash lamp to be in normal
Bright state, so as to illuminate the Quick Response Code for needing to shoot.
Step S20, when the Quick Response Code being taken is illuminated by the flash lamp, collect the first image in 2 D code;
When the Quick Response Code being taken is illuminated by flash lamp, mobile terminal collects the first Quick Response Code by camera
Image.Due to reflective, first image in 2 D code may include a highlight area, as shown in figure 3, Fig. 3 is the present invention
The schematic diagram of first image in 2 D code in embodiment.
Further, after step S20, can also include:Identify the Quick Response Code in first image in 2 D code;When
When the Quick Response Code is identified successfully, illustrate the highlight area for influenceing Quick Response Code identification is not present in the first image in 2 D code, now
Quick Response Code can normally be identified;When the Quick Response Code recognition failures, illustrating to exist in the first image in 2 D code influences Quick Response Code
The highlight area of identification, now need to carry out shooting adjustment, that is, perform step S30.
Step S30, the shooting exposure of the mobile terminal camera is reduced, according to the shooting exposure after reduction
Collect the second image in 2 D code;
Then, mobile terminal reduces the shooting exposure of camera, and is collected according to the shooting exposure after reduction
Second image in 2 D code.Because the shooting exposure of camera is bigger, the brightness of shooting image is higher, therefore, reduces camera
Shooting exposure, the brightness for the image that is taken can be effectively reduced, so as to eliminate the highlight area that can not be identified.
Specifically, reducing a kind of mode of the shooting exposure of mobile terminal camera can be:Reduce mobile terminal to take the photograph
As the exposure value of head.Because exposure value is bigger, the image that is taken is brighter, and therefore, the exposure value for reducing mobile terminal camera can
To reduce the brightness of mobile terminal shooting image, so as to eliminate the bloom part being taken in image, showing its image becomes
Clearly.In addition, when reducing the exposure value of mobile terminal camera, it can only reduce mobile terminal camera in the first Quick Response Code
The exposure value of highlight area in image, exposure value of the mobile terminal camera based on whole shooting image can also be reduced, had
Body can flexibly be set when implementing.
Reducing the another way of the shooting exposure of mobile terminal camera can be:Reduce mobile terminal flash lamp
Brightness value.Because brightness of flash lamp value is bigger, the image that is taken is brighter, and therefore, the brightness value for reducing mobile terminal flash lamp can
To reduce the brightness of mobile terminal shooting image, so as to eliminate the bloom part being taken in image, showing its image becomes
Clearly, wherein, the electric current of flash lamp can be flowed through to realize by reducing by reducing the brightness value of mobile terminal flash lamp.
It should be noted that to ensure that the second image in 2 D code can clearly be shown, can be by above two during specific implementation
Mode is combined, so that the shooting exposure of mobile terminal camera meets preparatory condition.For example it first can progressively reduce shifting
The exposure value of dynamic terminal camera, the brightness value of mobile terminal flash lamp is then gradually reduced, or, first gradually reduce mobile whole
The brightness value of flash lamp is held, then progressively reduces the exposure value of mobile terminal camera, or, while reduce mobile terminal camera
Exposure value and reduce the brightness value of mobile terminal flash lamp, until the shooting exposure of mobile terminal camera meets default bar
Part, can flexibly it set during specific implementation.
When the shooting exposure of mobile terminal camera meets preparatory condition, mobile terminal is gathered by camera
To the second image in 2 D code.
Step S40, processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target
Image in 2 D code.
Afterwards, mobile terminal is overlapped processing to the first image in 2 D code and the second image in 2 D code, obtains target two
Tie up code image.Its stacked system can be:The highlight area in the first image in 2 D code is identified, and obtains the position of the highlight area
Put and size, the region of same location and size is intercepted in the second image in 2 D code simultaneously according to the position of the highlight area and size
Itself and the non-highlight area in the first image in 2 D code are spliced, so as to obtain the complete image in 2 D code of a frame, simultaneously
To balance brightness of image, spliced image can also be subjected to brightness uniformity processing, so as to obtain final target two dimension
Code image.In addition, stacked system can also be:Directly by the non-highlight area in the first image in 2 D code and the second Quick Response Code figure
As being overlapped, so as to obtain the complete image in 2 D code of a frame, and brightness uniformity is carried out to the complete image in 2 D code
Processing, stacked system can be selected flexibly during specific implementation.
Further, after the step s 40, can also include:Identify the Quick Response Code in the target image in 2 D code.
After obtaining target image in 2 D code, mobile terminal identifies Quick Response Code therein according to the target image in 2 D code.By above-mentioned
Quick Response Code shooting process, user need not manually adjust the angle of mobile phone, and need to only keep camera being directed at Quick Response Code, you can know
Do not go out 2 D code information, so as to simplify user's operation, improve Consumer's Experience.
In the present embodiment, when receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night shape
State, if so, then enabling the flash lamp of the mobile terminal;When the Quick Response Code being taken is illuminated by the flash lamp, gather
To the first image in 2 D code;The shooting exposure of the mobile terminal camera is reduced, is exposed according to the shooting after reduction
Degree collects the second image in 2 D code;Place is overlapped to first image in 2 D code and second image in 2 D code
Reason, obtains target image in 2 D code.The present embodiment adjusts the shooting exposure of mobile terminal camera by dynamic and gathers tune
Whole front and rear image in 2 D code, and then the image in 2 D code collected is overlapped, the image in 2 D code after the superposition can
It is enough normally to be identified, so as to solve the technical problem that night Quick Response Code can not be identified normally caused by reflective, carry
Consumer's Experience is risen.
Further, reference picture 4, Fig. 4 are the schematic flow sheet of Quick Response Code image pickup method second embodiment of the present invention.It is based on
Embodiment shown in above-mentioned Fig. 2, step S30 can include:
Step S31, first image in 2 D code is divided into normal region and highlight area;
Step S32, the exposure value of the mobile terminal camera and the flash lamp are adjusted according to the highlight area
Brightness, to reduce the shooting exposure of the mobile terminal camera;
Step S33, when the shooting exposure after reduction meets preparatory condition, collect the second Quick Response Code figure
Picture;
Now step S40 could alternatively be:Step S41, by the normal region in first image in 2 D code and described
Second image in 2 D code is overlapped, and obtains target image in 2 D code.
In the present embodiment, when gathering the second image in 2 D code, mobile terminal can be first by the first image in 2 D code
It is divided into normal region and highlight area.Reference picture 5, Fig. 5 are the region division of the first image in 2 D code in the embodiment of the present invention
Schematic diagram.The standard specifically divided can be:Brightness in first image in 2 D code is less than the region of predetermined luminance as normal
Region, brightness is more than or equal to the region of predetermined luminance as highlight area, or, by can be just in the first image in 2 D code
The region of two-dimensional code data is often read as normal region, it is impossible to which the normal region for reading two-dimensional code data is as specular
Domain.
Then, mobile terminal adjusts the brightness of the exposure value and flash lamp of camera according to highlight area, to reduce movement
The shooting exposure of terminal camera.As a kind of embodiment, step S32 can include:Reduce the mobile terminal shooting
Head and detects the shooting of the mobile terminal camera in the exposure value of the highlight area during exposure value reduction
Whether exposure meets preparatory condition;When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for default bar
During part, the brightness of the flash lamp is reduced until the shooting exposure of the mobile terminal camera meets preparatory condition.Wherein,
Mobile terminal can progressively reduce exposure value of the camera in the highlight area according to the position of highlight area and size, if adjustment
Quick Response Code to highlight area during a certain exposure value becomes enough to clear or can normally be identified, then can be determined that it is mobile eventually
The shooting exposure of end camera meets preparatory condition, conversely, shooting exposure when exposure value is decreased to preset value and being still discontented with
During sufficient preparatory condition, then the brightness of flash lamp is reduced until the shooting exposure of mobile terminal camera meets preparatory condition, by
This can realize elimination highlight area, and premise is provided for the normal identification of succeeding target image in 2 D code.Certainly, it is mobile
Terminal can also gradually reduce the brightness of flash lamp first, shoot exposure in luminance-reduction to preset value and be still unsatisfactory for presetting
During condition, reduce exposure value of the mobile terminal camera in the highlight area, until the shooting of mobile terminal camera exposes
Degree meets preparatory condition, and specific adjustment mode can be selected flexibly.
The adjustment mode that the present embodiment is combined using the brightness of the exposure value and flash lamp of mobile terminal camera, can
The reflective influence to Quick Response Code shooting is at utmost reduced, so as to ensure that follow-up Quick Response Code can be identified normally, is improved
Consumer's Experience.
The present invention also provides a kind of computer-readable recording medium.
Quick Response Code photographing program is stored with computer-readable recording medium of the present invention, the Quick Response Code photographing program is located
Reason device realizes following steps when performing:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling
The flash lamp of the mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, is collected according to the shooting exposure after reduction
Second image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target Quick Response Code figure
Picture.
Further, following steps are also realized when the Quick Response Code photographing program is executed by processor:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:Reduce the shooting exposure of the mobile terminal camera, root
The second image in 2 D code is collected according to the shooting exposure after reduction.
Further, following steps are also realized when the Quick Response Code photographing program is executed by processor:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, with drop
The shooting exposure of the low mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target
Image in 2 D code.
Further, following steps are also realized when the Quick Response Code photographing program is executed by processor:
Reduce exposure value of the mobile terminal camera in the highlight area, and during exposure value reduction
Whether the shooting exposure for detecting the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the sudden strain of a muscle is reduced
The brightness of light lamp is until the shooting exposure of the mobile terminal camera meets preparatory condition.
Further, following steps are also realized when the Quick Response Code photographing program is executed by processor:
Identify the Quick Response Code in the target image in 2 D code.
Wherein, the method that the Quick Response Code photographing program run on the processor is realized when being performed can refer to this hair
Bright Quick Response Code image pickup method embodiment, here is omitted.
It should be noted that herein, term " comprising ", "comprising" or its any other variant are intended to non-row
His property includes, so that process, method, article or system including a series of elements not only include those key elements, and
And also include the other element being not expressly set out, or also include for this process, method, article or system institute inherently
Key element.In the absence of more restrictions, the key element limited by sentence "including a ...", it is not excluded that including this
Other identical element also be present in the process of key element, method, article or system.
The embodiments of the present invention are for illustration only, do not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side
Method can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but in many cases
The former is more preferably embodiment.Based on such understanding, technical scheme is substantially done to prior art in other words
Going out the part of contribution can be embodied in the form of software product, and the computer software product is stored in one as described above
In storage medium (such as ROM/RAM, magnetic disc, CD), including some instructions to cause a station terminal equipment (can be mobile phone,
Computer, server, air conditioner, or network equipment etc.) perform method described in each embodiment of the present invention.
The preferred embodiments of the present invention are these are only, are not intended to limit the scope of the invention, it is every to utilize this hair
The equivalent structure or equivalent flow conversion that bright specification and accompanying drawing content are made, or directly or indirectly it is used in other related skills
Art field, is included within the scope of the present invention.
Claims (10)
1. a kind of Quick Response Code image pickup method, it is characterised in that the Quick Response Code image pickup method comprises the following steps:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling described
The flash lamp of mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, second is collected according to the shooting exposure after reduction
Image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target image in 2 D code.
2. Quick Response Code image pickup method as claimed in claim 1, it is characterised in that the reduction mobile terminal camera
Exposure is shot, before the step of collecting the second image in 2 D code according to the shooting exposure after reduction, in addition to:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:The shooting exposure of the mobile terminal camera is reduced, according to drop
The shooting exposure after low collects the second image in 2 D code.
3. Quick Response Code image pickup method as claimed in claim 1 or 2, it is characterised in that described to reduce the mobile terminal shooting
The shooting exposure of head, the step of collecting the second image in 2 D code according to the shooting exposure after reduction, include:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, to reduce
State the shooting exposure of mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
It is described that processing is overlapped to first image in 2 D code and second image in 2 D code, obtain target Quick Response Code figure
The step of picture, includes:
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target two dimension
Code image.
4. Quick Response Code image pickup method as claimed in claim 3, it is characterised in that described according to highlight area adjustment
The brightness of the exposure value of mobile terminal camera and the flash lamp, to reduce the shooting exposure of the mobile terminal camera
The step of include:
Reduce exposure value of the mobile terminal camera in the highlight area, and detected during exposure value reduction
Whether the shooting exposure of the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the flash lamp is reduced
Brightness until the shooting exposure of the mobile terminal camera meets preparatory condition.
5. Quick Response Code image pickup method as claimed in claim 1, it is characterised in that the Quick Response Code image pickup method also includes:
Identify the Quick Response Code in the target image in 2 D code.
6. a kind of mobile terminal, it is characterised in that the mobile terminal includes:Memory, processor and it is stored in the storage
On device and the Quick Response Code photographing program that can run on the processor, the Quick Response Code photographing program is by the computing device
Shi Shixian following steps:
When receiving Quick Response Code shooting instruction, judge whether mobile terminal is in shooting at night state, if so, then enabling described
The flash lamp of mobile terminal;
When the Quick Response Code being taken is illuminated by the flash lamp, the first image in 2 D code is collected;
The shooting exposure of the mobile terminal camera is reduced, second is collected according to the shooting exposure after reduction
Image in 2 D code;
Processing is overlapped to first image in 2 D code and second image in 2 D code, obtains target image in 2 D code.
7. mobile terminal as claimed in claim 6, it is characterised in that the Quick Response Code photographing program is by the computing device
When also realize following steps:
Identify the Quick Response Code in first image in 2 D code;
When the Quick Response Code recognition failures, step is performed:The shooting exposure of the mobile terminal camera is reduced, according to drop
The shooting exposure after low collects the second image in 2 D code.
8. mobile terminal as claimed in claims 6 or 7, it is characterised in that the Quick Response Code photographing program is by the processor
Following steps are also realized during execution:
First image in 2 D code is divided into normal region and highlight area;
The brightness of the exposure value and the flash lamp of the mobile terminal camera is adjusted according to the highlight area, to reduce
State the shooting exposure of mobile terminal camera;
When the shooting exposure after reduction meets preparatory condition, the second image in 2 D code is collected;
Normal region in first image in 2 D code and second image in 2 D code are overlapped, obtain target two dimension
Code image.
9. mobile terminal as claimed in claim 8, it is characterised in that the Quick Response Code photographing program is by the computing device
When also realize following steps:
Reduce exposure value of the mobile terminal camera in the highlight area, and detected during exposure value reduction
Whether the shooting exposure of the mobile terminal camera meets preparatory condition;
When the exposure value is decreased to preset value and the shooting exposure is still unsatisfactory for preparatory condition, the flash lamp is reduced
Brightness until the shooting exposure of the mobile terminal camera meets preparatory condition.
10. a kind of computer-readable recording medium, it is characterised in that be stored with Quick Response Code on the computer-readable recording medium
Photographing program, the two dimension as any one of claim 1 to 5 is realized when the Quick Response Code photographing program is executed by processor
The step of code image pickup method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711066951.9A CN107818283A (en) | 2017-11-02 | 2017-11-02 | Quick Response Code image pickup method, mobile terminal and computer-readable recording medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711066951.9A CN107818283A (en) | 2017-11-02 | 2017-11-02 | Quick Response Code image pickup method, mobile terminal and computer-readable recording medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107818283A true CN107818283A (en) | 2018-03-20 |
Family
ID=61604053
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711066951.9A Withdrawn CN107818283A (en) | 2017-11-02 | 2017-11-02 | Quick Response Code image pickup method, mobile terminal and computer-readable recording medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107818283A (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109190436A (en) * | 2018-07-30 | 2019-01-11 | 努比亚技术有限公司 | A kind of two-dimensional code identification method, mobile terminal and storage medium |
CN109274791A (en) * | 2018-09-30 | 2019-01-25 | 联想(北京)有限公司 | A kind of processing method, device and electronic equipment |
CN109492451A (en) * | 2018-10-30 | 2019-03-19 | 维沃移动通信有限公司 | A kind of coded image recognition methods and mobile terminal |
CN110475079A (en) * | 2019-09-10 | 2019-11-19 | 上海快仓智能科技有限公司 | A kind of image exposure luminance regulating method, system and associated component |
CN112036201A (en) * | 2020-08-06 | 2020-12-04 | 浙江大华技术股份有限公司 | Image processing method, device, equipment and medium |
CN112241642A (en) * | 2019-07-19 | 2021-01-19 | 杭州海康威视数字技术股份有限公司 | Two-dimensional code identification method, device, equipment and storage medium |
CN113065374A (en) * | 2021-04-01 | 2021-07-02 | 支付宝(杭州)信息技术有限公司 | Two-dimensional code identification method, device and equipment |
CN113194253A (en) * | 2021-04-28 | 2021-07-30 | 维沃移动通信有限公司 | Shooting method and device for removing image reflection and electronic equipment |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100252635A1 (en) * | 2009-04-02 | 2010-10-07 | Symbol Technologies, Inc. | Exposure control for multi-imaging scanner |
CN104200189A (en) * | 2014-08-27 | 2014-12-10 | 苏州佳世达电通有限公司 | Barcode scanning device and processing method thereof |
CN105574457A (en) * | 2015-12-15 | 2016-05-11 | 东软集团股份有限公司 | Light supplementing method and device for scanning terminal |
CN105956510A (en) * | 2016-04-29 | 2016-09-21 | 苏州佳世达光电有限公司 | Bar code processing method and bar code scanning device |
CN106156684A (en) * | 2016-06-30 | 2016-11-23 | 南京理工大学 | A kind of two-dimensional code identification method and device |
CN107220578A (en) * | 2017-05-31 | 2017-09-29 | 维沃移动通信有限公司 | A kind of two-dimensional code scanning recognition methods, device, mobile terminal and storage medium |
-
2017
- 2017-11-02 CN CN201711066951.9A patent/CN107818283A/en not_active Withdrawn
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100252635A1 (en) * | 2009-04-02 | 2010-10-07 | Symbol Technologies, Inc. | Exposure control for multi-imaging scanner |
CN104200189A (en) * | 2014-08-27 | 2014-12-10 | 苏州佳世达电通有限公司 | Barcode scanning device and processing method thereof |
CN105574457A (en) * | 2015-12-15 | 2016-05-11 | 东软集团股份有限公司 | Light supplementing method and device for scanning terminal |
CN105956510A (en) * | 2016-04-29 | 2016-09-21 | 苏州佳世达光电有限公司 | Bar code processing method and bar code scanning device |
CN106156684A (en) * | 2016-06-30 | 2016-11-23 | 南京理工大学 | A kind of two-dimensional code identification method and device |
CN107220578A (en) * | 2017-05-31 | 2017-09-29 | 维沃移动通信有限公司 | A kind of two-dimensional code scanning recognition methods, device, mobile terminal and storage medium |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109190436A (en) * | 2018-07-30 | 2019-01-11 | 努比亚技术有限公司 | A kind of two-dimensional code identification method, mobile terminal and storage medium |
CN109274791A (en) * | 2018-09-30 | 2019-01-25 | 联想(北京)有限公司 | A kind of processing method, device and electronic equipment |
US11212455B2 (en) | 2018-09-30 | 2021-12-28 | Lenovo (Beijing) Co., Ltd. | Processing method, apparatus, and electronic device |
CN109492451A (en) * | 2018-10-30 | 2019-03-19 | 维沃移动通信有限公司 | A kind of coded image recognition methods and mobile terminal |
CN112241642A (en) * | 2019-07-19 | 2021-01-19 | 杭州海康威视数字技术股份有限公司 | Two-dimensional code identification method, device, equipment and storage medium |
CN112241642B (en) * | 2019-07-19 | 2024-02-23 | 杭州海康威视数字技术股份有限公司 | Two-dimensional code identification method, device, equipment and storage medium |
CN110475079A (en) * | 2019-09-10 | 2019-11-19 | 上海快仓智能科技有限公司 | A kind of image exposure luminance regulating method, system and associated component |
CN112036201A (en) * | 2020-08-06 | 2020-12-04 | 浙江大华技术股份有限公司 | Image processing method, device, equipment and medium |
CN113065374A (en) * | 2021-04-01 | 2021-07-02 | 支付宝(杭州)信息技术有限公司 | Two-dimensional code identification method, device and equipment |
CN113065374B (en) * | 2021-04-01 | 2023-10-27 | 支付宝(杭州)信息技术有限公司 | Two-dimensional code identification method, device and equipment |
CN113194253A (en) * | 2021-04-28 | 2021-07-30 | 维沃移动通信有限公司 | Shooting method and device for removing image reflection and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107818283A (en) | Quick Response Code image pickup method, mobile terminal and computer-readable recording medium | |
US9451173B2 (en) | Electronic device and control method of the same | |
US9819870B2 (en) | Photographing method and electronic device | |
CN108024065B (en) | Terminal shooting method, terminal and computer readable storage medium | |
CN108399349B (en) | Image recognition method and device | |
CN105282430B (en) | Electronic device using composition information of photograph and photographing method using the same | |
US20180032815A1 (en) | Electronic device and method for iris authentication thereof | |
KR102263537B1 (en) | Electronic device and control method of the same | |
CN107087118B (en) | Photographic method, device, storage medium and terminal | |
CN107566752B (en) | Shooting method, terminal and computer storage medium | |
CN105472246B (en) | Camera arrangement and method | |
CN113890989B (en) | Shooting method and electronic device | |
EP3110134B1 (en) | Electronic device and method for processing image | |
CN108989678B (en) | Image processing method and mobile terminal | |
CN108234882B (en) | Image blurring method and mobile terminal | |
CN109194882A (en) | Image processing method, device, electronic equipment and storage medium | |
CN110430357B (en) | Image shooting method and electronic equipment | |
CN113411498B (en) | Image shooting method, mobile terminal and storage medium | |
CN110930335B (en) | Image processing method and electronic equipment | |
US11563889B2 (en) | Electronic device and method for controlling camera using external electronic device | |
US11153498B2 (en) | Image processing method and electronic device supporting same | |
US9942483B2 (en) | Information processing device and method using display for auxiliary light | |
CN108616687B (en) | Photographing method and device and mobile terminal | |
CN114424520A (en) | Image processing method and electronic device supporting the same | |
US10685216B2 (en) | Method for collecting facial information and related devices |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WW01 | Invention patent application withdrawn after publication | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20180320 |