CN107509034B - A kind of image pickup method and mobile terminal - Google Patents

A kind of image pickup method and mobile terminal Download PDF

Info

Publication number
CN107509034B
CN107509034B CN201710865596.5A CN201710865596A CN107509034B CN 107509034 B CN107509034 B CN 107509034B CN 201710865596 A CN201710865596 A CN 201710865596A CN 107509034 B CN107509034 B CN 107509034B
Authority
CN
China
Prior art keywords
picture frame
target
timestamp
mobile terminal
frame
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.)
Active
Application number
CN201710865596.5A
Other languages
Chinese (zh)
Other versions
CN107509034A (en
Inventor
吴再稳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN201710865596.5A priority Critical patent/CN107509034B/en
Publication of CN107509034A publication Critical patent/CN107509034A/en
Application granted granted Critical
Publication of CN107509034B publication Critical patent/CN107509034B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/68Control of cameras or camera modules for stable pick-up of the scene, e.g. compensating for camera body vibrations
    • H04N23/681Motion detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/68Control of cameras or camera modules for stable pick-up of the scene, e.g. compensating for camera body vibrations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/68Control of cameras or camera modules for stable pick-up of the scene, e.g. compensating for camera body vibrations
    • H04N23/682Vibration or motion blur correction
    • H04N23/683Vibration or motion blur correction performed by a processor, e.g. controlling the readout of an image memory

Abstract

The present invention provides a kind of image pickup method and mobile terminal, this method comprises:, if receiving photographing instruction, detecting whether mobile terminal is shaken during caching the preview image of camera acquisition;If detecting, mobile terminal is shaken, and obtains jitter amplitude value;According to jitter amplitude value, target cache picture frame is determined;The picture frame for meeting preset condition is chosen from target cache picture frame as target shooting image.In this way, when mobile terminal receives photographing instruction, if mobile terminal is shaken, the jitter amplitude value of available mobile terminal.And then target cache picture frame can be determined according to jitter amplitude value.Finally, the picture frame for meeting preset condition can be chosen from target cache picture frame as target shooting image.The photo of shooting is than more visible, perfect photograph taking effect.

Description

A kind of image pickup method and mobile terminal
Technical field
The present invention relates to field of communication technology more particularly to a kind of image pickup methods and mobile terminal.
Background technique
Currently, the function that mobile terminal has is more and more diversified.For example, audio-frequency function, camera function, camera function All have become the necessary functions of mobile terminal with store function etc..
It is all many caching (buffer) data of caching in the prior art for camera function.When receiving photographing command When, just take a frame data to be pushed to user from data cached.If user is when pressing shoot button, firmly larger, will Mobile terminal is caused to have shaking by a relatively large margin, shooting the photo come in this way will be relatively fuzzyyer.Therefore, in the prior art, If the hand of user is shaken in shooting process, captured image can be obscured.
Summary of the invention
The embodiment of the present invention provides a kind of image pickup method and mobile terminal, to solve trembling due to user hand in shooting process The fuzzy problem of dynamic bring shooting image.
In order to solve the above-mentioned technical problem, the present invention is implemented as follows: a kind of image pickup method, comprising:
During caching the preview image of camera acquisition, if receiving photographing instruction, detecting mobile terminal is It is no to shake;
If detecting, mobile terminal is shaken, and obtains jitter amplitude value;
According to the jitter amplitude value, target cache picture frame is determined;
The picture frame for meeting preset condition is chosen from the target cache picture frame as target shooting image.
In a first aspect, the embodiment of the invention provides a kind of image pickup methods, comprising:
During caching the preview image of camera acquisition, if receiving photographing instruction, detecting mobile terminal is It is no to shake;
If detecting, mobile terminal is shaken, and obtains jitter amplitude value;
According to the jitter amplitude value, target cache picture frame is determined;
The picture frame for meeting preset condition is chosen from the target cache picture frame as target shooting image.
Second aspect, the embodiment of the present invention also provide a kind of mobile terminal, comprising:
Detection module, for if receiving photographing instruction, examining during caching the preview image of camera acquisition Survey whether mobile terminal is shaken;
First obtains module, if obtaining jitter amplitude value for detecting that mobile terminal is shaken;
Determining module, for determining target cache picture frame according to the jitter amplitude value;
Module is chosen, for choosing the picture frame for meeting preset condition from the target cache picture frame as target bat Take the photograph image.
The third aspect, the embodiment of the present invention also provide a kind of mobile terminal, which is characterized in that including processor, memory And it is stored in the computer program that can be run on the memory and on the processor, the computer program is by the place The step of reason device realizes above-mentioned image pickup method when executing.
Fourth aspect, the embodiment of the present invention also provide a kind of computer-readable storage medium, which is characterized in that the meter Computer program is stored on calculation machine read/write memory medium, the computer program realizes above-mentioned shooting when being executed by processor The step of method.
In this way, in the embodiment of the present invention, during caching the preview image of camera acquisition, if receiving finger of taking pictures It enables, then detects whether mobile terminal is shaken;If detecting, mobile terminal is shaken, and obtains jitter amplitude value;According to The jitter amplitude value, determines target cache picture frame;The figure for meeting preset condition is chosen from the target cache picture frame As frame shoots image as target.In this way, when mobile terminal receives photographing instruction, it, can if mobile terminal is shaken To obtain the jitter amplitude value of mobile terminal.And then target cache picture frame can be determined according to jitter amplitude value.Finally, can Image is shot as target using the picture frame that selection meets preset condition from target cache picture frame.The photo of shooting is more clear It is clear, perfect photograph taking effect.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, needed in being described below to the embodiment of the present invention Attached drawing to be used is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, For those of ordinary skill in the art, without any creative labor, it can also obtain according to these attached drawings Obtain other attached drawings.
Fig. 1 is one of the flow chart of image pickup method of mobile terminal provided in an embodiment of the present invention;
Fig. 2 is that in the prior art take pictures provided in an embodiment of the present invention takes frame schematic diagram;
Fig. 3 is the schematic diagram provided in an embodiment of the present invention for establishing three-dimensional cartesian coordinate system on mobile terminals;
Fig. 4 is a kind of schematic diagram of the mode of determining target shooting image provided in an embodiment of the present invention;
Fig. 5 is the two of the flow chart of image pickup method provided in an embodiment of the present invention;
Fig. 6 is that the data that a kind of cache image frame queue provided in an embodiment of the present invention and gravity sensor export form The schematic diagram of buffer queue;
Fig. 7 is the three of the flow chart of image pickup method provided in an embodiment of the present invention;
Fig. 8 is the data composition of another cache image frame queue provided in an embodiment of the present invention and gravity sensor output Buffer queue schematic diagram;
Fig. 9 is one of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 10 is the two of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 11 is the three of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 12 is the four of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 13 is the five of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 14 is the six of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 15 is the seven of the structure chart of mobile terminal provided in an embodiment of the present invention;
Figure 16 is the eight of the structure chart of mobile terminal provided in an embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are some of the embodiments of the present invention, instead of all the embodiments.Based on this hair Embodiment in bright, every other implementation obtained by those of ordinary skill in the art without making creative efforts Example, shall fall within the protection scope of the present invention.
It is the flow chart of image pickup method provided in an embodiment of the present invention referring to Fig. 1, Fig. 1, as shown in Figure 1, including following step It is rapid:
Step 101, cache camera acquisition preview image during, if receiving photographing instruction, detect shifting Whether dynamic terminal shakes.
It in a step 101, in the prior art, is all many buffer data of caching.When receiving photographing command, just from A frame data are taken to be pushed to user in data cached.As shown in Fig. 2, taking frame schematic diagram in the prior art take pictures.
In Fig. 2, buffer queue includes n picture frame altogether, when receiving photographing command, is generally taken in buffer queue Third last picture frame, that is, take (n-2) a picture frame to be pushed to user.If user when pressing shoot button, uses Power is larger, and will lead to mobile terminal has shaking by a relatively large margin, and (n-2) a picture frame for being pushed to user in this way will compare It is relatively fuzzy.
In the embodiment of the present invention, at least two buffered image frames can be first obtained, it can first obtain buffered image frame team Column.8 picture frames that may include 8 picture frames in cache image frame queue, and include in cache image frame queue are can be with Real-time update.For example, under preview state, mobile terminal can be according to predetermined after the camera function of unlatching mobile terminal Time interval obtains multiple picture frames, and predetermined time interval can be 33 milliseconds, i.e., mobile terminal can obtain one with every 33 milliseconds A picture frame.The picture frame got can be sensor raw data by the image processor in mobile terminal chip The multiple working procedure of (Image Signal Processor, ISP) is handled, including goes bad point, gamma correction, color correction, color Enhancing and denoising etc. algorithm process, obtained picture frame.
It should be noted that often getting a picture frame, mobile terminal can get the timestamp of the picture frame, And the jitter amplitude value of the corresponding mobile terminal of the picture frame.Two threshold values, respectively first threshold a and can also be set Two threshold value b, and first threshold a is less than second threshold b.When the jitter amplitude value of mobile terminal is less than or equal to first threshold a When, it is believed that there is no shakes for mobile terminal;When mobile terminal jitter amplitude value be greater than first threshold a and be less than or When equal to second threshold b, it is believed that slight jitter occurs for mobile terminal;When the jitter amplitude value of mobile terminal is greater than the second threshold When value b, it is believed that serious shake occurs for mobile terminal.
Cache image frame queue may include two kinds of situations, first explain the first situation here.
The timing since the camera function for opening mobile terminal, often gets a picture frame, so that it may by the picture frame Cache image frame queue is added.After filling up 8 picture frames in cache image frame queue, when getting the 9th picture frame, 9th picture frame can be added to cache image frame queue, while the 1st picture frame in cache image frame queue being abandoned; When getting the 10th picture frame, the 10th picture frame can be added to cache image frame queue, while by buffered image frame The 2nd picture frame in queue abandons.So circulation is gone down, it is ensured that always include 8 images in cache image frame queue Frame, and 8 picture frames for including are real-time updates.And for the first situation, two neighboring figure in cache image frame queue As frame timestamp between interval can be 33 milliseconds.
For second case, mobile terminal often gets a picture frame, can be by the corresponding movement of the picture frame The jitter amplitude value of terminal is compared with default second threshold b, and the jitter amplitude value of corresponding mobile terminal is less than Or cache image frame queue is added in the picture frame equal to default second threshold b, it can by there is no the picture frames of shake And the picture frame addition cache image frame queue of slight jitter occurs;And the jitter amplitude value of corresponding mobile terminal is greater than in advance If the picture frame of second threshold b is then added without cache image frame queue, i.e., cache image will not be added in the picture frame seriously shaken Frame queue.Include in cache image frame queue is all the jitter amplitude value of corresponding mobile terminal less than or equal to default Include in the picture frame namely cache image frame queue of second threshold b is all that there is no the picture frame of shake and generations The picture frame of slight jitter.It equally can always include 8 picture frames in cache image frame queue in second case, and wrap 8 picture frames contained are real-time updates.In this way, always only include 8 picture frames in cache image frame queue, rather than preview Accessed all picture frames, greatly reduce the memory of occupied mobile terminal under state.
During caching the preview image of camera acquisition, if user clicks shoot button, mobile terminal can To receive photographing instruction.And then it can detecte whether mobile terminal is shaken.
It should be noted that under preview state, the gravity of mobile terminal is passed after the camera function of unlatching mobile terminal Sensor can be spaced output data to schedule, and can stamp timestamp for each data.It can establish three-dimensional straight Angular coordinate system, as shown in figure 3, to establish the schematic diagram of three-dimensional cartesian coordinate system on mobile terminals.
The data of gravity sensor output can be (x, y, z).Wherein, x is the acceleration of mobile terminal in the direction of the x axis Value;Y is the acceleration value of mobile terminal in the y-axis direction;Z is the acceleration value of mobile terminal in the z-axis direction.For gravity Sensor, predetermined time interval can be 20 milliseconds, i.e. gravity sensor can be with one data of every 20 milliseconds output.Gravity sensitive The data of device output can also form a buffer queue, may include 13 data in the buffer queue, and in buffer queue 13 data can be with real-time update.Interval in the buffer queue between the timestamp of adjacent two data can be 20 milliseconds.
After receiving photographing instruction, the available receiving time for receiving photographing instruction.And then it can be based on above-mentioned Receiving time, determine at the first time stamp and the second timestamp, wherein receiving time between first time stamp and the second timestamp it Between.Next, the available gravity sensor of mobile terminal is in the first data of first time stamp acquisition and in the second timestamp Second data of acquisition.Assuming that gravity sensor is (x in the first data of first time stamp acquisition1, y1, z1);Gravity sensor It is (x in the second data of the second timestamp acquisition2, y2, z2).The arrow between the first data and the second data can then be calculated Measure length value:
Wherein, vector length value of the A between the first data and the second data;x1It is mobile to stab this moment at the first time The acceleration value of terminal in the direction of the x axis;y1To stab this acceleration of moment mobile terminal in the y-axis direction at the first time Value;z1To stab this acceleration value of moment mobile terminal in the z-axis direction at the first time;x2For this moment of the second timestamp The acceleration value of mobile terminal in the direction of the x axis;y2For this acceleration of moment mobile terminal in the y-axis direction of the second timestamp Angle value;z2For this acceleration value of moment mobile terminal in the z-axis direction of the second timestamp.
After calculating the vector length value between the first data and the second data, it can be determined that above-mentioned vector length value is It is no to be greater than first threshold a.If mobile terminal judges that above-mentioned vector length value is greater than first threshold a, reception can be determined At the time of to photographing instruction, mobile terminal is shaken.
If step 102 detects that mobile terminal is shaken, jitter amplitude value is obtained.
It in a step 102,, can if detecting that mobile terminal is shaken at the time of receiving photographing instruction To obtain jitter amplitude value.And it can be using above-mentioned vector length value as the jitter amplitude value of mobile terminal.
Step 103, according to the jitter amplitude value, determine target cache picture frame.
In step 103, mobile terminal can determine target cache according to jitter amplitude value when receiving photographing instruction Picture frame.
Determine target cache picture frame mode can there are two types of, introduce first way first here.For the first The cache image frame queue of situation is taken pictures if above-mentioned vector length value is less than or equal to first threshold a if received When instruction, the jitter amplitude value of mobile terminal is less than or equal to first threshold a, then when can determine in cache image frame queue Between stab and receiving time between the smallest first object picture frame in interval.It is then possible to by the time in cache image frame queue The picture frame that stamp is less than or equal to the timestamp of first object picture frame is determined as target cache picture frame.
If above-mentioned vector length value is greater than first threshold a, it can determine in cache image frame queue timestamp and connect The smallest second target image frame in interval between time receiving.It is then possible to since the second target image frame, it can postpone It deposits a picture frame last in image frame queue to start, can also postpone and deposit the 8th picture frame in image frame queue and start, According to timestamp reduce sequence, by the corresponding jitter amplitude value of picture frame in cache image frame queue successively with first threshold A is compared.Next it may be determined to the of the first jitter amplitude value compared less than or equal to first threshold a Three target image frames.
For example, the jitter amplitude value of the 8th corresponding mobile terminal of picture frame can be compared with first threshold a. If the jitter amplitude value of the 8th corresponding mobile terminal of picture frame is greater than first threshold a, can be by the 7th picture frame pair The jitter amplitude value for the mobile terminal answered is compared with first threshold a.If the 7th corresponding mobile terminal of picture frame is trembled Dynamic range value is greater than first threshold a, then can be by the jitter amplitude value and first threshold of the 6th corresponding mobile terminal of picture frame A is compared.And so on, the jitter amplitude value until finding first corresponding mobile terminal is less than or equal to the first threshold Until the third target image frame of value a.Finally, timestamp in cache image frame queue can be less than or equal to third target The picture frame of the timestamp of picture frame is determined as target cache picture frame.
It should be noted that the shake of the first corresponding mobile terminal found for the sequence reduced according to timestamp Range value is less than or equal to the third target image frame of first threshold a, it is believed that in cache image frame queue, timestamp is small It is respectively less than in or equal to the jitter amplitude value of the corresponding mobile terminal of all picture frames of timestamp of third target image frame Or it is equal to first threshold a.Target cache picture frame determined by can thinking is the shake width of corresponding mobile terminal Angle value is less than or equal to the picture frame of first threshold a, namely can consider that identified target cache picture frame is not have The picture frame shaken.
And if firmly smaller, then the jitter amplitude value of mobile terminal may be between first when user clicks shoot button Between threshold value a and second threshold b, i.e., slight jitter may occur for mobile terminal at this time.Then looked for according to the sequence that timestamp reduces The jitter amplitude value of the first corresponding mobile terminal arrived less than or equal to first threshold a third target image frame when Between stamp can be relatively close to the receiving time for receiving photographing instruction, for example, it may be possible to be the 5th picture frame;It is clapped if user clicks Firmly larger when according to key, then the jitter amplitude value of mobile terminal is likely larger than second threshold b, i.e., mobile terminal may at this time Serious shake occurs.The jitter amplitude value of the first corresponding mobile terminal then found according to the sequence that timestamp reduces is less than Or the third target image frame equal to first threshold a timestamp and receive photographing instruction receiving time between interval It will be long.For example, it may be possible to be the 2nd picture frame.
Assuming that according to the sequence that timestamp reduces, the jitter amplitude value of the first corresponding mobile terminal eventually found is small In or equal to the third target image frame of first threshold a be the 5th picture frame, i.e., the 4th picture frame reciprocal.It then can be from The 4th picture frame of number starts, and according to the sequence that timestamp reduces, finds the picture frame that image parameter instruction focusing is completed, and can The picture frame completed using the first image parameter instruction focusing that will be found shoots image as target.As shown in figure 4, for one kind Determine the schematic diagram of the mode of target shooting image.
Here the mode of second of determining target cache picture frame is introduced again.For the buffered image frame of second case Queue is less than or equal to second threshold b for the jitter amplitude value that the picture frame for being included is corresponding mobile terminal Picture frame cache image frame queue, mobile terminal can determine in cache image frame queue between timestamp and receiving time The smallest 4th target image frame in interval.And then timestamp in cache image frame queue can be less than or equal to the 4th mesh The picture frame of the timestamp of logo image frame is determined as target cache picture frame.
It should be noted that if the target time interval between the timestamp and receiving time of the 4th target image frame is small In or be equal to prefixed time interval, then mobile terminal can since the 4th target image frame in buffered image frame queue, It can also postpone since buffered image frame queue a picture frame last and deposit in image frame queue the 8th Picture frame starts, and according to the sequence that timestamp reduces, finds the picture frame that image parameter instruction focusing is completed, and can will find First image parameter instruction focusing complete picture frame as target shooting image.
If the target time interval between the timestamp and receiving time of the 4th target image frame is greater than between preset time Every can not then export photo, and prompt information can be exported.The prompt information is for prompting trembling for user's current mobile terminal Dynamic range value is larger, to keep mobile terminal to hold steady.
Step 104 chooses the picture frame for meeting preset condition as target shooting figure from the target cache picture frame Picture.
At step 104, it is determined that after target cache picture frame, so that it may choose and meet from target cache picture frame The picture frame of preset condition shoots image as target.For example, image parameter instruction can be chosen from target cache picture frame The picture frame completed of focusing shoots image as target.
It takes pictures in this way, can solve user in outdoor, and when outdoor wind is larger, mobile terminal, which holds shakiness, to be caused The problem of shooting blurring of photos;It is handshaking that mobile terminal is caused to shake when can solve user and pressing volume key or shoot button It is dynamic, and then lead to the problem of shooting blurring of photos;Can also solve when taking pictures, user due to it is uncomfortable cause it is handshaking, The problem of eventually leading to shooting blurring of photos etc..It ensure that the clarity of captured photo.
In the embodiment of the present invention, above-mentioned mobile terminal can be mobile phone, tablet computer (Tablet Personal Computer), laptop computer (Laptop Computer), personal digital assistant (personal digital Assistant, abbreviation PDA), mobile Internet access device (Mobile Internet Device, MID) or wearable device (Wearable Device) etc..
The image pickup method of the embodiment of the present invention, during caching the preview image of camera acquisition, if receiving bat According to instruction, then detect whether mobile terminal is shaken;If detecting, mobile terminal is shaken, and obtains jitter amplitude value; According to the jitter amplitude value, target cache picture frame is determined;It is chosen from the target cache picture frame and meets preset condition Picture frame as target shoot image.In this way, when mobile terminal receives photographing instruction, if mobile terminal is shaken, The then jitter amplitude value of available mobile terminal.And then target cache picture frame can be determined according to jitter amplitude value.Most Afterwards, the picture frame for meeting preset condition can be chosen from target cache picture frame as target shooting image.The photo of shooting Than more visible, perfect photograph taking effect.
It is the flow chart of image pickup method provided in an embodiment of the present invention, the present embodiment and previous implementation referring to Fig. 5, Fig. 5 The difference of example is to illustrate the mode of determining target shooting image.As shown in Figure 5, comprising the following steps:
Step 501, cache camera acquisition preview image during, obtain first group of picture frame, described first The timestamp of each picture frame corresponding jitter amplitude value and each picture frame in group picture frame, wherein described first group Picture frame includes at least two buffered image frames.
In step 501, during caching the preview image of camera acquisition, available first group of picture frame, The timestamp of each picture frame corresponding jitter amplitude value and each picture frame in first group of picture frame.Wherein, first group Picture frame includes at least two buffered image frames.
It was once mentioned in previous embodiment, it is mobile whole under preview state after the camera function for opening mobile terminal The gravity sensor at end can be spaced output data to schedule, and can stamp timestamp for each data.For Any one picture frame can correspond to two data that determining gravity sensor is exported.Wherein, gravity sensor is exported Two data timestamp and the picture frame timestamp it is closest.
As shown in fig. 6, for the buffer queue of a kind of cache image frame queue and the data composition of gravity sensor output Schematic diagram.
In Fig. 6, first group of picture frame includes 8 picture frames, the buffer queue of the data composition of gravity sensor output Include 13 data.For the 2nd picture frame, the data and t=40ms of the t=20ms that can be exported by gravity sensor Data calculate the jitter amplitude value of the 2nd corresponding mobile terminal of picture frame;For the 3rd picture frame, weight can be passed through The data of t=60ms and the data of t=80ms of force snesor output calculate the 3rd corresponding mobile terminal of picture frame Jitter amplitude value;For the 4th picture frame, the data and t=100ms of the t=80ms that can be exported by gravity sensor Data calculate the jitter amplitude value etc. of the 4th corresponding mobile terminal of picture frame.In this way, the first group picture can be calculated As in frame 8 picture frames corresponding mobile terminal jitter amplitude value.Specific calculating process is in previous embodiment In carried out detailed elaboration, details are not described herein.
If step 502 receives the photographing instruction, the receiving time for receiving the photographing instruction is obtained.
In step 502, if user clicks shoot button, mobile terminal can receive photographing instruction, Jin Erke To obtain the receiving time for receiving photographing instruction.Assuming that the receiving time for receiving photographing instruction is 10:00.
Step 503 is based on the receiving time, determines stamp and the second timestamp at the first time, wherein the receiving time Between first time stamp and second timestamp.
In step 503, it can be based on above-mentioned receiving time, determine stamp and the second timestamp at the first time, wherein receive Time is between first time stamp and the second timestamp.
Step 504 obtains gravity sensor in the first data of first time stamp acquisition and in the acquisition of the second timestamp Second data.
In step 504, the available gravity sensor of mobile terminal first time stamp acquisition the first data and Second data of the second timestamp acquisition.
Vector length value between step 505, calculating first data and second data.
In step 505, mobile terminal can also calculate the vector length value between the first data and the second data.Specifically Calculating process has carried out detailed elaboration in previous embodiment, and details are not described herein.
If step 506, the vector length value are greater than first threshold, it is determined that mobile terminal is shaken.
In step 506, mobile terminal may determine that whether above-mentioned vector length value is greater than first threshold a.If mobile Terminal judges that above-mentioned vector length value is greater than first threshold a, then can determine at the time of receive photographing instruction, mobile terminal It is shaken.
If step 507 detects that mobile terminal is shaken, jitter amplitude value is obtained, the jitter amplitude value is institute State vector length value.
It,, can if detecting that mobile terminal is shaken at the time of receiving photographing instruction in step 507 To obtain jitter amplitude value.And it can be using above-mentioned vector length value as the jitter amplitude value of mobile terminal.
If step 508, the vector length value are less than or equal to the first threshold, it is determined that first group of image The smallest first object picture frame in interval in frame between timestamp and the receiving time.
In step 508, it if above-mentioned vector length value is less than or equal to first threshold a, i.e., takes pictures if received When instruction, the jitter amplitude value of mobile terminal is less than or equal to first threshold a, then can determine the time in first group of picture frame The smallest first object picture frame in interval between stamp and receiving time.
Step 509, by timestamp in first group of picture frame be less than or equal to the first object picture frame when Between the picture frame that stabs be determined as the target cache picture frame.
In step 509, can by timestamp in first group of picture frame be less than or equal to first object picture frame when Between the picture frame that stabs be determined as target cache picture frame.
If step 5010, the vector length value are greater than the first threshold, it is determined that when in first group of picture frame Between stab and the receiving time between the smallest second target image frame in interval.
In step 5010, if above-mentioned vector length value is greater than first threshold a, it can determine in first group of picture frame The smallest second target image frame in interval between timestamp and receiving time.
Step 5011, since the second target image frame, according to timestamp reduce sequence, by first group picture As the corresponding jitter amplitude value of picture frame in frame is successively compared with the first threshold.
It, can be since the second target image frame, it can last from first group of picture frame in step 5011 A picture frame starts, also can be since first group of picture frame the 8th picture frame, will according to the sequence of timestamp reduction The corresponding jitter amplitude value of picture frame in first group of picture frame is successively compared with first threshold a.
For example, the jitter amplitude value of the 8th corresponding mobile terminal of picture frame can be compared with first threshold a. If the jitter amplitude value of the 8th corresponding mobile terminal of picture frame is greater than first threshold a, can be by the 7th picture frame pair The jitter amplitude value for the mobile terminal answered is compared with first threshold a.If the 7th corresponding mobile terminal of picture frame is trembled Dynamic range value is greater than first threshold a, then can be by the jitter amplitude value and first threshold of the 6th corresponding mobile terminal of picture frame A is compared.And so on, the jitter amplitude value until finding first corresponding mobile terminal is less than or equal to the first threshold Until the picture frame of value a.
Step 5012 determines that the first jitter amplitude value relatively obtained is less than or equal to the third of the first threshold Target image frame.
In step 5012, it can determine that the first jitter amplitude value compared is less than or equal to first threshold a Third target image frame.If user clicks shoot button, firmly smaller, then the jitter amplitude value of mobile terminal may be situated between Between first threshold a and second threshold b, i.e., slight jitter may occur for mobile terminal at this time.Then reduce according to timestamp The jitter amplitude value for first corresponding mobile terminal that sequence is found is less than or equal to the third target image of first threshold a The timestamp of frame can be relatively close to the receiving time for receiving photographing instruction, for example, it may be possible to be the 5th picture frame;If user When clicking shoot button, firmly larger, then the jitter amplitude value of mobile terminal is likely larger than second threshold b, i.e., mobile at this time whole End may occur seriously to shake.The jitter amplitude of the first corresponding mobile terminal then found according to the sequence that timestamp reduces Between the timestamp of third target image frame of the value less than or equal to first threshold a and the receiving time for receiving photographing instruction Interval will be long.For example, it may be possible to be the 2nd picture frame.
Assuming that according to the sequence that timestamp reduces, the jitter amplitude value of the first corresponding mobile terminal eventually found is small In or equal to the third target image frame of first threshold a be the 5th picture frame, i.e., the 4th picture frame reciprocal.It then can be from The 4th picture frame of number starts, and according to the sequence that timestamp reduces, finds the picture frame that image parameter instruction focusing is completed, and can The picture frame completed using the first image parameter instruction focusing that will be found shoots image as target.
Step 5013, by timestamp in first group of picture frame be less than or equal to the third target image frame when Between the picture frame that stabs be determined as the target cache picture frame.
In step 5013, can by timestamp in first group of picture frame be less than or equal to third target image frame when Between the picture frame that stabs be determined as target cache picture frame.
Timestamp in first group of picture frame can be less than or equal to the 1st of the timestamp of third target image frame 2nd picture frame, timestamp of the timestamp that picture frame, timestamp are less than or equal to third target image frame are less than or wait It is less than or equal to the time of third target image frame in the 3rd picture frame, the timestamp of the timestamp of third target image frame The 4th picture frame and timestamp of stamp are equal to the 5th picture frame of the timestamp of third target image frame as above-mentioned target Buffered image frame.
Step 5014 chooses the picture frame for meeting preset condition as target shooting figure from the target cache picture frame Picture.
In step 5014, the picture frame for meeting preset condition can be chosen from target cache picture frame as target bat Take the photograph image.It is clapped for example, the picture frame that image parameter instruction focusing is completed can be chosen from target cache picture frame as target Take the photograph image.
It takes pictures in this way, can solve user in outdoor, and when outdoor wind is larger, mobile terminal, which holds shakiness, to be caused The problem of shooting blurring of photos;It is handshaking that mobile terminal is caused to shake when can solve user and pressing volume key or shoot button It is dynamic, and then lead to the problem of shooting blurring of photos;Can also solve when taking pictures, user due to it is uncomfortable cause it is handshaking, The problem of eventually leading to shooting blurring of photos etc..It ensure that the clarity of captured photo.
The image pickup method of the embodiment of the present invention obtains first group during caching the preview image of camera acquisition The timestamp of each picture frame corresponding jitter amplitude value and each picture frame in picture frame, first group of picture frame, Wherein, first group of picture frame includes at least two buffered image frames;If receiving the photographing instruction, acquisition is received The receiving time of the photographing instruction;Based on the receiving time, stamp and the second timestamp at the first time are determined, wherein described Receiving time is stabbed between second timestamp between the first time;Gravity sensor is obtained in first time stamp acquisition The first data and the second timestamp acquisition the second data;Calculate the arrow between first data and second data Measure length value;If the vector length value is greater than first threshold, it is determined that mobile terminal is shaken;If detecting mobile terminal It shakes, then obtains jitter amplitude value, the jitter amplitude value is the vector length value;If the vector length value is less than Or it is equal to the first threshold, it is determined that the interval in first group of picture frame between timestamp and the receiving time is most Small first object picture frame;Timestamp in first group of picture frame is less than or equal to the first object picture frame The picture frame of timestamp is determined as the target cache picture frame;If the vector length value is greater than the first threshold, really The smallest second target image frame in interval in fixed first group of picture frame between timestamp and the receiving time;From described Second target image frame starts, and according to the sequence that timestamp reduces, trembles the picture frame in first group of picture frame is corresponding Dynamic range value is successively compared with the first threshold;Determine that the first jitter amplitude value relatively obtained is less than or equal to The third target image frame of the first threshold;Timestamp in first group of picture frame is less than or equal to the third mesh The picture frame of the timestamp of logo image frame is determined as the target cache picture frame;It is chosen from the target cache picture frame full The picture frame of sufficient preset condition shoots image as target.In this way, when mobile terminal receives photographing instruction, if mobile terminal It shakes, then the jitter amplitude value of available mobile terminal.And then target cache figure can be determined according to jitter amplitude value As frame.Finally, the picture frame for meeting preset condition can be chosen from target cache picture frame as target shooting image.Shooting Photo than more visible, perfect photograph taking effect.
It is the flow chart of image pickup method provided in an embodiment of the present invention, the present embodiment and previous implementation referring to Fig. 7, Fig. 7 The difference of example is to illustrate another mode for determining target shooting image.As shown in fig. 7, comprises following steps:
Step 701, cache camera acquisition preview image during, obtain jitter amplitude value be less than or equal to The timestamp of each picture frame in second group of picture frame of second threshold and second group of picture frame, wherein described second Group picture frame includes at least two buffered image frames, and the second threshold is greater than the first threshold.
In step 701, during caching the preview image of camera acquisition, available jitter amplitude value is less than Or in the second group of picture frame and second group of picture frame equal to second threshold b each picture frame timestamp.Wherein, second Group picture frame includes at least two buffered image frames, and second threshold b is greater than first threshold a.That is include in second group of picture frame It is all the picture frame there is no the picture frame of shake and generation slight jitter.
If step 702 receives the photographing instruction, the receiving time for receiving the photographing instruction is obtained.
In a step 702, if user clicks shoot button, mobile terminal can receive photographing instruction, Jin Erke To obtain the receiving time for receiving photographing instruction.Assuming that the receiving time for receiving photographing instruction is 11:00.
Step 703 is based on the receiving time, determines stamp and the second timestamp at the first time, wherein the receiving time Between first time stamp and second timestamp.
In step 703, it can be based on above-mentioned receiving time, determine stamp and the second timestamp at the first time, wherein receive Time is between first time stamp and the second timestamp.
Step 704 obtains gravity sensor in the first data of first time stamp acquisition and in the acquisition of the second timestamp Second data.
In step 704, the available gravity sensor of mobile terminal first time stamp acquisition the first data and Second data of the second timestamp acquisition.
Vector length value between step 705, calculating first data and second data.
In step 705, mobile terminal can also calculate the vector length value between the first data and second data. Specific calculating process has carried out detailed elaboration in one embodiment, and details are not described herein.
If step 706, the vector length value are greater than first threshold, it is determined that mobile terminal is shaken.
In step 706, mobile terminal may determine that whether above-mentioned vector length value is greater than first threshold a.If mobile Terminal judges that above-mentioned vector length value is greater than first threshold a, then can determine at the time of receive photographing instruction, mobile terminal It is shaken.
If step 707 detects that mobile terminal is shaken, jitter amplitude value is obtained, the jitter amplitude value is institute State vector length value.
It,, can if detecting that mobile terminal is shaken at the time of receiving photographing instruction in step 707 To obtain jitter amplitude value.And it can be using above-mentioned vector length value as the jitter amplitude value of mobile terminal.
Step 708 determines that the interval in second group of picture frame between timestamp and the receiving time is the smallest by Four target image frames.
In step 708, as shown in figure 8, the data group exported for another cache image frame queue and gravity sensor At buffer queue schematic diagram.
In fig. 8, cache image frame queue includes 8 picture frames, the caching team of the data composition of gravity sensor output Column include 13 data.
Mobile terminal can determine the smallest 4th mesh in interval in second group of picture frame between timestamp and receiving time Logo image frame.In fig. 8, the 8th picture frame in second group of picture frame is the 4th target image frame, i.e. second group of picture frame In a picture frame last be the 4th target image frame.
Step 709, by timestamp in second group of picture frame be less than or equal to the 4th target image frame when Between the picture frame that stabs be determined as the target cache picture frame.
In step 709, can by timestamp in second group of picture frame be less than or equal to the 4th target image frame when Between the picture frame that stabs be determined as target cache picture frame.Timestamp in second group of picture frame can be less than or equal to the 4th The 1st picture frame, the timestamp of the timestamp of target image frame are less than or equal to the 2nd of the timestamp of the 4th target image frame A picture frame, timestamp be less than or equal to the 4th target image frame timestamp the 3rd picture frame, timestamp be less than or Equal to the 4th picture frame of the timestamp of the 4th target image frame, timestamp be less than or equal to the 4th target image frame when Between stab the 5th picture frame, timestamp be less than or equal to the 4th target image frame timestamp the 6th picture frame, time Stamp is less than or equal to the 7th picture frame of the timestamp of the 4th target image frame and timestamp is equal to the 4th target image frame Timestamp the 8th picture frame as target cache picture frame.
Step 7010, obtain the 4th target image frame timestamp and the receiving time between target time interval.
In step 7010, between the object time between the timestamp and receiving time of available 4th target image frame Every.As shown in figure 8, the target between the timestamp and receiving time of the 8th picture frame in available second group of picture frame Time interval;Namely between the timestamp and receiving time of a picture frame last in available second group of picture frame Target time interval.
Step 7011 judges whether the target time interval is greater than prefixed time interval.
In step 7011, mobile terminal may determine that whether above-mentioned target time interval is greater than prefixed time interval.Its In the prefixed time interval can be 300 milliseconds.
If step 7012, the target time interval are less than or equal to the prefixed time interval, from the target The picture frame for meeting preset condition is chosen in buffered image frame as target shooting image.
In step 7012, if target time interval is less than or equal to prefixed time interval, i.e., if the object time Interval is less than or equal to 300 milliseconds, then the picture frame conduct for meeting preset condition can be chosen from target cache picture frame Target shoots image.
As shown in Figure 8, it is assumed that within 100 milliseconds before at the time of receiving photographing instruction, the shake width of mobile terminal Angle value is always more than second threshold b, then the mobile terminal corresponding movement of 3 picture frames accessed within this 100 milliseconds The jitter amplitude value of terminal is all larger than second threshold b.Therefore, cache image frame queue can not be added in this 3 picture frames.Cause This, at the time of 11:00 receives photographing instruction, the picture frame in cache image frame queue delays before being still 100 milliseconds The picture frame deposited.
It, will but since the time interval between the timestamp and receiving time of the 4th target image frame is only 100 milliseconds The picture frame cached before 100 milliseconds is pushed to user still within an acceptable range.It therefore can be from target cache image The picture frame for meeting preset condition is chosen in frame as target shooting image.For example, can from second group of picture frame timestamp Start with the immediate 4th target image frame of receiving time, it can a picture frame last is opened from second group of picture frame Begin, also, according to the sequence that timestamp reduces, image parameter can be found since second group of picture frame the 8th picture frame Indicate the picture frame that focusing is completed, and the picture frame that find first image parameter instruction focusing can be completed is as target Shoot image.
Optionally, the picture frame for meeting preset condition of choosing from the target cache picture frame is as target shooting The step of image, comprising:
From the target cache picture frame, chooses the picture frame that image parameter instruction focusing is completed and clapped as the target Take the photograph image;
Wherein, each of described target cache picture frame picture frame includes the image parameter for indicating focusing state.
As previously mentioned, the picture frame conduct that image parameter instruction focusing is completed can be chosen from target cache picture frame Target shoots image.Wherein, each of target cache picture frame picture frame includes the image parameter for indicating focusing state.
If step 7013, the target time interval are greater than the prefixed time interval, prompt information is exported, it is described to mention Show that information is steady for prompting user that mobile terminal is kept to hold.
In step 7013, if the target time interval between the timestamp and receiving time of the 4th target image frame is big In prefixed time interval, i.e., if target time interval is greater than 300 milliseconds, photo can not be exported, and prompt can be exported Information.The prompt information will keep mobile terminal to hold flat for prompting the jitter amplitude value of user's current mobile terminal larger Surely.
For example, it is assumed that the jitter amplitude value of mobile terminal is always within 10 seconds before at the time of receiving photographing instruction Greater than second threshold b, the then shake of the mobile terminal corresponding mobile terminal of multiple images frame accessed within this 10 seconds Range value is all larger than second threshold b.Therefore, mobile terminal multiple images frame accessed within this 10 seconds can not be added Cache image frame queue.Therefore, at the time of 11:00 receives photographing instruction, the picture frame in cache image frame queue is still It is the picture frame cached before 10 seconds.The picture frame cached before 10 seconds is pushed to user's not how many meaning at this time Justice.Therefore, if above-mentioned target time interval is greater than prefixed time interval, photo can not be exported, and prompt can be exported Information.The prompt information will keep mobile terminal to hold flat for prompting the jitter amplitude value of user's current mobile terminal larger Surely.
The benefit that prefixed time interval is arranged can be prevented from by timestamp before at the time of receiving photographing instruction, And timestamp differs farther away picture frame at the time of receiving photographing instruction and is pushed to user.It can guarantee to be pushed to user's Picture frame be timestamp with lesser picture frame is differed at the time of receiving photographing instruction.
It takes pictures in this way, can solve user in outdoor, and when outdoor wind is larger, mobile terminal, which holds shakiness, to be caused The problem of shooting blurring of photos;It is handshaking that mobile terminal is caused to shake when can solve user and pressing volume key or shoot button It is dynamic, and then lead to the problem of shooting blurring of photos;Can also solve when taking pictures, user due to it is uncomfortable cause it is handshaking, The problem of eventually leading to shooting blurring of photos etc..It ensure that the clarity of captured photo.
The image pickup method of the embodiment of the present invention obtains shake width during caching the preview image of camera acquisition Angle value is less than or equal to the time of each picture frame in the second group of picture frame and second group of picture frame of second threshold Stamp, wherein second group of picture frame includes at least two buffered image frames, and the second threshold is greater than the first threshold; If receiving the photographing instruction, the receiving time for receiving the photographing instruction is obtained;Based on the receiving time, determine At the first time stamp and the second timestamp, wherein the receiving time between the first time stamp and second timestamp it Between;Gravity sensor is obtained in the first data of first time stamp acquisition and in the second data of the second timestamp acquisition;It calculates Vector length value between first data and second data;If the vector length value is greater than first threshold, really Determine mobile terminal to shake;If detecting, mobile terminal is shaken, and obtains jitter amplitude value, and the jitter amplitude value is The vector length value;Determine that the interval in second group of picture frame between timestamp and the receiving time is the smallest by 4th Target image frame;Timestamp in second group of picture frame is less than or equal to the timestamp of the 4th target image frame Picture frame is determined as the target cache picture frame;It obtains between the timestamp and the receiving time of the 4th target image frame Target time interval;Judge whether the target time interval is greater than prefixed time interval;If the target time interval is less than Or be equal to the prefixed time interval, then the picture frame conduct for meeting preset condition is chosen from the target cache picture frame Target shoots image;If the target time interval is greater than the prefixed time interval, prompt information, the prompt letter are exported Breath is steady for prompting user that mobile terminal is kept to hold.In this way, when mobile terminal receives photographing instruction, if mobile terminal It shakes, then the jitter amplitude value of available mobile terminal.And then target cache figure can be determined according to jitter amplitude value As frame.Finally, the picture frame for meeting preset condition can be chosen from target cache picture frame as target shooting image.Shooting Photo than more visible, perfect photograph taking effect.
It is the structure chart that the present invention implements the mobile terminal provided referring to Fig. 9, Fig. 9, as shown in figure 9, mobile terminal 900 wraps It includes detection module 901, first to obtain module 902, determining module 903 and choose module 904, detection module 901 and first obtains Module 902 connects, and the first acquisition module 902 is connect with determining module 903, and determining module 903 is connect with module 904 is chosen, In:
Detection module 901, for cache camera acquisition preview image during, if receiving photographing instruction, Then detect whether mobile terminal is shaken;
First obtains module 902, if obtaining jitter amplitude value for detecting that mobile terminal is shaken;
Determining module 903, for determining target cache picture frame according to the jitter amplitude value;
Module 904 is chosen, for choosing the picture frame for meeting preset condition from the target cache picture frame as mesh Mark shooting image.
Optionally, as shown in Figure 10, the detection module 901 includes:
First acquisition submodule 9011, if for receiving the photographing instruction, acquisition receives the photographing instruction Receiving time;
First determines submodule 9012, for being based on the receiving time, determines stamp and the second timestamp at the first time;
Second acquisition submodule 9013, for obtaining gravity sensor in the first data of first time stamp acquisition and the Second data of two timestamps acquisition;
Computational submodule 9014, for calculating the vector length value between first data and second data;
Second determines submodule 9015, if being greater than first threshold for the vector length value, it is determined that mobile terminal hair Raw shake;
Wherein, the receiving time is stabbed between second timestamp between the first time;The jitter amplitude Value is the vector length value.
Optionally, as shown in figure 11, the mobile terminal further include:
Second obtains module 905, for each picture frame pair in first group of picture frame of acquisition, first group of picture frame The timestamp of the jitter amplitude value and each picture frame answered;
Wherein, first group of picture frame includes at least two buffered image frames;
The determining module 903 includes:
Third determines submodule 9031, if being less than or equal to the first threshold for the vector length value, really The smallest first object picture frame in interval in fixed first group of picture frame between timestamp and the receiving time;
4th determines submodule 9032, for timestamp in first group of picture frame to be less than or equal to described first The picture frame of the timestamp of target image frame is determined as the target cache picture frame.
Optionally, as shown in figure 12, the determining module 903 further include:
5th determines submodule 9033, if being greater than the first threshold for the vector length value, it is determined that described the The smallest second target image frame in interval in one group of picture frame between timestamp and the receiving time;
Comparative sub-module 9034, for since the second target image frame, according to the sequence that timestamp reduces, by institute The corresponding jitter amplitude value of the picture frame in first group of picture frame is stated successively to be compared with the first threshold;
6th determines submodule 9035, for determining that it is described that the first jitter amplitude value relatively obtained is less than or equal to The third target image frame of first threshold;
7th determines submodule 9036, for timestamp in first group of picture frame to be less than or equal to the third The picture frame of the timestamp of target image frame is determined as the target cache picture frame.
Optionally, as shown in figure 13, the mobile terminal further include:
Third obtains module 906, second group of picture frame for being less than or equal to second threshold for obtaining jitter amplitude value With the timestamp of each picture frame in second group of picture frame;
Wherein, second group of picture frame includes at least two buffered image frames;
The determining module 903 further include:
8th determines submodule 9037, for determining in second group of picture frame between timestamp and the receiving time The smallest 4th target image frame in interval;
9th determines submodule 9038, for timestamp in second group of picture frame to be less than or equal to the described 4th The picture frame of the timestamp of target image frame is determined as the target cache picture frame;
Wherein, the second threshold is greater than the first threshold.
Optionally, as shown in figure 14, the mobile terminal further include:
4th obtains module 907, the mesh between timestamp and the receiving time for obtaining the 4th target image frame Mark time interval;
Judgment module 908, for judging whether the target time interval is greater than prefixed time interval;
Execution module 909 executes if being less than or equal to the prefixed time interval for the target time interval The described the step of picture frame for meeting preset condition is chosen from the target cache picture frame as target shooting image;
Output module 9010 exports prompt letter if being greater than the prefixed time interval for the target time interval Breath, the prompt information are steady for prompting user that mobile terminal is kept to hold.
Optionally, the selection module 904 is specifically used for:
From the target cache picture frame, chooses the picture frame that image parameter instruction focusing is completed and clapped as the target Take the photograph image;
Wherein, each of described target cache picture frame picture frame includes the image parameter for indicating focusing state.
Mobile terminal 900 can be realized each process that mobile terminal is realized in the embodiment of the method for Fig. 1, Fig. 5 and Fig. 7, To avoid repeating, which is not described herein again.And mobile terminal 900 is when may be implemented to receive photographing instruction, if mobile terminal is sent out Life is shaken, then the jitter amplitude value of available mobile terminal.And then target cache image can be determined according to jitter amplitude value Frame.Finally, the picture frame for meeting preset condition can be chosen from target cache picture frame as target shooting image.Shooting Photo is than more visible, perfect photograph taking effect.
It is the structure chart that the present invention implements the mobile terminal provided, as shown in figure 15, mobile terminal referring to Figure 15, Figure 15 1500 include: at least one processor 1501, memory 1502, at least one network interface 1504 and user interface 1503 and deposit The computer program that can be run on memory 1502 and on processor 1501 is stored up, computer program is executed by processor 1501 The step of Shi Shixian above-mentioned image pickup method.Various components in mobile terminal 1500 are coupled by bus system 1505. It is understood that bus system 1505 is for realizing the connection communication between these components.It includes data/address bus that bus system 1505, which is removed, Except, it further include power bus, control bus and status signal bus in addition.It, will be each in Figure 15 but for the sake of clear explanation Kind bus is all designated as bus system 1505.
Wherein, user interface 1503 may include display, keyboard or pointing device (for example, mouse, trace ball (track ball), touch-sensitive plate or touch screen etc..
It is appreciated that the memory 1502 in the embodiment of the present invention can be volatile memory or non-volatile memories Device, or may include both volatile and non-volatile memories.Wherein, nonvolatile memory can be read-only memory (Read-Only Memory, ROM), programmable read only memory (Programmable ROM, PROM), erasable programmable are only Read memory (Erasable PROM, EPROM), electrically erasable programmable read-only memory (Electrically EPROM, ) or flash memory EEPROM.Volatile memory can be random access memory (Random Access Memory, RAM), use Make External Cache.By exemplary but be not restricted explanation, the RAM of many forms is available, such as static random-access Memory (Static RAM, SRAM), dynamic random access memory (Dynamic RAM, DRAM), synchronous dynamic random-access Memory (Synchronous DRAM, SDRAM), double data speed synchronous dynamic RAM (Double Data Rate SDRAM, DDRSDRAM), it is enhanced Synchronous Dynamic Random Access Memory (Enhanced SDRAM, ESDRAM), synchronous Connect dynamic random access memory (Synchlink DRAM, SLDRAM) and direct rambus random access memory (Direct Rambus RAM, DRRAM).The memory 1502 of system and method described herein is intended to include but is not limited to this A little and any other suitable type memory.
In some embodiments, memory 1502 stores following element, executable modules or data structures, or Their subset of person or their superset: operating system 15021 and application program 15022.
Wherein, operating system 15021 include various system programs, such as ccf layer, core library layer, driving layer etc., are used for Realize various basic businesses and the hardware based task of processing.Application program 15022 includes various application programs, such as matchmaker Body player (Media Player), browser (Browser) etc., for realizing various applied business.Realize that the present invention is implemented The program of example method may be embodied in application program 15022.
In embodiments of the present invention, by the program or instruction of calling memory 1502 to store, specifically, can be application The program or instruction stored in program 15022, processor 1501 are used for: in the process of the preview image of caching camera acquisition In, if receiving photographing instruction, detect whether mobile terminal is shaken;If detecting, mobile terminal is shaken, and obtains Take jitter amplitude value;According to the jitter amplitude value, target cache picture frame is determined;It is chosen from the target cache picture frame The picture frame for meeting preset condition shoots image as target.
The method that the embodiments of the present invention disclose can be applied in processor 1501, or real by processor 1501 It is existing.Processor 1501 may be a kind of IC chip, the processing capacity with signal.During realization, the above method Each step can be completed by the instruction of the integrated logic circuit of the hardware in processor 1501 or software form.Above-mentioned Processor 1501 can be general processor, digital signal processor (Digital Signal Processor, DSP), dedicated Integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components.It may be implemented or execute disclosed each method, step and the logic diagram in the embodiment of the present invention.It is general Processor can be microprocessor or the processor is also possible to any conventional processor etc..In conjunction with institute of the embodiment of the present invention The step of disclosed method, can be embodied directly in hardware decoding processor and execute completion, or with the hardware in decoding processor And software module combination executes completion.Software module can be located at random access memory, and flash memory, read-only memory may be programmed read-only In the storage medium of this fields such as memory or electrically erasable programmable memory, register maturation.The storage medium is located at The step of memory 1502, processor 1501 reads the information in memory 1502, completes the above method in conjunction with its hardware.
It is understood that embodiments described herein can with hardware, software, firmware, middleware, microcode or its Combination is to realize.For hardware realization, processing unit be may be implemented in one or more specific integrated circuit (Application Specific Integrated Circuits, ASIC), digital signal processor (Digital Signal Processing, DSP), digital signal processing appts (DSP Device, DSPD), programmable logic device (Programmable Logic Device, PLD), field programmable gate array (Field-Programmable Gate Array, FPGA), general processor, In controller, microcontroller, microprocessor, other electronic units for executing herein described function or combinations thereof.
For software implementations, it can be realized herein by executing the module (such as process, function etc.) of function described herein The technology.Software code is storable in memory and is executed by processor.Memory can in the processor or It is realized outside processor.
Optionally, processor 1501 is also used to: if receiving the photographing instruction, acquisition receives the photographing instruction Receiving time;Based on the receiving time, stamp and the second timestamp at the first time are determined;Gravity sensor is obtained at first Between stab acquisition the first data and the second timestamp acquisition the second data;Calculate first data and second data Between vector length value;If the vector length value is greater than first threshold, it is determined that mobile terminal is shaken;Wherein, institute Receiving time is stated to stab between second timestamp between the first time;The jitter amplitude value is the vector length Value.
Optionally, processor 1501 is also used to: each image in first group of picture frame of acquisition, first group of picture frame The timestamp of frame corresponding jitter amplitude value and each picture frame;Wherein, first group of picture frame is slow including at least two Deposit picture frame;If the vector length value is less than or equal to the first threshold, it is determined that when in first group of picture frame Between stab and the receiving time between the smallest first object picture frame in interval;Timestamp in first group of picture frame is small It is determined as the target cache picture frame in or equal to the picture frame of timestamp of the first object picture frame.
Optionally, processor 1501 is also used to: if the vector length value is greater than the first threshold, it is determined that described the The smallest second target image frame in interval in one group of picture frame between timestamp and the receiving time;From second target Picture frame starts, according to the sequence that timestamp reduces, by the corresponding jitter amplitude value of picture frame in first group of picture frame Successively it is compared with the first threshold;Determine that the first jitter amplitude value relatively obtained is less than or equal to described first The third target image frame of threshold value;Timestamp in first group of picture frame is less than or equal to the third target image frame The picture frame of timestamp be determined as the target cache picture frame.
Optionally, processor 1501 is also used to: obtaining the second group picture that jitter amplitude value is less than or equal to second threshold As the timestamp of each picture frame in frame and second group of picture frame;Wherein, second group of picture frame includes at least two Open buffered image frame;Determine the smallest 4th mesh in interval in second group of picture frame between timestamp and the receiving time Logo image frame;Timestamp in second group of picture frame is less than or equal to the figure of the timestamp of the 4th target image frame As frame is determined as the target cache picture frame;Wherein, the second threshold is greater than the first threshold.
Optionally, processor 1501 is also used to: between the timestamp and the receiving time for obtaining the 4th target image frame Target time interval;Judge whether the target time interval is greater than prefixed time interval;If the target time interval is small In or equal to the prefixed time interval, then executes described choose from the target cache picture frame and meet preset condition The step of picture frame shoots image as target;If the target time interval is greater than the prefixed time interval, output is mentioned Show that information, the prompt information are steady for prompting user that mobile terminal is kept to hold.
Optionally, processor 1501 is also used to: from the target cache picture frame, being chosen image parameter instruction and has been focused At picture frame as the target shoot image;Wherein, each of described target cache picture frame picture frame includes referring to Show the image parameter of focusing state.
Mobile terminal 1500 can be realized each process that mobile terminal is realized in previous embodiment, to avoid repeating, this In repeat no more.And mobile terminal 1500 is when may be implemented to receive photographing instruction, it, can be with if mobile terminal is shaken Obtain the jitter amplitude value of mobile terminal.And then target cache picture frame can be determined according to jitter amplitude value.Finally, can be with The picture frame for meeting preset condition is chosen from target cache picture frame as target shooting image.The photo of shooting is more clear It is clear, perfect photograph taking effect.
A kind of hardware structural diagram of Figure 16 mobile terminal of each embodiment to realize the present invention.
The mobile terminal 1600 includes but is not limited to: radio frequency unit 1601, network module 1602, audio output unit 1603, input unit 1604, sensor 1605, display unit 1606, user input unit 1607, interface unit 1608, storage The components such as device 1609, processor 1610 and power supply 1611.It will be understood by those skilled in the art that being moved shown in Figure 16 Terminal structure does not constitute the restriction to mobile terminal, and mobile terminal may include components more more or fewer than diagram, or Combine certain components or different component layouts.In embodiments of the present invention, mobile terminal includes but is not limited to mobile phone, puts down Plate computer, laptop, palm PC, car-mounted terminal, wearable device and pedometer etc..
Processor 1610, for cache camera acquisition preview image during, if receiving photographing instruction, Whether detection mobile terminal is shaken;If detecting, mobile terminal is shaken, and obtains jitter amplitude value;It is trembled according to described Dynamic range value, determines target cache picture frame;The picture frame work for meeting preset condition is chosen from the target cache picture frame Image is shot for target.
When receiving photographing instruction, if mobile terminal is shaken, the jitter amplitude value of available mobile terminal. And then target cache picture frame can be determined according to jitter amplitude value.Finally, satisfaction can be chosen from target cache picture frame The picture frame of preset condition shoots image as target.The photo of shooting is than more visible, perfect photograph taking effect.
It should be understood that the embodiment of the present invention in, radio frequency unit 1601 can be used for receiving and sending messages or communication process in, signal Send and receive, specifically, by from base station downlink data receive after, to processor 1610 handle;In addition, by uplink Data are sent to base station.In general, radio frequency unit 1601 includes but is not limited to antenna, at least one amplifier, transceiver, coupling Device, low-noise amplifier, duplexer etc..In addition, radio frequency unit 1601 can also by wireless communication system and network and other Equipment communication.
Mobile terminal provides wireless broadband internet by network module 1602 for user and accesses, and such as user is helped to receive It sends e-mails, browse webpage and access streaming video etc..
Audio output unit 1603 can be received by radio frequency unit 1601 or network module 1602 or in memory The audio data stored in 1609 is converted into audio signal and exports to be sound.Moreover, audio output unit 1603 can be with Audio output relevant to the specific function that mobile terminal 1600 executes is provided (for example, call signal receives sound, message sink Sound etc.).Audio output unit 1603 includes loudspeaker, buzzer and receiver etc..
Input unit 1604 is for receiving audio or video signal.Input unit 1604 may include graphics processor (Graphics Processing Unit, GPU) 16041 and microphone 16042, graphics processor 16041 are captured in video In mode or image capture mode by image capture apparatus (such as camera) obtain static images or video image data into Row processing.Treated, and picture frame may be displayed on display unit 1606.Through treated the picture frame of graphics processor 16041 It can store in memory 1609 (or other storage mediums) or carried out via radio frequency unit 1601 or network module 1602 It sends.Microphone 16042 can receive sound, and can be audio data by such acoustic processing.Audio that treated Data can be converted to the lattice that mobile communication base station can be sent to via radio frequency unit 1601 in the case where telephone calling model Formula output.
Mobile terminal 1600 further includes at least one sensor 1605, for example, optical sensor, motion sensor and other Sensor.Specifically, optical sensor includes ambient light sensor and proximity sensor, wherein ambient light sensor can be according to ring The light and shade of border light adjusts the brightness of display panel 16061, proximity sensor can when mobile terminal 1600 is moved in one's ear, Close display panel 16061 and/or backlight.As a kind of motion sensor, accelerometer sensor can detect in all directions The size of (generally three axis) acceleration, can detect that size and the direction of gravity, can be used to identify mobile terminal appearance when static State (such as horizontal/vertical screen switching, dependent game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, percussion) Deng;Sensor 1605 can also include fingerprint sensor, pressure sensor, iris sensor, molecule sensor, gyroscope, gas Meter, hygrometer, thermometer, infrared sensor etc. are pressed, details are not described herein.
Display unit 1606 is for showing information input by user or being supplied to the information of user.Display unit 1606 can Including display panel 16061, liquid crystal display (Liquid Crystal Display, LCD), organic light-emitting diodes can be used Forms such as (Organic Light-Emitting Diode, OLED) are managed to configure display panel 16061.
User input unit 1607 can be used for receiving the number or character information of input, and generate the use with mobile terminal Family setting and the related key signals input of function control.Specifically, user input unit 1607 include touch panel 16071 with And other input equipments 16072.Touch panel 16071, also referred to as touch screen collect the touch behaviour of user on it or nearby Make (for example user uses any suitable objects or attachment such as finger, stylus on touch panel 16071 or in touch panel Operation near 16071).Touch panel 16071 may include both touch detecting apparatus and touch controller.Wherein, it touches The touch orientation of detection device detection user is touched, and detects touch operation bring signal, transmits a signal to touch controller; Touch controller receives touch information from touch detecting apparatus, and is converted into contact coordinate, then gives processor 1610, It receives the order that processor 1610 is sent and is executed.Furthermore, it is possible to using resistance-type, condenser type, infrared ray and surface The multiple types such as sound wave realize touch panel 16071.In addition to touch panel 16071, user input unit 1607 can also include Other input equipments 16072.Specifically, other input equipments 16072 can include but is not limited to physical keyboard, function key (ratio Such as volume control button, switch key), trace ball, mouse, operating stick, details are not described herein.
Further, touch panel 16071 can be covered on display panel 16061, when touch panel 16071 detects After touch operation on or near it, processor 1610 is sent to determine the type of touch event, is followed by subsequent processing device 1610 Corresponding visual output is provided on display panel 16061 according to the type of touch event.Although in Figure 16, touch panel 16071 and display panel 16061 are the functions that outputs and inputs of realizing mobile terminal as two independent components, but In some embodiments, touch panel 16071 can be integrated with display panel 16061 and realize outputting and inputting for mobile terminal Function, specifically herein without limitation.
Interface unit 1608 is the interface that external device (ED) is connect with mobile terminal 1600.For example, external device (ED) may include Wired or wireless headphone port, external power supply (or battery charger) port, wired or wireless data port, storage card Port, port, the port audio input/output (I/O), video i/o port, earphone for connecting the device with identification module Port etc..Interface unit 1608 can be used for receiving the input (for example, data information, electric power etc.) from external device (ED) simultaneously And by one or more elements that the input received is transferred in mobile terminal 1600 or it can be used in mobile terminal Data are transmitted between 1600 and external device (ED).
Memory 1609 can be used for storing software program and various data.Memory 1609 can mainly include storage program Area and storage data area, wherein storing program area can application program needed for storage program area, at least one function (such as Sound-playing function, image player function etc.) etc.;Storage data area, which can be stored, uses created data (ratio according to mobile phone Such as audio data, phone directory) etc..In addition, memory 1609 may include high-speed random access memory, it can also include non- Volatile memory, for example, at least a disk memory, flush memory device or other volatile solid-state parts.
Processor 1610 is the control centre of mobile terminal, utilizes each of various interfaces and the entire mobile terminal of connection A part by running or execute the software program and/or module that are stored in memory 1609, and calls and is stored in storage Data in device 1609 execute the various functions and processing data of mobile terminal, to carry out integral monitoring to mobile terminal.Place Managing device 1610 may include one or more processing units;Preferably, processor 1610 can integrate application processor and modulation /demodulation Processor, wherein the main processing operation system of application processor, user interface and application program etc., modem processor master Handle wireless communication.It is understood that above-mentioned modem processor can not also be integrated into processor 1610.
Mobile terminal 1600 can also include the power supply 1611 (such as battery) powered to all parts, it is preferred that power supply 1611 can be logically contiguous by power-supply management system and processor 1610, to realize that management is filled by power-supply management system The functions such as electricity, electric discharge and power managed.
In addition, mobile terminal 1600 includes some unshowned functional modules, details are not described herein.
Optionally, processor 1610 is also used to: if receiving the photographing instruction, acquisition receives the photographing instruction Receiving time;Based on the receiving time, stamp and the second timestamp at the first time are determined;Gravity sensor is obtained at first Between stab acquisition the first data and the second timestamp acquisition the second data;Calculate first data and second data Between vector length value;If the vector length value is greater than first threshold, it is determined that mobile terminal is shaken;Wherein, institute Receiving time is stated to stab between second timestamp between the first time;The jitter amplitude value is the vector length Value.
Optionally, processor 1610 is also used to: each image in first group of picture frame of acquisition, first group of picture frame The timestamp of frame corresponding jitter amplitude value and each picture frame;Wherein, first group of picture frame is slow including at least two Deposit picture frame;If the vector length value is less than or equal to the first threshold, it is determined that when in first group of picture frame Between stab and the receiving time between the smallest first object picture frame in interval;Timestamp in first group of picture frame is small It is determined as the target cache picture frame in or equal to the picture frame of timestamp of the first object picture frame.
Optionally, processor 1610 is also used to: if the vector length value is greater than the first threshold, it is determined that described the The smallest second target image frame in interval in one group of picture frame between timestamp and the receiving time;From second target Picture frame starts, according to the sequence that timestamp reduces, by the corresponding jitter amplitude value of picture frame in first group of picture frame Successively it is compared with the first threshold;Determine that the first jitter amplitude value relatively obtained is less than or equal to described first The third target image frame of threshold value;Timestamp in first group of picture frame is less than or equal to the third target image frame The picture frame of timestamp be determined as the target cache picture frame.
Optionally, processor 1610 is also used to: obtaining the second group picture that jitter amplitude value is less than or equal to second threshold As the timestamp of each picture frame in frame and second group of picture frame;Wherein, second group of picture frame includes at least two Open buffered image frame;Determine the smallest 4th mesh in interval in second group of picture frame between timestamp and the receiving time Logo image frame;Timestamp in second group of picture frame is less than or equal to the figure of the timestamp of the 4th target image frame As frame is determined as the target cache picture frame;Wherein, the second threshold is greater than the first threshold.
Optionally, processor 1610 is also used to: between the timestamp and the receiving time for obtaining the 4th target image frame Target time interval;Judge whether the target time interval is greater than prefixed time interval;If the target time interval is small In or equal to the prefixed time interval, then executes described choose from the target cache picture frame and meet preset condition The step of picture frame shoots image as target;If the target time interval is greater than the prefixed time interval, output is mentioned Show that information, the prompt information are steady for prompting user that mobile terminal is kept to hold.
Optionally, processor 1610 is also used to: from the target cache picture frame, being chosen image parameter instruction and has been focused At picture frame as the target shoot image;Wherein, each of described target cache picture frame picture frame includes referring to Show the image parameter of focusing state.
Mobile terminal 1600 can be realized each process that mobile terminal is realized in previous embodiment, to avoid repeating, this In repeat no more.And mobile terminal 1600 is when may be implemented to receive photographing instruction, it, can be with if mobile terminal is shaken Obtain the jitter amplitude value of mobile terminal.And then target cache picture frame can be determined according to jitter amplitude value.Finally, can be with The picture frame for meeting preset condition is chosen from target cache picture frame as target shooting image.The photo of shooting is more clear It is clear, perfect photograph taking effect.
Preferably, the embodiment of the present invention also provides a kind of mobile terminal, including processor 1610, memory 1609, storage On memory 1609 and the computer program that can run on the processor 1610, the computer program is by processor 1610 Each process of above-mentioned image pickup method embodiment is realized when execution, and can reach identical technical effect, to avoid repeating, here It repeats no more.
The embodiment of the present invention also provides a kind of computer readable storage medium, and meter is stored on computer readable storage medium Calculation machine program, the computer program realize each process of above-mentioned image pickup method embodiment when being executed by processor, and can reach Identical technical effect, to avoid repeating, which is not described herein again.Wherein, the computer readable storage medium is deposited Ru read-only Reservoir (Read-Only Memory, abbreviation ROM), random access memory (Random Access Memory, abbreviation RAM), Magnetic or disk etc..
It should be noted that, in this document, the terms "include", "comprise" or its any other variant are intended to non-row His property includes, so that the process, method, article or the device that include a series of elements not only include those elements, and And further include other elements that are not explicitly listed, or further include for this process, method, article or device institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do There is also other identical elements in the process, method of element, article or device.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art The part contributed out can be embodied in the form of software products, which is stored in a storage medium In (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal (can be mobile phone, computer, service Device, air conditioner or network equipment etc.) execute method described in each embodiment of the present invention.
The embodiment of the present invention is described with above attached drawing, but the invention is not limited to above-mentioned specific Embodiment, the above mentioned embodiment is only schematical, rather than restrictive, those skilled in the art Under the inspiration of the present invention, without breaking away from the scope protected by the purposes and claims of the present invention, it can also make very much Form belongs within protection of the invention.

Claims (10)

1. a kind of image pickup method characterized by comprising
During caching the preview image of camera acquisition, if receiving photographing instruction, detect whether mobile terminal is sent out Raw shake;
If detecting, mobile terminal is shaken, and obtains jitter amplitude value;
According to the jitter amplitude value, target cache picture frame is determined;
The picture frame for meeting preset condition is chosen from the target cache picture frame as target shooting image;
If described receive photographing instruction, the step of whether mobile terminal is shaken detected, comprising:
If receiving the photographing instruction, the receiving time for receiving the photographing instruction is obtained;
Based on the receiving time, stamp and the second timestamp at the first time are determined;
Gravity sensor is obtained in the first data of first time stamp acquisition and in the second data of the second timestamp acquisition;
Calculate the vector length value between first data and second data;
If the vector length value is greater than first threshold, it is determined that mobile terminal is shaken;
Wherein, the receiving time is stabbed between second timestamp between the first time;The jitter amplitude value is The vector length value;
If receiving the photographing instruction described, before obtaining the step of receiving the receiving time of the photographing instruction, The method also includes:
Obtain first group of picture frame, the corresponding jitter amplitude value of each picture frame and each figure in first group of picture frame As the timestamp of frame;
Wherein, first group of picture frame includes at least two buffered image frames;
It is described according to the jitter amplitude value, the step of determining target cache picture frame, comprising:
If the vector length value be less than or equal to the first threshold, it is determined that in first group of picture frame timestamp with The smallest first object picture frame in interval between the receiving time;
Timestamp in first group of picture frame is less than or equal to the picture frame of the timestamp of the first object picture frame It is determined as the target cache picture frame;
It is described according to the jitter amplitude value, the step of determining target cache picture frame, comprising:
If the vector length value is greater than the first threshold, it is determined that timestamp and the reception in first group of picture frame The smallest second target image frame in interval between time;
Since the second target image frame, according to the sequence that timestamp reduces, by the image in first group of picture frame The corresponding jitter amplitude value of frame is successively compared with the first threshold;
Determine that the first jitter amplitude value relatively obtained is less than or equal to the third target image frame of the first threshold;
Timestamp in first group of picture frame is less than or equal to the picture frame of the timestamp of the third target image frame It is determined as the target cache picture frame.
2. if the method according to claim 1, wherein receive the photographing instruction described, acquisition connects Before the step of receiving the receiving time of the photographing instruction, the method also includes:
It is each less than or equal in the second group of picture frame and second group of picture frame of second threshold to obtain jitter amplitude value The timestamp of a picture frame;
Wherein, second group of picture frame includes at least two buffered image frames;
It is described according to the jitter amplitude value, the step of determining target cache picture frame, comprising:
Determine the smallest 4th target image frame in interval in second group of picture frame between timestamp and the receiving time;
Timestamp in second group of picture frame is less than or equal to the picture frame of the timestamp of the 4th target image frame It is determined as the target cache picture frame;
Wherein, the second threshold is greater than the first threshold.
3. according to the method described in claim 2, it is characterized in that, meeting in described chosen from the target cache picture frame Before the step of picture frame of preset condition shoots image as target, the method also includes:
Obtain the target time interval between the timestamp and the receiving time of the 4th target image frame;
Judge whether the target time interval is greater than prefixed time interval;
If the target time interval is less than or equal to the prefixed time interval, execute described from the target cache figure As the step of choosing the picture frame for meeting preset condition in frame as target shooting image;
If the target time interval is greater than the prefixed time interval, prompt information is exported, the prompt information is for mentioning It is steady to show that user keeps mobile terminal to hold.
4. according to the method in any one of claims 1 to 3, which is characterized in that described from the target cache picture frame Middle the step of choosing the picture frame for meeting preset condition as target shooting image, comprising:
From the target cache picture frame, the picture frame of image parameter instruction focusing completion is chosen as the target shooting figure Picture;
Wherein, each of described target cache picture frame picture frame includes the image parameter for indicating focusing state.
5. a kind of mobile terminal characterized by comprising
Detection module, for if receiving photographing instruction, detecting shifting during caching the preview image of camera acquisition Whether dynamic terminal shakes;
First obtains module, if obtaining jitter amplitude value for detecting that mobile terminal is shaken;
Determining module, for determining target cache picture frame according to the jitter amplitude value;
Module is chosen, for choosing the picture frame for meeting preset condition from the target cache picture frame as target shooting figure Picture;
The detection module includes:
First acquisition submodule, if for receiving the photographing instruction, when acquisition receives the reception of the photographing instruction Between;
First determines submodule, for being based on the receiving time, determines stamp and the second timestamp at the first time;
Second acquisition submodule, for obtaining gravity sensor in the first data of first time stamp acquisition and in the second timestamp Second data of acquisition;
Computational submodule, for calculating the vector length value between first data and second data;
Second determines submodule, if being greater than first threshold for the vector length value, it is determined that mobile terminal is shaken;
Wherein, the receiving time is stabbed between second timestamp between the first time;The jitter amplitude value is The vector length value;
Second obtains module, and for obtaining, first group of picture frame, each picture frame is corresponding in first group of picture frame trembles The timestamp of dynamic range value and each picture frame;
Wherein, first group of picture frame includes at least two buffered image frames;
The determining module includes:
Third determines submodule, if being less than or equal to the first threshold for the vector length value, it is determined that described the The smallest first object picture frame in interval in one group of picture frame between timestamp and the receiving time;
4th determines submodule, for timestamp in first group of picture frame to be less than or equal to the first object image The picture frame of the timestamp of frame is determined as the target cache picture frame;
The determining module further include:
5th determines submodule, if being greater than the first threshold for the vector length value, it is determined that first group of image The smallest second target image frame in interval in frame between timestamp and the receiving time;
Comparative sub-module, for since the second target image frame, according to the sequence that timestamp reduces, by described first group The corresponding jitter amplitude value of picture frame in picture frame is successively compared with the first threshold;
6th determines submodule, for determining that the first jitter amplitude value relatively obtained is less than or equal to the first threshold Third target image frame;
7th determines submodule, for timestamp in first group of picture frame to be less than or equal to the third target image The picture frame of the timestamp of frame is determined as the target cache picture frame.
6. mobile terminal according to claim 5, which is characterized in that the mobile terminal further include:
Third obtains module, for obtaining jitter amplitude value less than or equal to second group of picture frame of second threshold and described the The timestamp of each picture frame in two groups of picture frames;
Wherein, second group of picture frame includes at least two buffered image frames;
The determining module further include:
8th determines submodule, for determining the interval in second group of picture frame between timestamp and the receiving time most The 4th small target image frame;
9th determines submodule, for timestamp in second group of picture frame to be less than or equal to the 4th target image The picture frame of the timestamp of frame is determined as the target cache picture frame;
Wherein, the second threshold is greater than the first threshold.
7. mobile terminal according to claim 6, which is characterized in that the mobile terminal further include:
4th obtains module, between the object time between timestamp and the receiving time for obtaining the 4th target image frame Every;
Judgment module, for judging whether the target time interval is greater than prefixed time interval;
Execution module, if being less than or equal to the prefixed time interval for the target time interval, execute it is described from The step of picture frame for meeting preset condition is chosen in the target cache picture frame as target shooting image;
Output module exports prompt information if being greater than the prefixed time interval for the target time interval, described to mention Show that information is steady for prompting user that mobile terminal is kept to hold.
8. mobile terminal according to any one of claims 5 to 7, which is characterized in that the selection module is specifically used for:
From the target cache picture frame, the picture frame of image parameter instruction focusing completion is chosen as the target shooting figure Picture;
Wherein, each of described target cache picture frame picture frame includes the image parameter for indicating focusing state.
9. a kind of mobile terminal, which is characterized in that including processor, memory and be stored on the memory and can be described The computer program run on processor is realized when the computer program is executed by the processor as in Claims 1-4 The step of described in any item image pickup methods.
10. a kind of computer-readable storage medium, which is characterized in that be stored with meter in the computer-readable storage medium Calculation machine program, the computer program realize image pickup method according to any one of claims 1 to 4 when being executed by processor The step of.
CN201710865596.5A 2017-09-22 2017-09-22 A kind of image pickup method and mobile terminal Active CN107509034B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710865596.5A CN107509034B (en) 2017-09-22 2017-09-22 A kind of image pickup method and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710865596.5A CN107509034B (en) 2017-09-22 2017-09-22 A kind of image pickup method and mobile terminal

Publications (2)

Publication Number Publication Date
CN107509034A CN107509034A (en) 2017-12-22
CN107509034B true CN107509034B (en) 2019-11-26

Family

ID=60697211

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710865596.5A Active CN107509034B (en) 2017-09-22 2017-09-22 A kind of image pickup method and mobile terminal

Country Status (1)

Country Link
CN (1) CN107509034B (en)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108347563B (en) * 2018-02-07 2020-12-22 Oppo广东移动通信有限公司 Video processing method and device, electronic equipment and computer readable storage medium
CN109688319B (en) * 2018-09-19 2020-10-30 青岛海信智慧家居系统股份有限公司 Method and device for inhibiting camera shooting jitter of intelligent sound box with camera
CN109005355B (en) * 2018-09-28 2020-10-09 维沃移动通信有限公司 Shooting method and mobile terminal
CN111385475B (en) * 2020-03-11 2021-09-10 Oppo广东移动通信有限公司 Image acquisition method, photographing device, electronic equipment and readable storage medium
CN112333387A (en) * 2020-10-30 2021-02-05 维沃移动通信有限公司 Shooting method, shooting device, electronic equipment and storage medium
CN114449151B (en) * 2020-10-30 2023-06-02 华为技术有限公司 Image processing method and related device
CN112653842A (en) * 2020-12-23 2021-04-13 维沃移动通信有限公司 Video anti-shake method and device
CN113259594A (en) * 2021-06-22 2021-08-13 展讯通信(上海)有限公司 Image processing method and device, computer readable storage medium and terminal
CN116709043A (en) * 2022-02-25 2023-09-05 荣耀终端有限公司 Shooting method and electronic equipment
CN116723383A (en) * 2022-02-28 2023-09-08 荣耀终端有限公司 Shooting method and related equipment
CN116347212B (en) * 2022-08-05 2024-03-08 荣耀终端有限公司 Automatic photographing method and electronic equipment
CN117156261A (en) * 2023-03-28 2023-12-01 荣耀终端有限公司 Image processing method and related equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8289400B2 (en) * 2009-06-05 2012-10-16 Apple Inc. Image capturing device having continuous image capture
CN104219448A (en) * 2014-08-28 2014-12-17 小米科技有限责任公司 Shooting method and shooting device
CN105611180A (en) * 2016-03-28 2016-05-25 广东欧珀移动通信有限公司 Method, mobile terminal and system for preventing photographic shake by using wearable equipment
CN105827967A (en) * 2016-03-28 2016-08-03 广东欧珀移动通信有限公司 Control method and device, and electronic device
CN105872376A (en) * 2016-04-12 2016-08-17 广东欧珀移动通信有限公司 Control method, control apparatus and electronic device
CN106210496A (en) * 2015-05-06 2016-12-07 小米科技有限责任公司 Method, photo taking and device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8289400B2 (en) * 2009-06-05 2012-10-16 Apple Inc. Image capturing device having continuous image capture
CN104219448A (en) * 2014-08-28 2014-12-17 小米科技有限责任公司 Shooting method and shooting device
CN106210496A (en) * 2015-05-06 2016-12-07 小米科技有限责任公司 Method, photo taking and device
CN105611180A (en) * 2016-03-28 2016-05-25 广东欧珀移动通信有限公司 Method, mobile terminal and system for preventing photographic shake by using wearable equipment
CN105827967A (en) * 2016-03-28 2016-08-03 广东欧珀移动通信有限公司 Control method and device, and electronic device
CN105872376A (en) * 2016-04-12 2016-08-17 广东欧珀移动通信有限公司 Control method, control apparatus and electronic device

Also Published As

Publication number Publication date
CN107509034A (en) 2017-12-22

Similar Documents

Publication Publication Date Title
CN107509034B (en) A kind of image pickup method and mobile terminal
CN107580184B (en) A kind of image pickup method and mobile terminal
CN108513070A (en) A kind of image processing method, mobile terminal and computer readable storage medium
CN108391053A (en) A kind of filming control method and terminal
CN107592471A (en) A kind of high dynamic range images image pickup method and mobile terminal
CN107566748A (en) A kind of image processing method, mobile terminal and computer-readable recording medium
CN107707825B (en) A kind of panorama shooting method, mobile terminal and computer readable storage medium
CN108881733A (en) A kind of panorama shooting method and mobile terminal
CN107610075A (en) Image combining method and mobile terminal
CN109862258A (en) A kind of image display method and terminal device
CN108322647A (en) Panoramic picture image pickup method, mobile terminal and computer readable storage medium
CN108012084A (en) A kind of image generating method, application processor AP and third party's picture processing chip
CN108989672A (en) A kind of image pickup method and mobile terminal
CN109218626A (en) A kind of photographic method and terminal
CN107820022A (en) A kind of photographic method and mobile terminal
CN107748648A (en) Prevent the method and terminal device of fingerprint sensor false triggering
CN108833709A (en) A kind of the starting method and mobile terminal of camera
CN108320263A (en) A kind of method, device and mobile terminal of image procossing
CN108040209A (en) A kind of image pickup method and mobile terminal
CN108200229A (en) Image pickup method, terminal and the computer readable storage medium of flexible screen terminal
CN107888833A (en) A kind of image capturing method and mobile terminal
CN109803087A (en) A kind of image generating method and terminal device
CN109639987A (en) A kind of bracelet image pickup method, equipment and computer readable storage medium
CN108121486A (en) A kind of image display method and mobile terminal
CN108174110A (en) A kind of photographic method and flexible screen terminal

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
GR01 Patent grant
GR01 Patent grant