CN105187692B - Video capture method and device - Google Patents

Video capture method and device Download PDF

Info

Publication number
CN105187692B
CN105187692B CN201410268233.XA CN201410268233A CN105187692B CN 105187692 B CN105187692 B CN 105187692B CN 201410268233 A CN201410268233 A CN 201410268233A CN 105187692 B CN105187692 B CN 105187692B
Authority
CN
China
Prior art keywords
frame data
video
video file
media material
shooting
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
CN201410268233.XA
Other languages
Chinese (zh)
Other versions
CN105187692A (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.)
Tencent Technology Beijing Co Ltd
Original Assignee
Tencent Technology Beijing 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 Tencent Technology Beijing Co Ltd filed Critical Tencent Technology Beijing Co Ltd
Priority to CN201410268233.XA priority Critical patent/CN105187692B/en
Publication of CN105187692A publication Critical patent/CN105187692A/en
Application granted granted Critical
Publication of CN105187692B publication Critical patent/CN105187692B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention discloses a kind of video capture method and devices, belong to multi-media processing field.The described method includes:Multi-media Material is obtained, the Multi-media Material includes picture or video file;At least one frame data of this shooting are obtained, the frame data include the former or all two kinds of image frame data and audio frame number in;It is a part of video content in target video file by Multi-media Material processing, is another part video content of the target video file by least one frame data processing of this shooting, obtains the target video file.The present invention solves the problems, such as that the entire shooting process of current video capture method can not really be cut off;Other Multi-media Materials can be based on by having reached, for example, section has been taken the video file finished and carries out continuous bat at other times by active user or other users, to complete the effect of this shooting.

Description

Video capture method and device
Technical field
The present embodiments relate to multi-media processing field, more particularly to a kind of video capture method and device.
Background technology
At present, user is gradually changed using the mode of internet, and the occupation mode based on original download becomes Into current download and upload the occupation mode laid equal stress on.In view of user produces the demand of original content, in such as smart mobile phone, put down On the mobile terminals such as plate computer or smart camera, it is most widely used in daily life that video capture has been increasingly becoming people One of function.
In order to enrich style of shooting of the user when shooting video, a kind of video capture method is:Mobile terminal is receiving To user to the Continued depression signal of shooting push button when, create an empty video file, frame data will write this one by one and regard Frequency file, frame data include image frame data and audio frame number evidence;Mobile terminal is receiving release of the user to shooting push button During signal, suspend to the video file and write frame data;When mobile terminal receive again user to shooting push button persistently by When pressing signal, mobile terminal continues to write frame data one by one in the video file, before repeating 2 steps can it is multiple not The same period carries out video and continues bat.
During the embodiment of the present invention is realized, inventor has found that above-mentioned technology has at least the following problems:It is above-mentioned to regard Although the shooting process of frequency image pickup method can realize that video in different time periods continues bat, the effect for interrupting shooting can only be realized Fruit, entire shooting process can not really be cut off.Namely when user unclamps shooting push button, camera still needs in work shape State.
The content of the invention
In order to which the entire shooting process for solving the problems, such as current video capture method can not really be cut off, the present invention is implemented Example provides a kind of video capture method and device.The technical solution is as follows:
It is according to embodiments of the present invention in a first aspect, provide a kind of video capture method, the described method includes:
Multi-media Material is obtained, the Multi-media Material includes picture or video file;
At least one frame data of this shooting are obtained, the frame data include image frame data and audio frame number in Former is two kinds whole;
It is a part of video content in target video file by Multi-media Material processing, by this shooting At least one frame data processing is another part video content of the target video file, obtains the target video file.
Second aspect according to embodiments of the present invention, provides a kind of video capture device, and described device includes:
Material obtaining module, for obtaining Multi-media Material, the Multi-media Material includes picture or video file;
This taking module, for obtaining at least one frame data of this shooting, the frame data include number of image frames According to the former or two kinds whole with audio frame number in;
Video processing module, for being in a part of video in target video file by Multi-media Material processing Hold, be another part video content of the target video file by least one frame data processing of this shooting, obtain To the target video file.
The third aspect according to embodiments of the present invention, provides a kind of mobile terminal, the mobile terminal, including:
One or more than one processor;
Memory;
And one or more than one program, wherein the one or more programs are stored in the storage It in device, and is configured to be performed by the one or more processor, the one or more programs include For the instruction operated below:
Multi-media Material is obtained, the Multi-media Material includes picture or video file;
At least one frame data of this shooting are obtained, the frame data include image frame data and audio frame number in Former is two kinds whole;
It is a part of video content in target video file by Multi-media Material processing, by this shooting At least one frame data processing is another part video content of the target video file, obtains the target video file.
The advantageous effect that technical solution provided in an embodiment of the present invention is brought is:
By being a part of video content in the target video file of this shooting by Multi-media Material processing;It solves The problem of entire shooting process of current video capture method can not really be cut off;Other multimedias element can be based on by having reached Material, for example, section has been taken the video file finished and carries out continuous bat at other times by active user or other users, to complete The effect of this shooting.
Description of the drawings
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some embodiments of the present invention, for For those of ordinary skill in the art, without creative efforts, other are can also be obtained according to these attached drawings Attached drawing.
Fig. 1 is the method flow diagram of video capture method provided by one embodiment of the present invention;
Fig. 2A is the method flow diagram for the video capture method that another embodiment of the present invention provides;
Fig. 2 B, Fig. 2 C, Fig. 2 D, Fig. 2 E and Fig. 2 F are implementation of the video capture method of Fig. 2A embodiments offer when implementing Schematic diagram;
Fig. 3 A are the method flow diagrams for the video capture method that another embodiment of the present invention provides;
Fig. 3 B, Fig. 3 C, Fig. 3 D and Fig. 3 E are implementation signal of the video capture method of Fig. 3 A embodiments offer when implementing Figure;
Fig. 4 A are the method flow diagrams for the video capture method that another embodiment of the present invention provides;
Fig. 4 B, Fig. 4 C, Fig. 4 D, Fig. 4 E, Fig. 4 F and Fig. 4 G are the video capture methods of Fig. 4 A embodiments offer when implementing Implementation schematic diagram;
Fig. 5 is the block diagram of video capture device provided by one embodiment of the present invention;
Fig. 6 is the block diagram for the video capture device that another embodiment of the present invention provides;
Fig. 7 is the block diagram of mobile terminal provided by one embodiment of the present invention.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, below in conjunction with attached drawing to embodiment party of the present invention Formula is described in further detail.
Mobile terminal in the embodiment of the present invention can be mobile phone, tablet computer, E-book reader, MP3 player (Moving Picture Experts Group Audio Layer III, dynamic image expert's compression standard audio level 3), MP4 (Moving Picture Experts Group Audio Layer IV, dynamic image expert's compression standard audio level 3) player, pocket computer on knee, camera and video camera etc..
It please refers to Fig.1, it illustrates the method flow diagrams of video capture method provided by one embodiment of the present invention.This reality Apply example with the video capture method applied to come in mobile terminal for example, the mobile terminal can be equipped with social class should With or the mobile terminal applied of short video sharing, this method includes:
Step 102, Multi-media Material is obtained, Multi-media Material includes picture or video file;
Step 104, at least one frame data of this shooting are obtained, frame data include image frame data and audio frame number evidence In former or all two kinds;
Step 106, it is a part of video content in target video file by Multi-media Material processing, by this shooting At least one frame data processing is another part video content of target video file, obtains target video file.
In conclusion video capture method provided in this embodiment, by being this shooting by Multi-media Material processing A part of video content in target video file;The entire shooting process for solving current video capture method can not be real The problem of cutting off;Other Multi-media Materials can be based on by having reached, for example, active user or other users section at other times The video file finished has been taken and carries out continuous bat, to complete the effect of this shooting.
Since Multi-media Material can include any one in following three kinds of materials:
1st, static images material;
2nd, dynamic picture material;
3rd, video file material;
So above-mentioned three kinds of realization methods are carried out respectively below by Fig. 2A, Fig. 3 A and tri- embodiments of Fig. 4 A detailed It illustrates:
Video refer to a series of static images in a manner of electric signal are captured, are noted down, are handled, are stored, transmit with again Existing various technologies.Continuous image change it is per second more than more than 24 frame pictures when, according to persistence of vision principle, human eye will be unable to Distinguish the tableaux of single width, so as to appear to be smooth continuous visual effect, so continuous picture is called video.
Therefore, video can be added to using still image as the image frame data of video.
A is please referred to Fig.2, it illustrates the method flow diagrams of video capture method provided by one embodiment of the present invention.This Embodiment is in the video capture method applied to coming in mobile terminal for example, the mobile terminal can be equipped with social class Using or the application of short video sharing mobile terminal, this method includes:
Step 201, Multi-media Material is obtained, Multi-media Material includes picture or video file;
The present embodiment is by Multi-media Material for exemplified by static images, the acquisition methods of static images have following four:
1) obtained from local storage;
Mobile terminal obtains the static images of designated position in local storage after the operational order of user is received.
2) obtained from network memory;
Mobile terminal obtains designated position in the corresponding network memory of user after the operational order of user is received Static images.Network memory can be the various Dropbox positioned at high in the clouds.
3) obtained from the file that the good friend that social class is applied is shared;
It is mobile whole if mobile terminal is the terminal for being equipped with social class application as a kind of novel acquisition modes End can obtain static images from the file that the good friend in the application of social class is shared.
4) static images are obtained in the file shared from the application of short video sharing by other people or platform.
As another novel acquisition modes, if mobile terminal is the terminal for being equipped with short video sharing application, Static images are obtained in the file that mobile terminal can be shared from the application of short video sharing by other people or platform.
For example, as shown in Figure 2 B, mobile terminal is the terminal for being equipped with short video sharing application, user can pass through click " static images " button 22 shows pop-up box 24 to trigger mobile terminal, and then user can select one kind to obtain in pop-up box 24 The mode of static images is taken to obtain material file.
Step 202, static images are handled, obtains at least one frame data corresponding with the static images;
Then, mobile terminal handles the static images, obtains at least one frame number corresponding with the static images According to.This step can have 2 kinds of different realization methods:
1) image frame data of video file can be write by, being converted into a static images.
That is, mobile terminal does not do other processing to a static images, directly as a two field picture frame data, alternatively, The identical image frame data of continuous multiple frames is used as after duplication.
2), static images are done with dynamic change processing, obtains at least one figure corresponding in dynamic change processing procedure As frame data;
Wherein, dynamic change processing includes:Translation variation;And/or scaling variation;It is and/or rotationally-varying;And/or disappear Hidden variation.
Mobile terminal can include but not limited to a static images:Translation variation, scaling change, are rotationally-varying And/or the dynamic changes processing such as blanking variation.A static images will become multiple images frame data at this time.
As shown in Figure 2 C, mobile terminal does static images 26 rotationally-varying, and static images 26 are carried out at several variations N image frame datas are obtained after reason.
By taking mobile terminal is Android (Android) mobile phone as an example, the Ondraw methods in android system can be used real It is existing.That is, when mobile terminal does static images by Ondraw methods dynamic change processing, image that each moment is drawn It is plotted on an individual bitmap, process is continuously drawn several times, can obtain the system in dynamic change processing procedure Row bitmap, finally using a series of this bitmap as image frame data corresponding with the static images.
Step 203, at least one frame data of this shooting are obtained;
Mobile terminal can obtain at least one frame data of this shooting by built-in camera or external camera. When not shooting sound, frame data only include image frame data;When shooting sound and image at the same time, frame data both include picture frame Data further include audio frame number evidence.
For example, mobile terminal is the mobile phone for being built-in with camera, then mobile terminal can be obtained by built-in camera The frame data one by one of this shooting.
For example, mobile terminal is the tablet computer of no built-in camera, then mobile terminal can pass through external camera Obtain the frame data one by one of this shooting.
Step 204, an empty video file is created for this shooting;
Mobile terminal can be that this shooting creates an empty video file, this empty video file is equivalent to one " container ", for storing image frame data and audio frame number evidence.
By taking MP4 forms as an example, this empty video file can only there are one video header file, the one of essential record video A little essential informations:The wide height of video, duration, code check, coded format, frame list, the sample rate of audio, channel number of audio etc..
Step 205, at least one frame data of the corresponding at least one frame data of Multi-media Material and this shooting are pressed It is coded into according to predetermined order in video file, obtains target video file;
Predetermined order can include any one in following three kinds of orders:
For the corresponding at least one image frame data of static images preceding, at least one frame data of this shooting are posterior suitable Sequence;Or,
At least one frame data of this shooting are preceding, and the corresponding at least one image frame data of static images material is rear Order;Or,
A part at least one frame data of this shooting is in preceding, the corresponding at least one number of image frames of static images According to the posterior order of another part in centre, at least one frame data of this shooting.
As shown in Figure 2 D, the present embodiment is illustrated by taking the first order as an example:
First, the corresponding at least one image frame data of obtained static images is coded by mobile terminal according to predetermined format Video file.This step can include:
1st, mobile terminal according to predetermined format set video stream encoder, video flowing coding parameter, audio stream encoder and Audio stream coding parameter;
Video flowing coding parameter include video format, the width of image frame data, image frame data it is high;
Audio stream coding parameter includes code check, channel number, if be stereo etc..
2nd, according to video stream encoder corresponding with predetermined format and video flowing coding parameter by the corresponding figure of static images As frame data are coded into video file.
The above process can also use increase income free cross-platform video and audio stream scheme ffmpeg realizations.
2nd, at least one frame data by this shooting are coded into according to predetermined format in video file.
That is, mobile terminal claps this according to video stream encoder corresponding with predetermined format and video flowing coding parameter The image frame data taken the photograph is coded into video file;According to audio stream encoder corresponding with predetermined format and audio stream coding parameter By the audio frame number of this shooting according to being coded into video file, target video file is obtained.
As shown in Figure 2 E, the schematic diagram of the third order is as shown in Figure 2 F for the schematic diagram of second of order.
In conclusion video capture method provided in this embodiment, by being this shooting by Multi-media Material processing A part of video content in target video file;The entire shooting process for solving current video capture method can not be real The problem of cutting off;Other Multi-media Materials can be based on by having reached, for example, active user or other users section at other times The video file finished has been taken and carries out continuous bat, to complete the effect of this shooting.
It should be added that as long as step 203 performs before the coding, specific execution sequence is not subject to specifically It limits.For example, during using the first sequential shoot, step 203 can be corresponding at least one by static images in step 205 Frame data perform after being coded into video file;When for another example, using second of sequential shoot, step 203 can be in step 201 It performs before;When for another example, using the third sequential shoot, step 203 can perform once before step 201, in step The corresponding at least one frame data of static images are coded into video file and then secondary execution once in 205.
It should be added that before step 205, if the corresponding image frame data of static images is RGB (Red Green Blue, RGB) form and this shooting image frame data for YUV (Luma Chroma, brightness and color) form, The image frame data that then mobile terminal can obtain this shooting is converted to rgb format from yuv format, not only so that picture frame The form of data is consistent, and the image frame data for being also based on rgb format adds filter or special efficacy during continuous clap.
It should be added that before step 205, if the corresponding image frame data of static images and this shooting The angle of image frame data is different, then mobile terminal rotates this image frame data shot, the figure for obtaining decoding As frame data are identical with the angle for the image frame data that this shoots.So that the continuous figure clapped in obtained target video file As the angle of frame data is consistent.For example, static images are corresponded to vertical image frame data, and this shooting is that shake-hands grip obtains Image frame data, then the image frame data of this shooting can be rotated by 90 °, be converted to by horizontal image frame data perpendicular To image frame data.
A is please referred to Fig.3, it illustrates the method flow diagrams for the video capture method that another embodiment of the present invention provides. The present embodiment is in the video capture method applied to coming in mobile terminal for example, the mobile terminal can be equipped with social activity Class is applied or the mobile terminal of short video sharing application, this method include:
Step 301, Multi-media Material is obtained, Multi-media Material includes picture or video file;
The present embodiment is by Multi-media Material for exemplified by dynamic picture, dynamic picture is usually to be combined by multiple static images frames It forms, this picture is played out each frame being composed by certain speed, and forms dynamic picture effect.
Similar with static images, the acquisition methods of dynamic picture also include following four:
1) obtained from local storage;
Mobile terminal obtains the dynamic picture of designated position in local storage after the operational order of user is received.
2) obtained from network memory;
Mobile terminal obtains designated position in the corresponding network memory of user after the operational order of user is received Dynamic picture.Network memory can be the various Dropbox positioned at high in the clouds.
3) obtained from the file that the good friend that social class is applied is shared;
It is mobile whole if mobile terminal is the terminal for being equipped with social class application as a kind of novel acquisition modes End can obtain dynamic picture from the file that the good friend in the application of social class is shared.
4) dynamic picture is obtained in the file shared from the application of short video sharing by other people or platform.
As another novel acquisition modes, if mobile terminal is the terminal for being equipped with short video sharing application, Dynamic picture is obtained in the file that mobile terminal can be shared from the application of short video sharing by other people or platform.
For example, as shown in Figure 3B, mobile terminal is the terminal for being equipped with short video sharing application, user can pass through click " dynamic picture " button 32 shows pop-up box 34 to trigger mobile terminal, and then user can select one kind to obtain in pop-up box 34 The mode of dynamic picture is taken to obtain material file.
Step 302, deconsolidation process is carried out to dynamic picture, obtains at least one number of image frames included by dynamic picture According to;
Exemplified by the dynamic picture of the present embodiment in the gif format, the original of GIF (Graphics Interchange Format) Justice is " graphic interchange format ", and the data of gif file are a kind of nondestructive compression types of the continuous tone based on lzw algorithm, is moved Dynamic terminal can directly extract multiple static images frames in GIF format pictures.
It, can will be after these static images change process after obtaining after the static images of each frame of GIF pictures As the image frame data that will be added to video file, change process mentioned here can include:Translation variation;And/or Scaling variation;It is and/or rotationally-varying;And/or blanking variation.
Step 303, at least one frame data of this shooting are obtained;
Mobile terminal can obtain at least one frame data of this shooting by built-in camera or external camera. When not shooting sound, frame data only include image frame data;When shooting sound and image at the same time, frame data include picture frame Data further include audio frame number evidence.
For example, mobile terminal is the mobile phone for being built-in with camera, then mobile terminal can be obtained by built-in camera The frame data one by one of this shooting.
For example, mobile terminal is the tablet computer of no built-in camera, then mobile terminal can pass through external camera Obtain the frame data one by one of this shooting.
Step 304, an empty video file is created for this shooting;
Mobile terminal can be that this shooting creates an empty video file, this empty video file is equivalent to one " container ", for storing image frame data and audio frame number evidence.
By taking MP4 forms as an example, this empty video file can only there are one video header file, the one of essential record video A little essential informations:The wide height of video, duration, code check, coded format, frame list, the sample rate of audio, channel number of audio etc..
Step 305, at least one frame data of the corresponding at least one frame data of Multi-media Material and this shooting are pressed It is coded into according to predetermined order in video file, obtains target video file;
Predetermined order can include any one in following three kinds of orders:The corresponding at least one frame data of dynamic picture In preceding, the posterior order of at least one frame data of this shooting;Or,
At least one frame data of this shooting are in preceding, the corresponding at least one posterior order of frame data of dynamic picture; Or,
Preceding, the corresponding at least one frame data of dynamic picture exist a part at least one frame data of this shooting Centre, this shooting at least one frame data in the posterior order of another part.
As shown in Figure 3 C, the present embodiment is illustrated by taking the first order as an example:
First, the corresponding at least one image frame data of obtained dynamic picture is coded by mobile terminal according to predetermined format Video file.This step can include:
1st, mobile terminal according to predetermined format set video stream encoder, video flowing coding parameter, audio stream encoder and Audio stream coding parameter;
Video flowing coding parameter include video format, the width of image frame data, image frame data it is high;
Audio stream coding parameter includes code check, channel number, if be stereo etc..
2nd, according to video stream encoder corresponding with predetermined format and video flowing coding parameter by the corresponding figure of dynamic picture As frame data are coded into video file.
The above process can also use increase income free cross-platform video and audio stream scheme ffmpeg realizations.
2nd, at least one frame data by this shooting are coded into according to predetermined format in video file.
That is, mobile terminal claps this according to video stream encoder corresponding with predetermined format and video flowing coding parameter The image frame data taken the photograph is coded into video file;If this shooting includes audio frame number evidence, according to corresponding with predetermined format Audio stream encoder and audio stream coding parameter by audio frame number that this shoots according to being coded into video file, obtain target Video file.
Similar, as shown in Figure 3D, the schematic diagram of the third order is as shown in FIGURE 3 E for the schematic diagram of second of order.
In conclusion video capture method provided in this embodiment, by being this shooting by Multi-media Material processing A part of video content in target video file;The entire shooting process for solving current video capture method can not be real The problem of cutting off;Other Multi-media Materials can be based on by having reached, for example, active user or other users section at other times The video file finished has been taken and carries out continuous bat, to complete the effect of this shooting.
It should be added that as long as step 303 is performed before the coding, specific execution sequence is not subject to It is specific to limit.For example, during using the first sequential shoot, step 303 can be corresponding at least by dynamic picture in step 305 One frame data performs after being coded into video file;When for another example, using second of sequential shoot, step 303 can be in step It is performed before rapid 301;When for another example, using the third sequential shoot, step 303 can perform once before step 301, The corresponding at least one frame data of dynamic picture are coded into video file and then secondary execution once in step 305.
It should be added that before step 305, if the corresponding image frame data of dynamic picture is RGB (Red Green Blue, RGB) form and this shooting image frame data for YUV (Luma Chroma, brightness and color) form, The image frame data that then mobile terminal can obtain this shooting is converted to rgb format from yuv format, not only so that picture frame The form of data is consistent, and the image frame data for being also based on rgb format adds filter or special efficacy during continuous clap.
It should be added that before step 305, if the corresponding image frame data of dynamic picture and this shooting The angle of image frame data is different, then mobile terminal rotates this image frame data shot, the figure for obtaining decoding As frame data are identical with the angle for the image frame data that this shoots.So that the continuous figure clapped in obtained target video file As the angle of frame data is consistent.For example, dynamic picture corresponds to vertical image frame data, and this shooting is that shake-hands grip obtains The image frame data of this shooting can then be rotated by 90 °, is converted to vertically by horizontal image frame data by image frame data Image frame data.
A is please referred to Fig.4, it illustrates the method flow diagrams for the video capture method that another embodiment of the present invention provides. The present embodiment is in the video capture method applied to coming in mobile terminal for example, the mobile terminal can be equipped with social activity Class is applied or the mobile terminal of short video sharing application, this method include:
Step 401, Multi-media Material is obtained, Multi-media Material includes picture or video file;
The present embodiment is by Multi-media Material for exemplified by video file, the acquisition methods of video file include following four:
1) obtained from local storage;
Mobile terminal obtains the video file of designated position in local storage after the operational order of user is received.
2) obtained from network memory;
Mobile terminal obtains designated position in the corresponding network memory of user after the operational order of user is received Video file.Network memory can be the various Dropbox positioned at high in the clouds.
3) obtained from the file that the good friend that social class is applied is shared;
It is mobile whole if mobile terminal is the terminal for being equipped with social class application as a kind of novel acquisition modes End can obtain video file from the file that the good friend in the application of social class is shared.
4) video file is obtained in the file shared from the application of short video sharing by other people or platform.
As another novel acquisition modes, if mobile terminal is the terminal for being equipped with short video sharing application, Video file is obtained in the file that mobile terminal can be shared from the application of short video sharing by other people or platform.
For example, as shown in Figure 4 B, mobile terminal is the terminal for being equipped with short video sharing application, user can pass through click " video " button 41 shows pop-up box 42 to trigger mobile terminal, and then user can select a kind of acquisition to regard in pop-up box 42 The mode of frequency file obtains material file.
Step 402, intercept signal is received, a video segment in intercept signal interception video file is as needs Decoded video file;
As shown in Figure 4 C, mobile terminal is shown video file after video file is obtained in the form of time shaft 43 Show on the screen of terminal, user can by dragging selection cursor 44 and clicking on " interception " button 45, video file when Any one video segment is intercepted on countershaft 43 as the decoded video file of needs.
It should be noted that this step is preferred steps.
Step 403, video file is decoded, obtains at least one frame data that video file includes;
For the video file of acquisition, which is decoded by mobile terminal, obtains at least one frame data, frame Data can include image frame data and audio frame number evidence or only include image frame data.This step can include following sub-step Suddenly:
1) the video header file of video file is read, the stream information of video file is obtained from video header file;
The essence of video file is equivalent to one " container ", wherein, image frame data and/or audio frame number are smaller according to this The form of " container " is organized in " container ".Different video formats can be considered as different organizational forms.The tissue shape Formula is usually described by video header file.
Video header file, some essential informations of essential record video:The wide height of video, duration, code check, coded format, Frame list, the sample rate of audio, channel number of audio etc..Include the stream of video flowing in the video file in these essential informations The stream information of information and audio stream.
2) video flowing in video file is obtained according to stream information;Or, the video in video file is obtained according to stream information Stream and audio stream;
When video file is silent video, video flowing is only included in video file, not including audio stream.Mobile terminal can To read the video flowing in video file by the stream information of video flowing.
When video file is sound video, both includes video flowing in video file, further include audio stream.Mobile terminal can With by the stream information of video flowing read video file in video flowing, and pass through audio stream stay information read video file in Audio stream.
3) video stream decoder and decoding video stream parameter are set according to stream information;
The video flowing of different coding form is, it is necessary to corresponding video stream decoder and decoding video stream parameter.According to The stream information of video flowing, mobile terminal set video stream decoder corresponding with the video flowing read and decoding video stream ginseng Number.
4) an at least two field picture frame number is obtained to decoding video stream according to video stream decoder and decoding video stream parameter According to;
5) when video file includes audio stream, audio stream device and audio stream parameter are set according to stream information;
The audio stream of different coding form is, it is necessary to corresponding audio decoder and audio stream parameter.According to sound The stream information of frequency stream, mobile terminal set audio decoder corresponding with the audio stream read and audio stream parameter.
6) an at least frame audio frame number is obtained to audio stream according to audio stream device and audio stream parameter According to.
Obtained image frame data and audio frame number evidence are decoded, is the corresponding at least one frame data of the video file.
Step 404, at least one frame data of this shooting are obtained;
Mobile terminal can obtain at least one frame data of this shooting by built-in camera or external camera. When not shooting sound, frame data only include image frame data;When shooting sound and image at the same time, frame data include picture frame Data further include audio frame number evidence.
For example, mobile terminal is the mobile phone for being built-in with camera, then mobile terminal can be obtained by built-in camera The frame data one by one of this shooting.
For example, mobile terminal is the tablet computer of no built-in camera, then mobile terminal can pass through external camera Obtain the frame data one by one of this shooting.
Step 405, an empty video file is created for this shooting;
Mobile terminal can be that this shooting creates an empty video file, this empty video file is equivalent to one " container ", for storing image frame data and audio frame number evidence.
By taking MP4 forms as an example, this empty video file can only there are one video header file, the one of essential record video A little essential informations:The wide height of video, duration, code check, coded format, frame list, the sample rate of audio, channel number of audio etc..
Step 406, at least one frame data of the corresponding at least one frame data of Multi-media Material and this shooting are pressed It is coded into according to predetermined order in video file, obtains target video file;
Predetermined order can include any one in following three kinds of orders:
The corresponding at least one frame data of video file are in preceding, the posterior order of at least one frame data of this shooting; Or,
At least one frame data of this shooting are in preceding, the corresponding at least one posterior order of frame data of video file; Or,
Preceding, the corresponding at least one frame data of video file exist a part at least one frame data of this shooting Centre, this shooting at least one frame data in the posterior order of another part.
As shown in Figure 4 D, the present embodiment is illustrated by taking the first order as an example:
First, the corresponding at least one frame data of obtained video file are coded into video by mobile terminal according to predetermined format File.This operation can include:
1st, mobile terminal according to predetermined format set video stream encoder, video flowing coding parameter, audio stream encoder and Audio stream coding parameter;
Video flowing coding parameter include video format, the width of image frame data, image frame data it is high;
Audio stream coding parameter includes code check, channel number, if be stereo etc..
2nd, the image frame data that will be obtained according to video stream encoder corresponding with predetermined format and video flowing coding parameter It is coded into video file;If obtained video file includes audio stream, according to audio stream encryption corresponding with predetermined format Wanted increased audio frame number evidence is coded into video file by device and audio stream coding parameter.
The above process can also use increase income free cross-platform video and audio stream scheme ffmpeg realizations.
Second, at least one frame data of this shooting are coded into according to predetermined format in video file.
That is, mobile terminal claps this according to video stream encoder corresponding with predetermined format and video flowing coding parameter The image frame data taken the photograph is coded into video file;If this shooting includes audio frame number evidence, according to corresponding with predetermined format Audio stream encoder and audio stream coding parameter by audio frame number that this shoots according to being coded into video file, obtain target Video file.
Similar, as shown in Figure 4 E, the schematic diagram of the third order is as illustrated in figure 4f for the schematic diagram of second of order.
It should be added that the execution sequence of step 404 is not limited specifically.For example, using the first order During shooting, step 404 can perform after step 405;When for another example, using second of sequential shoot, step 404 can be It is performed before step 401;When for another example, using the third sequential shoot, step 404 can perform once before step 401, After the corresponding at least one frame data of video file are encoded in a step 406, perform again once.
In conclusion video capture method provided in this embodiment, by being this shooting by Multi-media Material processing A part of video content in target video file;The entire shooting process for solving current video capture method can not be real The problem of cutting off;Other Multi-media Materials can be based on by having reached, for example, active user or other users section at other times The video file finished has been taken and carries out continuous bat, to complete the effect of this shooting.
It should be added that before step 406, if the image frame data of obtained video file is RGB (Red Green Blue, RGB) form and this shooting image frame data for YUV (Luma Chroma, brightness and color) form, The image frame data that then mobile terminal can obtain this shooting is converted to rgb format from yuv format, not only so that picture frame The form of data is consistent, and the image frame data for being also based on rgb format adds filter or special efficacy during continuous clap.
It should be added that before step 406, if the image frame data of obtained video file and this shooting Image frame data angle it is different, then the image frame data number of rotation that mobile terminal shoots this makes what decoding obtained Image frame data is identical with the angle for the image frame data that this shoots.So that continuous clap in obtained final video file The angle of image frame data is consistent.For example, dynamic picture corresponds to vertical image frame data, and this shooting is that shake-hands grip obtains Image frame data, then the image frame data of this shooting can be rotated by 90 °, be converted to by horizontal image frame data perpendicular To image frame data.
In the example of a practical application, as shown in Figure 4 G, the present embodiment participates in a short-sighted frequency creation greatly with user Games-time, exemplified by the operating process of mobile terminal, this contest requires entrant using the video that sponsor provides as head material, and Continuous bat is carried out to it, winner is voted in through all users after continuous bat works are uploaded.User short video sharing application in, Into short video capture interface 46;Then, after user clicks on " video " button 47, mobile terminal switches to video acquisition interface 48;After user's selection " participating in short-sighted frequency creation contest " option 49, mobile terminal switches to short-sighted frequency creation contest interface 50, should Short-sighted frequency creation contest interface 50 includes a head material 51, which is the video file having had been taken. User can click on the head material 51 and carry out preview, if it is determined that and competition can then click on " download and continue and clap " button 52, this When mobile terminal the head material 51 can be downloaded to local, then decoding obtain several image frame datas and audio frame number According to, it then encodes in the empty video file that most this shooting is newly-built, and continuous bat interface 53 is jumped to, after user is prompted to carry out It is continuous to clap.User can carry out this shooting with Continued depression shooting push button 54, each figure that then mobile terminal shoots this As frame data and audio frame number are according to continuing to be coded into the video file of this shooting, final target video file is obtained.It should First 4 seconds corresponding head materials 51 in target video file, latter 4 seconds regarding for user oneself shooting in the target video file Frequently.Afterwards, during user can also apply the target video sharing files to social class or it is uploaded to short video sharing application Official's server in, so that other users is showed to vote.
Supplementary notes are also needed to, above-described embodiment comes using Multi-media Material as 1 for example, but for more matchmakers Voxel material is the situation of 2 or 2 or more, be those skilled in the art based on the easy full of beard of above-described embodiment and part, no It repeats one by one again.
Fig. 5 is refer to, it illustrates the block diagrams of video capture device provided by one embodiment of the present invention.This is regarded Frequency filming apparatus can pass through all or part being implemented in combination with as mobile terminal of software, hardware or both.It should Video capture device, including:Material obtaining module 510, this taking module 510 and video encoding module 530;
Material obtaining module 510, for obtaining Multi-media Material, Multi-media Material includes picture or video file;
This taking module 520, for obtaining at least one frame data of this shooting, frame data include image frame data With former or whole two kind of the audio frame number in;
Video processing module 530, for being a part of video content in target video file by Multi-media Material processing, It is another part video content of target video file by least one frame data processing of this shooting, obtains target video text Part.
In conclusion video capture device provided in this embodiment, after Multi-media Material is handled, is re-encoded into In the video file of this shooting;Solve that the entire shooting process of current video capture method can not interrupt really asks Topic;Having reached can be continued based on active user or other users video file that section has been taken finishing at other times It claps, to complete the effect of this shooting.
Fig. 6 is refer to, it illustrates the block diagrams of video capture device provided by one embodiment of the present invention.This is regarded Frequency filming apparatus can pass through all or part being implemented in combination with as mobile terminal of software, hardware or both.It should Video capture device, including:Material obtaining module 510, this taking module 520 and video encoding module 530;
Material obtaining module 510, for obtaining Multi-media Material, Multi-media Material includes picture or video file;
This taking module 520, for obtaining at least one frame data of this shooting, frame data include image frame data With former or whole two kind of the audio frame number in;
Video processing module 530, for being a part of video content in target video file by Multi-media Material processing, It is another part video content of target video file by least one frame data processing of this shooting, obtains target video text Part.
Optionally, video processing module 530 includes:Material processing unit 531, file creating unit 531 and data encoding Unit 533;
Material processing unit 531 for handling Multi-media Material, obtains corresponding with Multi-media Material at least one A frame data;
File creating unit 532, for creating an empty video file for this shooting;
Data encoding unit 533, for the corresponding at least one frame data of Multi-media Material and this to be shot at least One frame data is coded into according to predetermined order in video file, obtains target video file.
Optionally, predetermined order, including:
For the corresponding at least one frame data of Multi-media Material preceding, at least one frame data of this shooting are posterior suitable Sequence;Or,
For at least one frame data of this shooting preceding, the corresponding at least one frame data of Multi-media Material are posterior suitable Sequence;Or,
A part at least one frame data of this shooting is in preceding, the corresponding at least one frame data of Multi-media Material The posterior order of another part in centre, at least one frame data of this shooting.
Optionally, material processing unit 531, including:
First static treatment subelement 531a, for when Multi-media Material is static images, static images directly to be made For image frame data.
Optionally, material processing unit 531, including:
Second static treatment subelement 531b for static images to be done with dynamic change processing, obtains dynamic change processing Corresponding at least one image frame data in the process.
Optionally, material processing unit 531, including:
Dynamic picture handles subelement 531c, for when Multi-media Material is dynamic picture, being torn open to dynamic picture Office is managed, and obtains at least one image frame data included by dynamic picture.
Optionally, material processing unit 531, including:
Video file decoding subunit 531d, for when Multi-media Material is video file, being solved to video file Code, obtains at least one frame data that video file includes.
Optionally, material processing unit 531, including;
Video file intercepts subelement 531e, for receiving intercept signal, is intercepted according to intercept signal in video file One video segment is as the decoded video file of needs.
Optionally, video file decoding subunit 531d,
For reading the video header file of video file, the stream information of video file is obtained from video header file;According to Stream information obtains the video flowing in video file;Or, the video flowing and audio stream in video file are obtained according to stream information;
Video stream decoder and decoding video stream parameter are set according to stream information;
According to video stream decoder and decoding video stream parameter to decoding video stream, an at least two field picture frame data are obtained;
When video file includes audio stream, audio stream device and audio stream parameter are set according to stream information;
According to audio stream device and audio stream parameter to audio stream, an at least frame audio frame number evidence is obtained.
Optionally, device further includes:Format converting module 540;
Format converting module 540, if for the corresponding image frame data of Multi-media Material for RGB rgb format and this The image frame data of shooting is brightness and color yuv format, then is converted to the image frame data that this shooting obtains from yuv format Rgb format.
Optionally, device further includes:Image rotation module 550;
Image rotation module 550, if for the corresponding image frame data of Multi-media Material and the number of image frames of this shooting According to angle it is different, then by the image frame data number of rotation of this shooting, make the corresponding image frame data of Multi-media Material with The angle of the image frame data of this shooting is identical.
Optionally, material obtaining module 510 includes:Local acquiring unit 511, Dropbox acquiring unit 512, social acquisition are single Member 513 and platform acquiring unit 514;
Local acquiring unit 511, for obtaining Multi-media Material from local storage;
Network acquiring unit 512, for obtaining Multi-media Material from network storage disk;
Social acquiring unit 513, for obtaining more matchmakers of good friend from the file that the good friend in the application of social class is shared Voxel material;
Platform acquiring unit 514, for being obtained from the application of short video sharing in the file shared by other people or platform Multi-media Material.
In conclusion video capture device provided in this embodiment, after Multi-media Material is handled, is re-encoded into In the video file of this shooting;Solve that the entire shooting process of current video capture method can not interrupt really asks Topic;Having reached can be continued based on active user or other users video file that section has been taken finishing at other times It claps, to complete the effect of this shooting.
It should be noted that:The video capture device that above-described embodiment provides is when shooting video, only with above-mentioned each function The division progress of module, can be as needed and by above-mentioned function distribution by different function moulds for example, in practical application Block is completed, i.e., the internal structure of equipment is divided into different function modules, to complete all or part of work(described above Energy.In addition, the video capture device that above-described embodiment provides belongs to same design with video capture embodiment of the method, it is specific real Existing process refers to embodiment of the method, and which is not described herein again.
Fig. 7 is refer to, it illustrates the structure diagrams for the mobile terminal that one embodiment of the present of invention provides.The movement Terminal 700 is equipped with the client of video processing, video social activity, video sharing etc, and client is used to implement above-described embodiment The video-splicing method of middle offer, specifically:
Mobile terminal 700 can include RF (Radio Frequency, radio frequency) circuit 710, including there are one or one with Memory 720, input unit 730, display unit 740, sensor 750, the voicefrequency circuit of upper computer readable storage medium 760th, short range wireless transmission module 770, including there are one or more than one processing core processor 780 and power supply 790 grade components.It will be understood by those skilled in the art that mobile terminal structure shown in Fig. 6 is not formed to mobile terminal It limits, can include either combining some components or different components arrangement than illustrating more or fewer components.Wherein:
RF circuits 710 can be used for receive and send messages or communication process in, signal sends and receivees, particularly, by base station After downlink information receives, transfer to one or more than one processor 780 is handled;In addition, will be related to the data sending of uplink to Base station.In general, RF circuits 710 include but not limited to antenna, at least one amplifier, tuner, one or more oscillators, use Family identity module (SIM) card, transceiver, coupler, LNA (Low Noise Amplifier, low-noise amplifier), duplex Device etc..In addition, RF circuits 710 can also be communicated by wireless communication with network and other equipment.Wireless communication, which can use, appoints One communication standard or agreement, including but not limited to GSM, (Global System of Mobile communication, the whole world are moved Dynamic communication system), GPRS (General Packet Radio Service, general packet radio service), CDMA (Code Division Multiple Access, CDMA), WCDMA (Wideband Code Division Multiple Access, wideband code division multiple access), LTE (Long Term Evolution, Long Term Evolution), Email, SMS (Short Messaging Service, Short Message Service) etc..Memory 720 can be used for storage software program and module, for example, storage Device 720 can be used for storing preset time list, can be also used for the software program of storage acquisition voice signal, realizes keyword The software program of identification, the software program for realizing continuous speech recognition and the software program for realizing setting prompting item, may be used also For binding relationship of storage wireless access point and user account etc..Processor 780 is stored in memory 720 by operation Software program and module, so as to perform various functions in application and data processing, such as the embodiment of the present invention " receive with The function of the retrieval lines of graphical data-in ", function of " detecting whether exist with retrieving the matched information model of lines " etc. Deng.Memory 720 can mainly include storing program area and storage data field, wherein, storing program area can storage program area, extremely Application program (such as sound-playing function, image player function etc.) needed for a few function etc.;Storage data field can store Created data (such as voice data, phone directory etc.) etc. are used according to mobile terminal 700.In addition, memory 720 can be with Including high-speed random access memory, nonvolatile memory, for example, at least disk memory, a flash memory can also be included Device or other volatile solid-state parts.Correspondingly, memory 720 can also include Memory Controller, to provide place Manage the access of device 780 and input unit 730 to memory 720.
Input unit 730 can be used for the number for receiving input or character information and generate and user setting and function Control related keyboard, mouse, operation lever, optics or the input of trace ball signal.Specifically, input unit 730 may include to touch Sensitive surfaces 731 and other input equipments 732.Touch sensitive surface 731, also referred to as touch display screen or Trackpad, collect and use Family on it or neighbouring touch operation (such as user using any suitable object such as finger, stylus or attachment in touch-sensitive table Operation on face 731 or near touch sensitive surface 731), and corresponding attachment device is driven according to preset formula.It is optional , touch sensitive surface 731 may include both touch detecting apparatus and touch controller.Wherein, touch detecting apparatus detection is used The touch orientation at family, and the signal that touch operation is brought is detected, transmit a signal to touch controller;Touch controller is from touch Touch information is received in detection device, and is converted into contact coordinate, then gives processor 780, and processor 780 can be received The order sent simultaneously is performed.Furthermore, it is possible to using polytypes such as resistance-type, condenser type, infrared ray and surface acoustic waves Realize touch sensitive surface 731.Except touch sensitive surface 731, input unit 730 can also include other input equipments 732.Specifically, Other input equipments 732 can include but is not limited to physical keyboard, function key (such as volume control button, switch key etc.), One or more in trace ball, mouse, operation lever etc..
Display unit 740 can be used for display by information input by user or be supplied to the information and mobile terminal of user 700 various graphical user interface, these graphical user interface can by figure, text, icon, video and its any combination Lai It forms.Display unit 740 may include display panel 741, optionally, may be employed LCD (Liquid Crystal Display, Liquid crystal display), the forms such as OLED (Organic Light-Emitting Diode, Organic Light Emitting Diode) configure display Panel 741.Further, touch sensitive surface 631 can be covered on display panel 741, when touch sensitive surface 731 detects on it Or after neighbouring touch operation, processor 780 is sent to determine the type of touch event, is followed by subsequent processing device 780 according to touch The type of event provides corresponding visual output on display panel 741.Although in the figure 7, touch sensitive surface 731 and display panel 741 be the component independent as two to realize input and input function, but in some embodiments it is possible to by touch sensitive surface 731 integrate with display panel 741 and realize and output and input function.
Mobile terminal 700 may also include at least one sensor 750, for example, optical sensor, motion sensor and other Sensor.Specifically, optical sensor may include ambient light sensor and proximity sensor, wherein, ambient light sensor can basis The light and shade of ambient light adjusts the brightness of display panel 741, proximity sensor can when mobile terminal 700 is moved in one's ear, Close display panel 741 and/or backlight.As one kind of motion sensor, gravity accelerometer can detect all directions The size of upper (generally three axis) acceleration, can detect that size and the direction of gravity, available for identification mobile phone posture when static Application (such as horizontal/vertical screen switching, dependent game, magnetometer pose calibrating), Vibration identification correlation function (for example pedometer, strikes Hit) etc.;Gyroscope, barometer, hygrometer, thermometer, infrared ray sensor for can also configure as mobile terminal 700 etc. other Sensor, details are not described herein.
Voicefrequency circuit 760, loud speaker 761, microphone 762 can provide the audio interface between user and mobile terminal 700. The transformed electric signal of the voice data received can be transferred to loud speaker 761, is converted by loud speaker 761 by voicefrequency circuit 760 It is exported for voice signal;On the other hand, the voice signal of collection is converted to electric signal by microphone 762, is connect by voicefrequency circuit 760 Voice data is converted to after receipts, then after voice data output processor 780 is handled, through RF circuits 710 to be sent to another shifting Voice data is exported to memory 720 to be further processed by dynamic terminal.Voicefrequency circuit 760 is also possible that earplug Jack, to provide the communication of peripheral hardware earphone and mobile terminal 700.
Short range wireless transmission module 770 can be WIFI (wireless fidelity, Wireless Fidelity) modules or indigo plant Tooth module etc..Mobile terminal 700 can help user to send and receive e-mail, browse net by short range wireless transmission module 770 Page and access streaming video etc., it has provided wireless broadband internet to the user and has accessed.Although Fig. 7 shows short-distance wireless Transport module 770, but it is understood that, and must be configured into for mobile terminal 700 is not belonging to, it completely can be as needed It is omitted in the scope of essence for not changing invention.
Processor 780 is the control centre of mobile terminal 700, utilizes various interfaces and the entire mobile terminal of connection Various pieces are stored in by running or performing the software program being stored in memory 720 and/or module and call Data in reservoir 720 perform the various functions of mobile terminal 700 and processing data, so as to carry out whole prison to mobile terminal Control.Optionally, processor 780 may include one or more processing cores;Optionally, processor 780 can integrate application processor And modem processor, wherein, the main processing operation system of application processor, user interface and application program etc., modulatedemodulate Processor is adjusted mainly to handle wireless communication.It is understood that above-mentioned modem processor can not also be integrated into processor In 780.
Mobile terminal 700 is further included to the power supply 790 (such as battery) of all parts power supply, it is preferred that power supply can lead to Cross power-supply management system and processor 780 be logically contiguous, so as to by power-supply management system realize management charge, electric discharge and The functions such as power managed.Power supply 790 can also include one or more direct current or AC power, recharging system, electricity The random components such as source fault detection circuit, power supply changeover device or inverter, power supply status indicator.
Although being not shown, mobile terminal 700 can also include camera, bluetooth module etc., and details are not described herein.
Mobile terminal 700 has further included either one of them or one of more than one program of memory and one Procedure above is stored in memory, and is configured to perform above-mentioned each method implementation by one or more than one processor The video capture method of example.
The embodiments of the present invention are for illustration only, do not represent the quality of embodiment.
One of ordinary skill in the art will appreciate that hardware can be passed through by realizing all or part of step of above-described embodiment It completes, relevant hardware can also be instructed to complete by program, the program can be stored in a kind of computer-readable In storage medium, storage medium mentioned above can be read-only memory, disk or CD etc..
The foregoing is merely presently preferred embodiments of the present invention, is not intended to limit the invention, it is all the present invention spirit and Within principle, any modifications, equivalent replacements and improvements are made should all be included in the protection scope of the present invention.

Claims (23)

  1. A kind of 1. video capture method, which is characterized in that the described method includes:
    Multi-media Material is obtained, the Multi-media Material includes picture or video file;
    At least one frame data of this shooting are obtained, it is previous in that the frame data include image frame data and audio frame number Kind is two kinds whole;
    It is a part of video content in target video file by Multi-media Material processing, by this described shooting at least One frame data processing is another part video content of the target video file, obtains the target video file;
    Wherein, described by Multi-media Material processing is a part of video content in target video file, will it is described this At least one frame data processing of shooting is another part video content of the target video file, obtains the target video File, including:
    The Multi-media Material is handled, obtains at least one frame data corresponding with the Multi-media Material;
    An empty video file is created for this shooting;
    By the corresponding at least one frame data of the Multi-media Material and at least one frame data of this shooting according to pre- Determine sequential encoding to enter in the video file, obtain the target video file.
  2. 2. according to the method described in claim 1, it is characterized in that, the predetermined order includes:
    For the corresponding at least one frame data of the Multi-media Material preceding, at least one frame data of this shooting are posterior Sequentially;Or,
    For at least one frame data of this shooting preceding, the corresponding at least one frame data of the Multi-media Material are posterior Sequentially;Or,
    A part at least one frame data of this shooting is preceding, the corresponding at least one frame of the Multi-media Material Another part posterior order of the data in centre, at least one frame data of this shooting.
  3. 3. according to the method described in claim 1, it is characterized in that, described handle the Multi-media Material, obtain with The corresponding at least one frame data of the Multi-media Material, including:
    When the Multi-media Material is static images, using the static images as an image frame data.
  4. 4. according to the method described in claim 1, it is characterized in that, described handle the Multi-media Material, obtain with The corresponding at least one frame data of the Multi-media Material, including:
    When the Multi-media Material is static images, dynamic change processing is done to the static images, obtains the dynamic and becomes Change at least one image frame data corresponding in processing procedure;
    Wherein, the dynamic change processing includes:Translation variation;And/or scaling variation;It is and/or rotationally-varying;And/or disappear Hidden variation.
  5. 5. according to the method described in claim 1, it is characterized in that, described handle the Multi-media Material, obtain with The corresponding at least one frame data of the Multi-media Material, including:
    When the Multi-media Material is dynamic picture, deconsolidation process is carried out to the dynamic picture, obtains the dynamic picture Included at least one image frame data.
  6. 6. according to the method described in claim 1, it is characterized in that, described handle the Multi-media Material, obtain with The corresponding at least one frame data of the Multi-media Material, including:
    When the Multi-media Material is video file, the video file is decoded, obtaining the video file includes At least one frame data.
  7. 7. according to the method described in claim 6, it is characterized in that, described be decoded the video file, obtain described Before at least one frame data that video file includes, further include:
    Receive intercept signal;
    A video segment in the video file is intercepted according to the intercept signal and is used as needs decoded video file.
  8. 8. according to the method described in claim 6, it is characterized in that, described be decoded the video file, obtain at least One frame data, including:
    The video header file of the video file is read, the stream information of the video file is obtained from the video header file;
    Video flowing in the video file is obtained according to the stream information;Or, the video text is obtained according to the stream information Video flowing and audio stream in part;
    Video stream decoder and decoding video stream parameter are set according to the stream information;
    According to the video stream decoder and the decoding video stream parameter to the decoding video stream, an at least two field picture is obtained Frame data;
    When the video file includes the audio stream, audio stream device and audio stream are set according to the stream information Parameter;
    According to the audio stream device and the audio stream parameter to the audio stream, an at least frame audio is obtained Frame data.
  9. 9. method according to any one of claims 1 to 8, which is characterized in that described that the Multi-media Material is corresponding extremely Few frame data and at least one frame data of this shooting are coded into according to predetermined order in the video file, are obtained To before the target video file, further include:
    If the image frame data of the corresponding image frame data of the Multi-media Material this shooting for RGB rgb format For brightness and color yuv format, then the described image frame data obtained this described shooting are converted to described from the yuv format Rgb format.
  10. 10. method according to any one of claims 1 to 8, which is characterized in that described that the Multi-media Material is corresponding extremely Few frame data and at least one frame data of this shooting are coded into according to predetermined order in the video file, are obtained To before the target video file, further include:
    If the corresponding image frame data of the Multi-media Material is different from the angle of the image frame data of this shooting, general The described image frame data number of rotation of this shooting, makes the corresponding image frame data of the Multi-media Material and described The angle of the described image frame data of secondary shooting is identical.
  11. 11. method according to any one of claims 1 to 8, which is characterized in that the acquisition Multi-media Material, including:
    The Multi-media Material is obtained from local storage;
    And/or
    The Multi-media Material is obtained from network storage disk;
    And/or the Multi-media Material of the good friend is obtained from the file that the good friend in the application of social class is shared;
    And/or
    The Multi-media Material is obtained in the file shared from the application of short video sharing by other people or platform.
  12. 12. a kind of video capture device, which is characterized in that described device includes:
    Material obtaining module, for obtaining Multi-media Material, the Multi-media Material includes picture or video file;
    This taking module, for obtain this shooting at least one frame data, the frame data include image frame data and Former or all two kind of the audio frame number in;
    Video processing module, will for being a part of video content in target video file by Multi-media Material processing At least one frame data processing of this shooting is another part video content of the target video file, is obtained described Target video file;
    Wherein, the video processing module includes:Material processing unit, file creating unit and data encoding unit;
    The material processing unit for handling the Multi-media Material, obtains corresponding with the Multi-media Material At least one frame data;
    The file creating unit, for creating an empty video file for this shooting;
    The data encoding unit, for by the corresponding at least one frame data of the Multi-media Material and it is described this shooting At least one frame data are coded into according to predetermined order in the video file, obtain the target video file.
  13. 13. device according to claim 12, which is characterized in that the predetermined order includes:
    For the corresponding at least one frame data of the Multi-media Material preceding, at least one frame data of this shooting are posterior Sequentially;Or,
    For at least one frame data of this shooting preceding, the corresponding at least one frame data of the Multi-media Material are posterior Sequentially;Or,
    A part at least one frame data of this shooting is preceding, the corresponding at least one frame of the Multi-media Material Another part posterior order of the data in centre, at least one frame data of this shooting.
  14. 14. device according to claim 12, which is characterized in that the material processing unit, including:
    First static treatment subelement, for when the Multi-media Material is static images, the static images directly to be made For image frame data.
  15. 15. device according to claim 12, which is characterized in that the material processing unit, including:
    Second static treatment subelement for doing dynamic change processing to the static images, obtains the dynamic change processing Corresponding at least one image frame data in the process;
    Wherein, the dynamic change processing includes:Translation variation;And/or scaling variation;It is and/or rotationally-varying;And/or disappear Hidden variation.
  16. 16. device according to claim 12, which is characterized in that the material processing unit, including:
    Dynamic picture handles subelement, for when the Multi-media Material is dynamic picture, being torn open to the dynamic picture Office is managed, and obtains at least one image frame data included by the dynamic picture.
  17. 17. device according to claim 12, which is characterized in that the material processing unit, including:
    Video file decoding subunit, for when the Multi-media Material is video file, being solved to the video file Code, obtains at least one frame data that the video file includes.
  18. 18. device according to claim 17, which is characterized in that the material processing unit, including:
    Video file intercepts subelement, for receiving intercept signal, is intercepted according to the intercept signal in the video file One video segment is as the decoded video file of needs.
  19. 19. device according to claim 17, which is characterized in that the video file decoding subunit is used for:
    The video header file of the video file is read, the stream information of the video file is obtained from the video header file;
    Video flowing in the video file is obtained according to the stream information;Or, the video text is obtained according to the stream information Video flowing and audio stream in part;
    Video stream decoder and decoding video stream parameter are set according to the stream information;
    According to the video stream decoder and the decoding video stream parameter to the decoding video stream, an at least two field picture is obtained Frame data;
    When the video file includes the audio stream, audio stream device and audio stream are set according to the stream information Parameter;
    According to the audio stream device and the audio stream parameter to the audio stream, an at least frame audio is obtained Frame data.
  20. 20. according to any device of claim 12 to 19, which is characterized in that described device further includes:Format conversion mould Block;
    The format converting module, if for the corresponding image frame data of the Multi-media Material for RGB rgb format institute The image frame data of this shooting is stated as brightness and color yuv format, then the described image frame data obtained this described shooting The rgb format is converted to from the yuv format.
  21. 21. according to any device of claim 12 to 19, which is characterized in that described device further includes:Image rotation mould Block;
    Described image rotary module, if for the corresponding image frame data of the Multi-media Material and the image of this shooting The angle of frame data is different, then by the described image frame data number of rotation of this shooting, makes the Multi-media Material pair The image frame data answered is identical with the angle of the described image frame data of this shooting.
  22. 22. according to any device of claim 12 to 19, which is characterized in that the material obtaining module includes:It is local Acquiring unit and/or, Dropbox acquiring unit and/or, social acquiring unit and/or, platform acquiring unit;
    The local acquiring unit, for obtaining the Multi-media Material from local storage;
    The Dropbox acquiring unit, for obtaining the Multi-media Material from network storage disk;
    The social activity acquiring unit, for being obtained from the file that the good friend in the application of social class is shared described in the good friend Multi-media Material;
    The platform acquiring unit, described in being obtained in the file shared as other people or platform from the application of short video sharing Multi-media Material.
  23. 23. a kind of mobile terminal, which is characterized in that the mobile terminal, including:
    One or more than one processor;
    Memory;
    And one or more than one program, wherein the one or more programs are stored in the memory In, and be configured to be performed by the one or more processor, the one or more programs, which include, to be used In the instruction for carrying out following operation:
    Multi-media Material is obtained, the Multi-media Material includes picture or video file;
    At least one frame data of this shooting are obtained, it is previous in that the frame data include image frame data and audio frame number Kind is two kinds whole;
    It is a part of video content in target video file by Multi-media Material processing, by this described shooting at least One frame data processing is another part video content of the target video file, obtains the target video file;
    Wherein, described by Multi-media Material processing is a part of video content in target video file, will it is described this At least one frame data processing of shooting is another part video content of the target video file, obtains the target video File, including:
    The Multi-media Material is handled, obtains at least one frame data corresponding with the Multi-media Material;
    An empty video file is created for this shooting;
    By the corresponding at least one frame data of the Multi-media Material and at least one frame data of this shooting according to pre- Determine sequential encoding to enter in the video file, obtain the target video file.
CN201410268233.XA 2014-06-16 2014-06-16 Video capture method and device Active CN105187692B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410268233.XA CN105187692B (en) 2014-06-16 2014-06-16 Video capture method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410268233.XA CN105187692B (en) 2014-06-16 2014-06-16 Video capture method and device

Publications (2)

Publication Number Publication Date
CN105187692A CN105187692A (en) 2015-12-23
CN105187692B true CN105187692B (en) 2018-05-18

Family

ID=54909524

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410268233.XA Active CN105187692B (en) 2014-06-16 2014-06-16 Video capture method and device

Country Status (1)

Country Link
CN (1) CN105187692B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105681891A (en) * 2016-01-28 2016-06-15 杭州秀娱科技有限公司 Mobile terminal used method for embedding user video in scene
CN107609012B (en) * 2017-07-31 2019-03-29 珠海市魅族科技有限公司 Multimedia file treating method and apparatus, computer installation, readable storage medium storing program for executing
CN108111752A (en) * 2017-12-12 2018-06-01 北京达佳互联信息技术有限公司 video capture method, device and mobile terminal
CN108377334B (en) * 2018-04-03 2021-06-04 阿里巴巴(中国)有限公司 Short video shooting method and device and electronic terminal
CN109120997A (en) * 2018-09-30 2019-01-01 北京微播视界科技有限公司 Method for processing video frequency, device, terminal and medium
CN109547850B (en) * 2018-11-22 2021-04-06 杭州秋茶网络科技有限公司 Video shooting error correction method and related product
CN112351203B (en) * 2020-10-26 2022-04-08 北京达佳互联信息技术有限公司 Video shooting method and device, electronic equipment and storage medium
CN113473224B (en) * 2021-06-29 2023-05-23 北京达佳互联信息技术有限公司 Video processing method, video processing device, electronic equipment and computer readable storage medium
CN115119038B (en) * 2022-06-13 2023-09-19 北京达佳互联信息技术有限公司 Information display method and device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101056385A (en) * 2007-04-29 2007-10-17 华为技术有限公司 Video communication method, video synthesizing processor, terminal and server
CN101489087A (en) * 2008-01-18 2009-07-22 德信智能手机技术(北京)有限公司 Image synthetic recording method in video calling process
CN103702041A (en) * 2013-12-30 2014-04-02 乐视网信息技术(北京)股份有限公司 Method and device for realizing pause continuation shooting of video
CN104519262A (en) * 2013-09-27 2015-04-15 腾讯科技(深圳)有限公司 Method, device for acquiring video data, and terminal

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1287518B1 (en) * 2000-04-07 2010-09-15 Dartfish SA Automated stroboscoping of video sequences

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101056385A (en) * 2007-04-29 2007-10-17 华为技术有限公司 Video communication method, video synthesizing processor, terminal and server
CN101489087A (en) * 2008-01-18 2009-07-22 德信智能手机技术(北京)有限公司 Image synthetic recording method in video calling process
CN104519262A (en) * 2013-09-27 2015-04-15 腾讯科技(深圳)有限公司 Method, device for acquiring video data, and terminal
CN103702041A (en) * 2013-12-30 2014-04-02 乐视网信息技术(北京)股份有限公司 Method and device for realizing pause continuation shooting of video

Also Published As

Publication number Publication date
CN105187692A (en) 2015-12-23

Similar Documents

Publication Publication Date Title
CN105187692B (en) Video capture method and device
CN104967902B (en) Video sharing method, apparatus and system
CN104811787B (en) Game video recording method and device
CN108924464B (en) Video file generation method and device and storage medium
KR101874895B1 (en) Method for providing augmented reality and terminal supporting the same
CN108540724A (en) A kind of image pickup method and mobile terminal
CN104853081B (en) Breakpoint image pickup method, device and mobile terminal
WO2018228168A1 (en) Image processing method and related product
CN105183296B (en) interactive interface display method and device
CN106937039A (en) A kind of imaging method based on dual camera, mobile terminal and storage medium
CN108259788A (en) Video editing method, terminal and computer readable storage medium
CN104469143A (en) Video sharing method and device
CN105187733B (en) Method for processing video frequency, device and terminal
CN103220490A (en) Special effect implementation method in video communication and video user terminal
CN106791958A (en) Position marker information generation method and device
CN108600647A (en) Shooting preview method, mobile terminal and storage medium
CN106973321B (en) Determine the method and device of video cardton
CN107635110A (en) A kind of video interception method and terminal
CN109068052A (en) video capture method, mobile terminal and computer readable storage medium
CN108108649A (en) Auth method and device
CN107948530A (en) A kind of image processing method, terminal and computer-readable recording medium
CN110149517A (en) Method, apparatus, electronic equipment and the computer storage medium of video processing
CN104036536A (en) Generating method and apparatus of stop motion animation
CN107943417A (en) Image processing method, terminal, computer-readable storage medium and computer program
CN109215655A (en) The method and mobile terminal of text are added in video

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant