WO2015196937A1 - 一种录制视频的方法和装置 - Google Patents
一种录制视频的方法和装置 Download PDFInfo
- Publication number
- WO2015196937A1 WO2015196937A1 PCT/CN2015/081457 CN2015081457W WO2015196937A1 WO 2015196937 A1 WO2015196937 A1 WO 2015196937A1 CN 2015081457 W CN2015081457 W CN 2015081457W WO 2015196937 A1 WO2015196937 A1 WO 2015196937A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- video
- image data
- user
- recording
- module
- Prior art date
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/60—Control of cameras or camera modules
- H04N23/667—Camera operation mode switching, e.g. between still and video, sport and normal or high- and low-resolution modes
-
- G—PHYSICS
- G11—INFORMATION STORAGE
- G11B—INFORMATION STORAGE BASED ON RELATIVE MOVEMENT BETWEEN RECORD CARRIER AND TRANSDUCER
- G11B31/00—Arrangements for the associated working of recording or reproducing apparatus with related apparatus
- G11B31/006—Arrangements for the associated working of recording or reproducing apparatus with related apparatus with video camera or receiver
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/60—Control of cameras or camera modules
- H04N23/62—Control of parameters via user interfaces
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N5/00—Details of television systems
- H04N5/222—Studio circuitry; Studio devices; Studio equipment
- H04N5/262—Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
- H04N5/2621—Cameras specially adapted for the electronic generation of special effects during image pickup, e.g. digital cameras, camcorders, video cameras having integrated special effects capability
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N5/00—Details of television systems
- H04N5/76—Television signal recording
- H04N5/765—Interface circuits between an apparatus for recording and another apparatus
- H04N5/77—Interface circuits between an apparatus for recording and another apparatus between a recording apparatus and a television camera
- H04N5/772—Interface circuits between an apparatus for recording and another apparatus between a recording apparatus and a television camera the recording apparatus and the television camera being placed in the same enclosure
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N9/00—Details of colour television systems
- H04N9/79—Processing of colour television signals in connection with recording
- H04N9/7921—Processing of colour television signals in connection with recording for more than one processing mode
- H04N9/7925—Processing of colour television signals in connection with recording for more than one processing mode for more than one standard
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N9/00—Details of colour television systems
- H04N9/79—Processing of colour television signals in connection with recording
- H04N9/80—Transformation of the television signal for recording, e.g. modulation, frequency changing; Inverse transformation for playback
- H04N9/802—Transformation of the television signal for recording, e.g. modulation, frequency changing; Inverse transformation for playback involving processing of the sound signal
Definitions
- This paper relates to the field of data processing, and in particular to a method and apparatus for recording video.
- the function of recording video on a mobile terminal has many limitations, for example, it cannot be paused in the middle, the sound has no special effect, and the image is not interesting. Video post-production can also be made to achieve special effects, but the professional requirements are high, and the real-time performance is not strong.
- the mobile terminal has a function of generating a GIF (Graphics Interchange Format) in the preview interface, but this method generates a temporary image file, and the image point accuracy is lost due to the limitation of the GIF file, in view of the movement.
- GIF Graphics Interchange Format
- Embodiments of the present invention provide a method and an apparatus for recording video to solve the problem that a mobile terminal cannot record video at intervals.
- An embodiment of the present invention provides a method for recording video, including the following steps:
- the image data is repeatedly captured at intervals, and the image data captured at intervals is encoded
- the encoded image data is generated according to the video file format set by the user.
- the method before performing the encoding process on the image data that is captured by the interval, the method further includes: performing special effect processing on the image data that is captured by the interval, where the special effect processing includes one or more of the following contents: Effect processing, filter effects, special scene effects.
- the method further includes: controlling to open the audio device, receiving audio data; and performing encoding processing on the audio data.
- the method before performing the encoding process on the audio data, the method further includes: performing special effect processing on the received audio data, where the special effect processing includes one or more of the following contents: special effect recording, mixing , change sound, change tone, shift speed.
- the method for generating the video file is: generating the video file according to the video file format set by the user according to the end instruction of the user recording the video, the encoded image data, and the encoded audio data.
- the method further includes: providing a user operation interface, configured to set an interval time for recording the video.
- the image data comprises camera data, or custom bitmaps, or screen data, or textures in an OpenGL rendering system.
- the encoded image data is generated according to a video file format set by the user, and the video file is generated according to the video file format set by the user and the set display timestamp PTS. , generate a video file.
- An embodiment of the present invention further provides an apparatus for recording video, including:
- the image information collecting module is configured to capture image data according to an interval instruction of the user to record the video and an interval time preset by the user;
- a video encoding module configured to perform encoding processing on image data that is captured by the image information collecting module
- the video file generating module is configured to generate the video file according to the video file format set by the user according to the image data processed by the video encoding module according to the end instruction of the user recording the video.
- the device further includes: a parameter setting module, configured to set an interval for recording video time.
- a parameter setting module configured to set an interval for recording video time.
- the parameter setting module is further configured to set a display timestamp PTS when the video file is generated;
- the video file generating module is configured to generate the video file according to the video file format set by the parameter setting module and the display time stamp PTS when the video file is generated.
- the image data comprises camera data, or custom bitmaps, or screen data, or textures in an OpenGL rendering system.
- the device further includes: an image special effect processing module, configured to perform special effect processing on the image data that is captured by the image information collection module, the special effect processing including one or more of the following contents: a basic effect Processing, filter effects, special scene effects.
- an image special effect processing module configured to perform special effect processing on the image data that is captured by the image information collection module, the special effect processing including one or more of the following contents: a basic effect Processing, filter effects, special scene effects.
- the apparatus further comprises: an audio collection and encoding module configured to control the opening of the audio device, receive the audio data, and perform encoding processing on the audio data.
- an audio collection and encoding module configured to control the opening of the audio device, receive the audio data, and perform encoding processing on the audio data.
- the device further includes: an audio special effect processing module, configured to perform special effect processing on the received audio data, where the special effect processing includes one or more of the following: special effect recording, mixing, changing, transposing, Variable speed.
- special effect processing includes one or more of the following: special effect recording, mixing, changing, transposing, Variable speed.
- the embodiment of the invention further provides a computer readable storage medium storing program instructions, which can be implemented when the program instructions are executed.
- the method and device for recording video provided by the embodiments of the present invention capture the image data by interval and perform encoding processing, and then package the encoded image data to generate a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- the method and device for recording video capture the image data by interval and perform encoding processing, and then package the encoded image data to generate a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- PTS display time stamp
- FIG. 1 is a flowchart of a method for recording video according to Embodiment 1 of the present invention
- FIG. 2 is a schematic structural diagram of an apparatus for recording video according to Embodiment 2 of the present invention.
- FIG. 3 is a flowchart of a method for recording video according to Embodiment 3 of the present invention.
- FIG. 4 is a schematic structural diagram of an apparatus for recording video according to Embodiment 4 of the present invention.
- FIG. 5 is a flowchart of a method for recording video according to Embodiment 5 of the present invention.
- FIG. 6 is a flowchart of an image output to an image encoding module according to Embodiment 5 of the present invention.
- FIG. 7 is a schematic structural diagram of an apparatus for recording video according to Embodiment 6 of the present invention.
- FIG. 8 is a comparison diagram of time intervals of original data, captured data, and written data according to Embodiment 6 of the present invention.
- FIG. 1 is a schematic diagram of a method for recording video according to an embodiment of the present invention. The method includes:
- Step S101 repeating according to the start instruction of the recorded video of the user and the interval time preset by the user: capturing the image data at intervals, and performing encoding processing on the image data captured at intervals;
- Step S102 Generate a video file according to the video file format set by the user according to the end instruction of the recorded video of the user.
- the image data may be an image taken by a camera, and may be a custom bitmap, an image on the screen, or other images such as Textures in the OpenGL drawing system.
- the method may further include: before encoding the image data captured by the interval, the method may further include:
- Special effect processing is performed on the image data that is captured at intervals, and the special effect processing includes one or more of the following: basic effect processing, filter effect, and special scene effect.
- the above method may further include:
- the audio data is encoded.
- the audio data may be, for example, audio data recorded by a microphone when the camera is photographed, or may be a custom audio file.
- the method before performing the encoding process on the audio data, the method further includes: performing special effect processing on the received audio data, where the special effect processing includes one or more of the following: special effect recording, mixing, changing, changing Speed change.
- the method for generating the video file includes: according to the end instruction of the user recording the video, the encoded image data, and the encoded audio data according to the video file format set by the user. , generate a video file.
- an operation interface can also be provided for the user, and the operation interface is set to set the interval time for recording the video, whether to enable the recording audio function, and the like.
- the image data that is captured by the interval is encoded, and the image data that is not captured is not stored, so as to save the storage space of the mobile terminal.
- the image data is captured by intervals, and the encoding process is performed, and then the image data after the encoding process is generated to generate a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- the embodiment of the present invention further provides a device for recording video.
- the device includes:
- the image information collecting module 201 is configured to capture image data according to an interval instruction of the user to record the video and an interval time preset by the user;
- the video encoding module 202 is configured to perform encoding processing on the image data that is captured by the image information collecting module 201;
- the video file generating module 203 is configured to generate the video file according to the video file format set by the user according to the image data processed by the video encoding module 202 according to the end instruction of the user recording the video.
- the source of the image data can be a camera, a custom bitmap, a screen, or Textures in an OpenGL drawing system.
- the device for recording video may further include a parameter setting module configured to set an interval time for recording the video.
- the parameter setting module can provide a user operation interface on the terminal, which is convenient for the user to set the interval between recording videos.
- the device for recording video may further include an image special effect processing module, configured to perform special effect processing on the image data that is captured by the image information collection module 201, and perform image processing after the special effect processing.
- the special effect processing includes one or more of the following: basic effect processing, filter effect, special scene effect.
- the user can record the sound
- the device for recording the video may further include:
- the audio collection module is configured to control to turn on the audio device, receive audio data, and encode the audio data.
- the audio collection module can be configured to receive or acquire audio data and perform encoding processing on the audio data.
- the device for recording video may further include: an audio special effect processing module, configured to perform special effect processing on the received audio data, where the special effect processing includes one or more of the following: special effect recording, mixing, and changing sound. , transposition, shifting.
- an audio special effect processing module configured to perform special effect processing on the received audio data, where the special effect processing includes one or more of the following: special effect recording, mixing, and changing sound. , transposition, shifting.
- the image information collecting module 201 is a camera of the mobile terminal.
- Video coding includes, but is not limited to, common video coding such as MPEG-4, H264, H263, VP8.
- Video file formats include, but are not limited to, mp4, 3gp, avi, rmvb, and the like.
- the video encoding module 202 repeats the process of capturing and encoding as follows: if the interval time is set to 1 second, the video encoding module 202 performs a capture on the preview image captured in the first second, The captured preview image is encoded, and then the preview image captured in the second second is captured again, and the captured second second preview image is encoded, so that the user receives the recorded video.
- the end instruction sends the image data captured and encoded at intervals to the video file generating module 203 to generate a video file.
- the video encoding module 202 does not store the uncaptured image data while capturing the preview image at intervals, so as to save storage space.
- the image data is captured by the video encoding module, and the encoding process is performed, and the video file generating module generates the video file by the encoded image data, thereby realizing the interval recording video of the mobile terminal.
- the image effect processing module performs special effects processing on the image data captured by the interval, and the audio recording module and the audio special effect processing module realize the functions of recording audio and processing the audio special effects while recording the video, thereby greatly improving the function. The user's interest and practicality in recording video using a mobile terminal.
- FIG. 3 is a method for recording video according to another embodiment of the present invention.
- the method includes:
- Step S301 The user performs parameter setting of the interval recording video
- the user sets the parameters related to the interval recording video through the operation interface.
- Related parameters include, but are not limited to, the interval between recording video, interval mode (manual interval mode or automatic interval mode), whether to enable image effects processing, whether to add audio, and how to source audio, whether to enable audio effects processing, etc.
- the automatic interval mode refers to capturing image data according to time intervals
- the manual interval mode refers to providing an operation interface for the user to click to trigger the captured image data
- Step S302 determining whether the audio needs to be added according to the parameter of the video recorded by the interval set by the user in step S301, if not, proceeding to step S303 to step S307, and if yes, performing step S313 to step S316, and simultaneously performing step S303 Go to step S307;
- Step S303 according to the start instruction of the user to record the video, the camera is turned on (ie, the image data acquisition module is turned on);
- the open camera includes a front camera and/or a rear camera, and supports multiple cameras simultaneously, and combines image data captured by multiple cameras according to certain rules.
- the image data data of the front camera is combined into an area of the background according to the image data of the rear camera as a background, and the user of the area can confirm by clicking. The user can also change this area by dragging.
- the image data data of the front camera can be used as a background, and the image data data of the rear camera is synthesized in an area of the background.
- Step S304 The image data is captured at intervals according to the interval mode and the interval time preset by the user in S301.
- an automatic interval mode is employed.
- the interval is set to 1 second. Capture real-time image data every 1S.
- the image data that is captured by the interval is encoded, and the image data that is not captured is not stored in any form, thereby saving the storage space of the terminal.
- Step S305 judging from the relevant parameters set by the user in step S301, whether it is necessary to perform image special effect processing, if yes, proceed to step S306, if not, proceed to step S307;
- Step S306 performing special effect processing on the image data captured by the interval
- Basic effect processing including noise reduction, brightness, chromaticity, etc.
- Filter effects including sketches, negatives, black and white, etc.
- Step S307 Perform encoding processing on the image data after the effect processing
- the captured image data and the encoding process of the above steps S303 to 307 are heavy according to the interval time. Repeated. As described above, the interval time is set to 1 second, the image data captured in the first second is captured once, the captured image data is encoded, and then the image data captured in the second second is captured again. And the image data of the captured second second is encoded, and so on, until the end instruction of the user's recorded video is received.
- Step S313 Turn on the audio device to receive audio data.
- the audio file is first decoded to obtain the original audio data.
- Step S314 judging according to the relevant parameters set by the user in step S301, whether it is necessary to perform special effect processing on the audio, if yes, proceed to step S315, if not, proceed to step S316;
- Step S315 performing special effect processing on the audio data.
- the special effect processing content includes but is not limited to one or more of the following processes: special effects recording, mixing, changing, changing, and shifting.
- Step S316 performing encoding processing on the audio data.
- Step S308 According to the end instruction of the video recorded by the user, the encoded data is generated according to the video file format set by the user.
- the encoded data video data and/or audio data is generated according to the video file format set by the user through S301, and the corresponding video file is generated.
- Video file formats include, but are not limited to, mp4, 3gp, avi, rmvb, and the like.
- the image data is captured by interval, and the encoding process is performed, and then the encoded image data is generated into a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- special effects processing is performed on image data captured at intervals, and Adding audio recording and special effects processing on audio while recording video expands the diversity and entertainment of video recorded on mobile devices, greatly improving the user experience.
- the embodiment of the present invention further provides a device for recording video.
- the device includes:
- the parameter setting module 401 is configured to set related parameters of the recorded video
- the related parameters include, but are not limited to, the interval of recording video, the interval mode (manual interval mode or automatic interval mode), whether to start image special effect processing, whether to add audio, and the source mode of audio, whether to enable audio special effect processing, and the like.
- the interval mode refers to capturing image data according to time intervals
- the manual interval mode refers to providing an operation interface for the user to click to trigger the captured image data.
- the image information collecting module 402 is configured to capture image data according to an interval instruction of the user to record the video and an interval time preset by the user;
- the image effect processing module 403 is configured to perform special effect processing on the image data that is captured by the image information collecting module 402 according to the special effect processing mode set by the parameter setting module 401;
- the image data may be an image taken by a camera, or a custom bitmap, or an image on the screen, or a Textures in an OpenGL drawing system.
- the special effect processing content includes but is not limited to one or more of the following: basic effect processing, filter effect, special scene effect.
- the video encoding module 404 is configured to perform encoding processing on the image data processed by the image special effect processing module 403;
- the image data that is captured by the interval is encoded, and the image data that is not captured is not stored.
- the audio collection module 405 is configured to control to open the audio device and receive audio data.
- the audio effect processing module 406 is configured to perform special effect processing on the audio data received by the audio collection module 405 according to the related parameters set by the parameter setting module 401;
- the special effect processing content includes but is not limited to one or more of the following: special effect recording, mixing, changing, changing, and shifting.
- the audio encoding module 407 is configured to perform encoding processing on the audio data processed by the special effects processing module 406;
- the video file generating module 408 is configured to: according to the end instruction of the user recording the video, the image data processed by the video encoding module 404 and the audio data encoded by the audio encoding module 407, according to the video set by the parameter setting module 401. File format, generating video files.
- the image data is captured by the interval, and the encoding process is performed, and then the encoded image data is generated into a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- FIG. 5 is a method for recording video according to another embodiment of the present invention.
- only video recording is performed separately and no special effect processing is performed as an example, while recording audio and/or performing special effects on the video.
- This can be implemented in combination with the foregoing embodiment, and will not be further described herein.
- the method flow in this example includes:
- Step S501 The user performs parameter setting of the interval recording video
- a video image PTS interval may be included
- Step S502 Open the camera according to the start instruction of the user to record the video, and capture the image data according to the set interval mode and the interval time;
- Step S503 performing general video image encoding processing on the captured image data
- the encoding process of the image data is performed by the image encoding module.
- the image encoding module may be checked for initialization. If not, the image encoding module is initialized, for example, including setting image resolution, screen update rate FPS, and encoding format.
- the general information in addition, also applies for a buffer for receiving image data (Buffer), the image encoding module receives the captured image data, and performs general video image encoding processing;
- Step S504 Write the encoded data and the PTS and other data required for packaging into a file to generate a video file.
- the fun of video recording can be improved by adding a PTS time stamp.
- a PTS time stamp For example, setting the PTS timestamp to 200 milliseconds per image interval results in a fast forward effect.
- the image is output to the image encoding module, and the flow is as shown in FIG. 6, including
- Step 601 using the OpenGl environment to draw data, including one of the following three types: screen data, OpenGL Textures, camera data;
- Step 602 the OpenGL environment is bound to a buffer in the image coding module and establishes a connection
- the data drawn in step 601 can be directly output to the Buffer.
- Step 603 using a Canvas environment to draw a custom bitmap
- Step 604 the Canvas environment is bound to a Buffer in the image coding module and establishes a connection;
- the custom bitmap drawn in step 603 can be directly stored in the Buffer.
- Step 605 A Buffer generated by the video encoding module is configured to receive related image data.
- the embodiment of the present invention further provides a device for recording video.
- the device includes:
- the parameter setting module 701 is configured to set related parameters of the recorded video
- the related parameters include, but are not limited to, interval of recording video, interval mode (manual interval mode or automatic interval mode), whether to start image special effect processing, whether to add audio, and whether the audio source mode, whether to enable audio special effect processing, display Timestamp PTS, etc.
- interval mode the automatic interval mode refers to capturing image data according to time intervals
- the manual interval mode refers to providing an operation interface for the user to click to trigger the captured image data.
- the image information collecting module 702 is configured to capture image data according to an interval instruction of the user to record the video and an interval time preset by the user;
- the image data captured by the image information collection module 702 may be, for example, image data (in this case, the image information acquisition module 702 is a camera), or screen data, or a custom bitmap, or an OpenGL texture.
- the image effect processing module 703 is configured to perform special effect processing on the image data that is captured by the image information collecting module 702 according to the special effect processing mode set by the parameter setting module 701;
- the special effect processing content includes but is not limited to one or more of the following: basic effect processing, filter effect, special scene effect.
- the video encoding module 704 is configured to perform encoding processing on the image data processed by the image special effect processing module 703;
- the image data that is captured by the interval is encoded, and the image data that is not captured is not stored.
- the audio collection module 705 is configured to receive audio data
- the audio data received by the audio collection module 705 can be, for example, data received by the microphone (the audio collection module 705 is a microphone at this time), or a custom audio file;
- the audio effect processing module 706 is configured to perform special effect processing on the audio data received by the audio collection module 705 according to the related parameters set by the parameter setting module 701;
- the special effect processing content includes but is not limited to one or more of the following: special effect recording, mixing, changing, changing, and shifting.
- the audio encoding module 707 is configured to perform encoding processing on the audio data processed by the special effects processing module 706;
- the video file generating module 708 is configured to: according to the end instruction of the user recording the video, the image data processed by the video encoding module 704 and the audio data encoded by the audio encoding module 707, according to the video set by the parameter setting module 701. File format, PTS timestamp, etc., to generate video files.
- the parameter setting module 701 and the image information collection module 702 process is as follows: the capture interval time is set to 4 seconds, and the video PTS time stamp is 500 milliseconds. Then figure The image acquisition module 702 performs a capture on the image data at the 0th second, and then captures the image data at the 4th second again, and so on, until an end instruction of the user's recorded video is received.
- the video file generating module 708 receives the data of the video encoding module 704, and writes the video file with the PTS time stamp of each picture set by the parameter setting module 701 for 500 milliseconds.
- the time interval of this process image is shown in FIG. 8.
- the interval recording video is realized by capturing image data at intervals and setting an image PTS time stamp interval in the video file.
- the image data is captured by the interval, and the encoding process is performed, and then the encoded image data is generated into a video file, thereby realizing the function of the mobile terminal to record video at intervals.
- Expanded mobile device recording by special effects processing of image data captured at intervals, as well as adding audio recordings and special effects processing while recording video, and packaging video files with set PTS timestamps when generating video files The diversity and entertainment of video greatly enhances the user experience.
- the method and device for recording video captureds image data at intervals and performs encoding processing, and then generates image files by encoding the processed image data, thereby realizing the interval recording video of the mobile terminal.
- the image data is captured by the interval, and the encoding process is performed, and then the encoded image data is generated into a video file, thereby realizing the function of the mobile terminal to record video at intervals.
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Human Computer Interaction (AREA)
- Television Signal Processing For Recording (AREA)
- Studio Devices (AREA)
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
- Signal Processing For Digital Recording And Reproducing (AREA)
Abstract
一种录制视频的方法和装置。所述方法流程包括:根据用户录制视频的开始指令和用户预设的间隔时间,重复进行:间隔抓取图像数据,对间隔抓取的图像数据进行编码处理;根据用户录制视频的结束指令,将编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
Description
本文涉及数据处理领域,尤其涉及一种录制视频的方法和装置。
随着通信技术和移动终端的发展,各种移动终端例如手机、智能手机、平板电脑已成为了人们工作和生活中不可或缺的一部分。随着移动终端日益普及,通过移动终端录制视频的功能给用户带来了极大地方便。
但是传统意义上的移动终端录制视频的功能,有诸多限制,例如:不能中间暂停,声音没有特殊效果,图像没有趣味性。视频后期制作虽然也可以制作达到特殊效果,但是专业性要求高,而且实时性不强。目前移动终端有在预览界面拍照生成GIF(Graphics Interchange Format,图像互换格式)的功能,但这种方式会生成临时的图片文件,由于GIF文件的限制,导致像数点精度会丢失,鉴于移动终端处理器的限制,也不太能接受大尺寸的图片和太多的帧数。
因此,有必要对相关技术的录制视频的方法和装置进行改进,使用户能够实现间隔录制视频。
发明内容
本发明实施例提供一种录制视频的方法和装置,以解决移动终端不能间隔录制视频的问题。
本发明实施例提供一种录制视频的方法,包括如下步骤:
根据用户录制视频的开始指令和用户预设的间隔时间,重复进行:间隔抓取图像数据,对间隔抓取的图像数据进行编码处理;
根据用户录制视频的结束指令,将编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
可选地,所述对间隔抓取的图像数据进行编码处理之前,所述方法还包括:对间隔抓取的图像数据进行特效处理,所述特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
可选地,所述间隔抓取图像数据并进行编码处理的同时,所述方法还包括:控制打开音频设备,接收音频数据;对所述音频数据进行编码处理。
可选地,所述对所述音频数据进行编码处理之前,所述方法还包括:对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
可选地,所述生成视频文件的方式为:根据用户录制视频的结束指令,将编码处理后的图像数据,以及编码处理后的音频数据,按照用户设定的视频文件格式,生成视频文件。
可选地,所述方法还包括:提供用户操作界面,设置为设定录制视频的间隔时间。
可选地,所述图像数据包括摄像数据,或自定义位图,或屏幕数据,或OpenGL绘制系统中的纹理。
可选地,将编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件,包括:将编码处理后的图像数据,按照用户设定的视频文件格式及设置的显示时间戳PTS,生成视频文件。
本发明实施例还提供了一种录制视频的装置,包括:
图像信息采集模块,设置为根据用户录制视频的开始指令和用户预设的间隔时间,间隔抓取图像数据;
视频编码模块,设置为对所述图像信息采集模块间隔抓取的图像数据进行编码处理;以及
视频文件生成模块,设置为根据用户录制视频的结束指令,将所述视频编码模块编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
可选地,所述装置还包括:参数设定模块,设置为设置录制视频的间隔
时间。
可选地,所述参数设定模块,还设置为设置生成视频文件时的显示时间戳PTS;
所述视频文件生成模块,是设置为将编码处理后的图像数据,按照所述参数设定模块设定的视频文件格式以及生成视频文件时的显示时间戳PTS,生成视频文件。
可选地,所述图像数据包括摄像数据,或自定义位图,或屏幕数据,或OpenGL绘制系统中的纹理。
可选地,所述装置还包括:图像特效处理模块,设置为对所述图像信息采集模块间隔抓取的图像数据进行特效处理,所述特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
可选地,所述装置还包括:音频采集和编码模块,设置为控制打开音频设备,接收音频数据,并对所述音频数据进行编码处理。
可选地,所述装置还包括:音频特效处理模块,设置为对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
本发明实施例还提供一种计算机可读存储介质,存储有程序指令,当该程序指令被执行时可实现上述方法。
本发明实施例提供的录制视频的方法和装置,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据打包生成视频文件,实现了移动终端间隔录制视频的功能。另外,通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,添加音频录制以及对音频进行特效处理,以及在图像数据打包视频文件时修改显示时间戳(Presentation Time Stamp,PTS),扩展了移动设备录制视频的多样性、娱乐性,极大的提高了用户体验。
附图概述
图1为本发明实施例1提供的一种录制视频的方法流程图;
图2为本发明实施例2提供的一种录制视频的装置结构示意图;
图3为本发明实施例3提供的一种录制视频的方法流程图;
图4为本发明实施例4提供的一种录制视频的装置结构示意图;
图5为本发明实施例5提供的一种录制视频的方法流程图;
图6为本发明实施例5图像输出到图像编码模块的流程图;
图7为本发明实施例6提供的一种录制视频的装置结构示意图;
图8为本发明实施例6原始数据、抓取数据、写入数据的时间间隔对比图。
需要说明的是,在不冲突的情况下,本发明实施例以及实施例中的特征可以相互任意组合。
实施例1
请参阅图1,为本发明实施例提供的一种录制视频的方法,该方法流程包括:
步骤S101:根据用户录制视频的开始指令和用户预设的间隔时间,重复进行:间隔抓取图像数据,对间隔抓取的图像数据进行编码处理;
步骤S102:根据用户录制视频的结束指令,将编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
所述图像数据可以是摄像机拍摄的图像,此外还可以是自定义位图、屏幕上的图像,或者是OpenGL绘制系统中的纹理(Textures)等其他图像。
为了提高用户拍摄的趣味性,在对间隔抓取的图像数据进行编码处理之前,上述方法还可包括:
对间隔抓取的图像数据进行特效处理,该特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
为了在录制视频的同时,用户能够录制声音,间隔抓取图像数据并进行
编码处理的同时,上述方法还可包括:
控制打开音频设备,接收音频数据;
对所述音频数据进行编码处理。
所述音频数据例如可以是摄像机拍摄时麦克风收录的音频数据,此外也可以是自定义音频文件。
可选地,对所述音频数据进行编码处理之前,还可包括:对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
在增加了录制音频的功能基础上,该生成视频文件的方式包括:根据用户录制视频的结束指令,将编码处理后的图像数据,以及编码处理后的音频数据,按照用户设定的视频文件格式,生成视频文件。
为了用户操作起来更为方便实用,还可以提供用户一个操作界面,该操作界面设置为设定录制视频的间隔时间,是否开启录制音频功能等。
区别于相关技术,本实施例在实际应用中,在对间隔抓取的图像数据进行编码处理的同时,对未抓取的图像数据,不进行存储,以便节省移动终端的存储空间。
在本实施例提供的录制视频的方法中,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,录制音频以及对音频进行特效处理,大大提高了移动终端录制视频的趣味性和实用性。
实施例2
在上述方法的基础上,本发明实施例还提供了一种录制视频的装置,请继续参阅图2,该装置包括:
图像信息采集模块201,设置为根据用户录制视频的开始指令和用户预设的间隔时间,间隔抓取图像数据;
视频编码模块202,设置为对图像信息采集模块201间隔抓取的图像数据进行编码处理;以及
视频文件生成模块203,设置为根据用户录制视频的结束指令,将视频编码模块202编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
图像数据的来源可以为摄像机、自定义位图、屏幕、或者OpenGL绘制系统中的Textures。
可选地,该录制视频的装置还可以包括一个参数设定模块,设置为设置录制视频的间隔时间。实际应用中,该参数设定模块可以在终端上提供一个用户操作界面,方便用户设定录制视频的间隔时间。
可选地,为了提高用户拍摄的趣味性,该录制视频的装置还可以包括图像特效处理模块,设置为对图像信息采集模块201间隔抓取的图像数据进行特效处理,进行特效处理后的图像数据再发送给视频编码模块202进行编码处理,所述特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
为了在录制视频的同时,用户能够录制声音,该录制视频的装置还可以包括:
音频采集模块,设置为控制打开音频设备,接收音频数据,并对所述音频数据进行编码处理。
当音频数据包括自定义音频文件时,音频采集模块可设置为接收或获取音频数据,并对所述音频数据进行编码处理。
可选地,该录制视频的装置还可以包括:音频特效处理模块,设置为对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
在实际应用中,该图像信息采集模块201,为移动终端的摄像头。
视频编码包括但不仅限于MPEG-4,H264,H263,VP8等常见视频编码。
视频文件格式包括但不仅限于mp4,3gp,avi,rmvb等。
需要举例说明的是,视频编码模块202重复进行抓取和编码处理这一过程为:假设间隔时间设置为1秒,那么视频编码模块202对处于第1秒拍摄的预览图像进行一次抓取,对抓取的预览图像进行编码处理,然后再对处于第2秒拍摄的预览图像进行再一次抓取,并对抓取的第2秒的预览图像进行编码处理,如此往复,直到收到用户录制视频的结束指令,将间隔抓取并编码的图像数据,发送给视频文件生成模块203,生成视频文件。
另外,为了节省终端设备的存储空间,视频编码模块202在间隔抓取预览图片的同时,对未抓取的图像数据,不进行存储,以便节省存储空间。
本实施例提供的录制视频的装置中,通过视频编码模块间隔抓取图像数据,并进行编码处理,通过视频文件生成模块将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过图像特效处理模块对间隔抓取的图像数据进行特效处理,以及通过音频采集模块和音频特效处理模块在录制视频的同时,实现录制音频以及对音频特效处理的功能,如此一来,大大提高了用户使用移动终端录制视频的趣味性和实用性。
实施例3
请继续参阅图3,为本发明另一实施例提供的录制视频的方法,该方法流程包括:
步骤S301:用户进行间隔录制视频的参数设定;
用户通过操作界面,对间隔录制视频的相关参数进行设定。相关参数包括但不仅限于:录制视频的间隔时间,间隔方式(手动间隔模式或者自动间隔模式),是否启动图像特效处理,是否添加音频,以及音频的来源方式、是否启动音频特效处理等。
对于间隔方式,自动间隔模式指按照时间间隔抓取图像数据,手动间隔模式指提供操作界面以便用户点击触发抓取图像数据。
步骤S302:根据步骤S301中用户设定的间隔录制视频的参数,判断是否需要添加音频,如果否,则进行步骤S303至步骤S307,如果是,则进行步骤S313至步骤S316,并同时执行步骤S303至步骤S307;
当用户录制视频的时候需要同时录制音频时,通过相关参数的设定,在录制视频的同时,开启录制音频的功能。
步骤S303:根据用户录制视频的开始指令,打开摄像头(即开启图像数据采集模块);
开启的摄像头包括前置摄像头和/或后置摄像头,并且支持同时开启多个摄像头,按照一定的规则合成多个摄像头抓取的图像数据。
例如,在同时调用两个摄像头情况下,按照后置摄像头的图像数据数据作为背景,将前置摄像头的图像数据数据合成在背景的一块区域,该区域用户可以通过点击来确认。用户也可以通过拖动来改变此区域。同理前置摄像头的图像数据数据可以作为背景,后置摄像头的图像数据数据合成在背景的一块区域中。
步骤S304:根据S301中用户预设的间隔方式和间隔时间,间隔抓取图像数据;
本实施例中,采用自动间隔模式。间隔时间设定为1秒。每隔1S抓取实时的图像数据。
为了节省移动终端的存储空间,在对间隔抓取的图像数据进行编码处理的同时,对未抓取的图像数据,不进行任何形式的存储,从而节省终端的存储空间。
步骤S305:从步骤S301中用户设定的相关参数判断,是否需要进行图像特效处理,如果是,则进行步骤S306,如果否,则进行步骤S307;
步骤S306:对间隔抓取的图像数据进行特效处理;
特效处理内容包括但不仅限于以下几种处理及其组合方式:
基本效果处理,包含减噪、亮度、色度等;
滤镜效果,包含素描、负片、黑白等;
特殊场景效果,包含常见天气、星空等。
步骤S307:对特效处理后的图像数据进行编码处理;
以上步骤S303至步骤307的抓取图像数据和编码处理是按照间隔时间重
复进行的。如上所述,间隔时间设置为1秒,对第1秒拍摄的图像数据进行一次抓取,对抓取的图像数据进行编码处理后,然后再对第2秒拍摄的图像数据进行再一次抓取,并对抓取的第2秒的图像数据进行编码处理,如此往复,直到收到用户录制视频的结束指令。
以下是当录制视频同时添加音频时,与录制图像同时进行的录制音频的过程:
步骤S313:打开音频设备,接收音频数据;
音频的来源方式主要有两种方式:麦克风或者自定义音频文件。
当音频来源为自定义音频文件时,先对音频文件进行解码,得到原始的音频数据。
步骤S314:根据步骤S301中用户设定的相关参数判断,是否需要对音频进行特效处理,如果是,则进行步骤S315,如果否,则进行步骤S316;
步骤S315:对所述音频数据进行特效处理;
所述特效处理内容包括但不限于以下处理的一种或多种:特效录音、混音、变声、变调、变速。
步骤S316:对所述音频数据进行编码处理;
以上步骤S313至S316的录制音频的流程和步骤S303至步骤S307的录制图像的流程同时进行,不分先后顺序。
步骤S308:根据用户录制视频的结束指令,将编码处理后的数据,按照用户设定的视频文件格式,生成视频文件。
当接收到用户录制视频的结束指令时,将编码处理后的数据:视频数据和/或者音频数据,按照用户通过S301设定的视频文件格式,生成相应的视频文件。
视频文件格式包括但不仅限于mp4,3gp,avi,rmvb等。
通过本实施例提供的录制视频的方法,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。另外,通过对间隔抓取的图像数据进行特效处理,以及
在录制视频的同时,添加音频录制以及对音频进行特效处理,扩展了移动设备录制视频的多样性、娱乐性,极大的提高了用户体验。
实施例4
在上述方法的基础上,本发明实施例还提供了一种录制视频的装置,请继续参阅图4,该装置包括:
参数设定模块401,设置为设置录制视频的相关参数;
所述相关参数包括但不仅限于:录制视频的间隔时间,间隔方式(手动间隔模式或者自动间隔模式),是否启动图像特效处理,是否添加音频,以及音频的来源方式、是否启动音频特效处理等。对于间隔方式,自动间隔模式指按照时间间隔抓取图像数据,手动间隔模式指提供操作界面以便用户点击触发抓取图像数据。
图像信息采集模块402,设置为根据用户录制视频的开始指令和用户预设的间隔时间,间隔抓取图像数据;
图像特效处理模块403,设置为根据参数设定模块401设定的特效处理方式,对图像信息采集模块402间隔抓取的图像数据进行特效处理;
所述图像数据可以是摄像头拍摄的图像,或者自定义位图,或屏幕上的图像,或者是OpenGL绘制系统中的纹理(Textures)。
所述特效处理内容包括但不限于以下一种或多种:基本效果处理、滤镜效果、特殊场景效果。
视频编码模块404,设置为对图像特效处理模块403特效处理后的图像数据进行编码处理;
为了节省移动终端的存储空间,在对间隔抓取的图像数据进行编码处理的同时,对未抓取的图像数据,不进行存储。
音频采集模块405,设置为控制打开音频设备,接收音频数据;
音频特效处理模块406,设置为根据参数设定模块401设定的相关参数,对音频采集模块405接收的音频数据进行特效处理;
所述特效处理内容包括但不限于以下一种或多种:特效录音、混音、变声、变调、变速。
音频编码模块407,设置为对音效特效处理模块406特效处理后的音频数据进行编码处理;
视频文件生成模块408,设置为根据用户录制视频的结束指令,将视频编码模块404编码处理后的图像数据,和音频编码模块407编码处理后的音频数据,按照参数设定模块401设定的视频文件格式,生成视频文件。
本实施例中,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,添加音频录制以及对音频进行特效处理,扩展了移动设备录制视频的多样性、娱乐性,极大的提高了用户体验。
实施例5
请参阅图5,为本发明另一实施例提供的录制视频的方法,在本例中仅以单独录制视频且不进行特效处理为例进行说明,同时录制音频和/或对视频进行特效处理时可结合前述实施例方案实现,本文不再赘述。本例中方法流程包括:
步骤S501:用户进行间隔录制视频的参数设定;
除了前述实施例中所述的参数外,还可以包括视频图像PTS间隔时间;
步骤S502:根据用户录制视频的开始指令,打开摄像头,根据设置的间隔方式和间隔时间,间隔抓取图像数据;
步骤S503:对抓取到的图像数据进行通用的视频图像编码处理;
对图像数据的编码处理由图像编码模块完成,在编码处理前,可先检查图像编码模块是否初始化,如果未初始化,则初始化图像编码模块,例如包括设置图像分辨率、画面更新率FPS、编码格式等通用信息,此外还同时申请一个用于接收图像数据的缓存(Buffer),图像编码模块接收到抓取到的图像数据后,进行通用的视频图像编码处理;
步骤S504:将编码处理后的数据和PTS以及其他打包需要的数据写入文件,生成视频文件。
本实施例方法,通过增加设置PTS时间戳,可以提高视频录制的趣味性。例如,设置PTS时间戳为每张图像间隔200毫秒,这样就形成快进的效果。
在本实施例中,图像输出到图像编码模块,流程如图6所示,包括
步骤601,使用OpenGl环境来绘制数据,包括以下三种之一:屏幕数据、OpenGL Textures、摄像头数据;
步骤602,OpenGL环境,与图像编码模块中的缓存(Buffer)绑定并建立连接;
绑定后,步骤601中绘制的数据可以直接输出到Buffer中。
步骤603,使用Canvas环境来绘制自定义位图;
步骤604,Canvas环境,与图像编码模块中的Buffer绑定并建立连接;
绑定后,步骤603中绘制的自定义位图就可以直接存到Buffer中。
步骤605,视频编码模块生成的Buffer,用来接收相关图像数据。
通过上述流程可见,不同的图像数据都可以传输到视频编码模块的Buffer中。
实施例6
在上述方法的基础上,本发明实施例还提供了一种录制视频的装置,请继续参阅图7,该装置包括:
参数设定模块701,设置为设置录制视频的相关参数;
所述相关参数包括但不仅限于:录制视频的间隔时间,间隔方式(手动间隔模式或者自动间隔模式),是否启动图像特效处理,是否添加音频,以及音频的来源方式、是否启动音频特效处理,显示时间戳PTS等。对于间隔方式,自动间隔模式指按照时间间隔抓取图像数据,手动间隔模式指提供操作界面以便用户点击触发抓取图像数据。
图像信息采集模块702,设置为根据用户录制视频的开始指令和用户预设的间隔时间,间隔抓取图像数据;
图像信息采集模块702抓取的图像数据例如可以是摄像数据(此时图像信息采集模块702即为摄像头),或者是屏幕数据,或者是自定义位图,或者是OpenGL纹理。
图像特效处理模块703,设置为根据参数设定模块701设定的特效处理方式,对图像信息采集模块702间隔抓取的图像数据进行特效处理;
所述特效处理内容包括但不限于以下一种或多种:基本效果处理、滤镜效果、特殊场景效果。
视频编码模块704,设置为对图像特效处理模块703特效处理后的图像数据进行编码处理;
为了节省移动终端的存储空间,在对间隔抓取的图像数据进行编码处理的同时,对未抓取的图像数据,不进行存储。
音频采集模块705,设置为接收音频数据;
音频采集模块705接收的音频数据例如可以是麦克风接收的数据(此时音频采集模块705即为麦克风),或者自定义音频文件;
音频特效处理模块706,设置为根据参数设定模块701设定的相关参数,对音频采集模块705接收的音频数据进行特效处理;
所述特效处理内容包括但不限于以下一种或多种:特效录音、混音、变声、变调、变速。
音频编码模块707,设置为对音效特效处理模块706特效处理后的音频数据进行编码处理;
视频文件生成模块708,设置为根据用户录制视频的结束指令,将视频编码模块704编码处理后的图像数据,和音频编码模块707编码处理后的音频数据,按照参数设定模块701设定的视频文件格式、PTS时间戳等,生成视频文件。
需要举例说明的是,参数设定模块701和图像信息采集模块702处理过程为:假设抓取间隔时间设置为4秒,视频PTS时间戳为500毫秒。那么图
像信息采集模块702对处于第0秒的图像数据进行一次抓取,然后再对处于第4秒的图像数据进行再一次抓取,如此往复,直到收到用户录制视频的结束指令。视频文件生成模块708接收到视频编码模块704的数据,以参数设定模块701设置的每张图片PTS时间戳为500毫秒写入视频文件,这一过程图像的时间间隔表现为图8所示。通过间隔抓取图像数据和设置视频文件中的图像PTS时间戳间隔,实现间隔录制视频。
本实施例中,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,添加音频录制并对音频进行特效处理,以及在生成视频文件时以设置的PTS时间戳打包视频文件,扩展了移动设备录制视频的多样性、娱乐性,极大的提高了用户体验。
需要说明的是,前述方法实施例中的技术特征在装置实施例中均对应适用,这里不再重述。
综上所述,本发明实施例提供的录制视频的方法和装置,通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,添加音频录制以及对音频进行特效处理,扩展了移动设备录制视频的多样性、娱乐性,极大的提高了用户体验。
本领域普通技术人员可以理解上述方法中的全部或部分步骤可通过程序来指令相关硬件完成,上述程序可以存储于计算机可读存储介质中,如只读存储器、磁盘或光盘等。可选地,上述实施例的全部或部分步骤也可以使用一个或多个集成电路来实现。相应地,上述实施例中的各模块/单元可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。本发明实施例不限制于任何特定形式的硬件和软件的结合。
通过间隔抓取图像数据,并进行编码处理,然后将编码处理后的图像数据生成视频文件,实现了移动终端间隔录制视频的功能。通过对间隔抓取的图像数据进行特效处理,以及在录制视频的同时,添加音频录制以及对音频进行特效处理,扩展了移动终端录制视频的多样性、娱乐性,极大的提高了用户体验。
Claims (16)
- 一种录制视频的方法,包括如下步骤:根据用户录制视频的开始指令和用户预设的间隔时间,重复进行:间隔抓取图像数据,对间隔抓取的图像数据进行编码处理;根据用户录制视频的结束指令,将编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
- 根据权利要求1所述的方法,所述对间隔抓取的图像数据进行编码处理之前,所述方法还包括:对间隔抓取的图像数据进行特效处理,所述特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
- 根据权利要求1所述的方法,所述间隔抓取图像数据并进行编码处理的同时,所述方法还包括:控制打开音频设备,接收音频数据;对所述音频数据进行编码处理。
- 根据权利要求3所述的方法,所述对所述音频数据进行编码处理之前,所述方法还包括:对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
- 根据权利要求3或4所述的方法,其中,所述生成视频文件的方式包括:根据用户录制视频的结束指令,将编码处理后的图像数据,以及编码处理后的音频数据,按照用户设定的视频文件格式,生成视频文件。
- 根据权利要求1至4任一项所述的方法,所述方法还包括:提供用户操作界面,设置为设定录制视频的间隔时间。
- 根据权利要求1所述的方法,其中,所述图像数据包括摄像数据,或自定义位图,或屏幕数据,或OpenGL绘制系统中的纹理。
- 根据权利要求1所述的方法,其中,将编码处理后的图像数据,按照 用户设定的视频文件格式,生成视频文件,包括:将编码处理后的图像数据,按照用户设定的视频文件格式及设置的显示时间戳PTS,生成视频文件。
- 一种录制视频的装置,包括:图像信息采集模块,设置为根据用户录制视频的开始指令和用户预设的间隔时间,间隔抓取图像数据;视频编码模块,设置为对所述图像信息采集模块间隔抓取的图像数据进行编码处理;以及视频文件生成模块,设置为根据用户录制视频的结束指令,将所述视频编码模块编码处理后的图像数据,按照用户设定的视频文件格式,生成视频文件。
- 根据权利要求9所述的装置,所述装置还包括:参数设定模块,设置为设置录制视频的间隔时间。
- 根据权利要求10所述的装置,其中,所述参数设定模块,还设置为设置生成视频文件时的显示时间戳PTS;所述视频文件生成模块,是设置为将编码处理后的图像数据,按照所述参数设定模块设定的视频文件格式以及生成视频文件时的显示时间戳PTS,生成视频文件。
- 根据权利要求9所述的装置,其中,所述图像数据包括摄像数据,或自定义位图,或屏幕数据,或OpenGL绘制系统中的纹理。
- 根据权利要求9所述的装置,所述装置还包括:图像特效处理模块,设置为对所述图像信息采集模块间隔抓取的图像数据进行特效处理,所述特效处理包括以下内容的一种或多种:基本效果处理、滤镜效果、特殊场景效果。
- 根据权利要求9所述的装置,所述装置还包括:音频采集和编码模块,设置为控制打开音频设备,接收音频数据,并对所述音频数据进行编码处理。
- 根据权利要求14所述的装置,所述装置还包括:音频特效处理模块,设置为对接收的音频数据进行特效处理,所述特效处理包括以下内容的一种或多种:特效录音、混音、变声、变调、变速。
- 一种计算机可读存储介质,存储有程序指令,当该程序指令被执行时可实现权利要求1-8任一项所述的方法。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP15812532.8A EP3151548B1 (en) | 2014-06-27 | 2015-06-15 | Video recording method and device |
US15/322,296 US10021302B2 (en) | 2014-06-27 | 2015-06-15 | Video recording method and device |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410301103.1A CN104023192B (zh) | 2014-06-27 | 2014-06-27 | 一种录制视频的方法和装置 |
CN201410301103.1 | 2014-06-27 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2015196937A1 true WO2015196937A1 (zh) | 2015-12-30 |
Family
ID=51439738
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2015/081457 WO2015196937A1 (zh) | 2014-06-27 | 2015-06-15 | 一种录制视频的方法和装置 |
Country Status (4)
Country | Link |
---|---|
US (1) | US10021302B2 (zh) |
EP (1) | EP3151548B1 (zh) |
CN (1) | CN104023192B (zh) |
WO (1) | WO2015196937A1 (zh) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11610391B2 (en) | 2019-12-30 | 2023-03-21 | Industrial Technology Research Institute | Cross-domain image comparison method and system using semantic segmentation |
Families Citing this family (24)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104023192B (zh) | 2014-06-27 | 2016-04-13 | 努比亚技术有限公司 | 一种录制视频的方法和装置 |
CN104202661A (zh) * | 2014-09-15 | 2014-12-10 | 厦门美图之家科技有限公司 | 一种自动将照片转换为视频的方法 |
CN104301649B (zh) * | 2014-10-29 | 2019-08-16 | 上海斐讯数据通信技术有限公司 | 一种视频拍摄存储、播放的方法和系统 |
CN104967801B (zh) * | 2015-02-04 | 2019-09-17 | 腾讯科技(深圳)有限公司 | 一种视频数据处理方法和装置 |
TWI592021B (zh) | 2015-02-04 | 2017-07-11 | 騰訊科技(深圳)有限公司 | 生成視頻的方法、裝置及終端 |
CN104836961A (zh) * | 2015-05-13 | 2015-08-12 | 广州市久邦数码科技有限公司 | 一种基于安卓系统的实时滤镜拍摄的实现方法及其系统 |
CN104917994A (zh) * | 2015-06-02 | 2015-09-16 | 烽火通信科技股份有限公司 | 音视频通话系统及方法 |
CN105657310B (zh) * | 2015-12-31 | 2018-06-01 | 南京维睛视空信息科技有限公司 | 一种手机屏幕实时录取方法 |
EP3249652B1 (en) * | 2016-05-25 | 2020-07-15 | Axis AB | Method and apparatus for playing back recorded video |
CN105979138A (zh) * | 2016-05-30 | 2016-09-28 | 努比亚技术有限公司 | 一种视频拍摄装置、方法和移动终端 |
CN106780363B (zh) * | 2016-11-21 | 2019-07-23 | 北京金山安全软件有限公司 | 一种图片处理方法、装置及电子设备 |
CN107172377A (zh) * | 2017-06-30 | 2017-09-15 | 福州瑞芯微电子股份有限公司 | 一种视频通话的数据处理方法和装置 |
CN107613357B (zh) * | 2017-09-13 | 2020-05-19 | 广州酷狗计算机科技有限公司 | 声画同步优化方法、装置及可读存储介质 |
CN107770596A (zh) * | 2017-09-25 | 2018-03-06 | 北京达佳互联信息技术有限公司 | 一种特效同步方法、装置及移动终端 |
CN108234479A (zh) * | 2017-12-29 | 2018-06-29 | 北京百度网讯科技有限公司 | 用于处理信息的方法和装置 |
CN109600660B (zh) * | 2018-08-01 | 2020-07-24 | 北京微播视界科技有限公司 | 用于录制视频的方法和装置 |
BR112020024621A2 (pt) | 2018-08-01 | 2021-03-02 | Beijing Microlive Vision Technology Co., Ltd. | método e dispositivo de gravação de vídeo |
CN108965757B (zh) * | 2018-08-02 | 2021-04-06 | 广州酷狗计算机科技有限公司 | 视频录制方法、装置、终端及存储介质 |
CN109255990A (zh) * | 2018-09-30 | 2019-01-22 | 杭州乔智科技有限公司 | 一种基于ar增强现实的教学系统 |
CN111464757A (zh) * | 2019-01-21 | 2020-07-28 | 西安诺瓦电子科技有限公司 | 视频处理方法、装置和系统 |
CN110300261B (zh) * | 2019-06-27 | 2021-11-12 | 努比亚技术有限公司 | 视频预览方法、可穿戴设备及计算机可读存储介质 |
CN111935395A (zh) * | 2020-06-29 | 2020-11-13 | 联想(北京)有限公司 | 一种视频文件生成方法及电子设备 |
CN112423095A (zh) * | 2020-11-02 | 2021-02-26 | 广州博冠信息科技有限公司 | 游戏视频录制方法、装置、电子设备和存储介质 |
CN112601041A (zh) * | 2020-12-11 | 2021-04-02 | 北京首汽智行科技有限公司 | 一种视频录制方法及系统 |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101370097A (zh) * | 2008-09-05 | 2009-02-18 | 深圳创维数字技术股份有限公司 | 数字电视机顶盒、电视视频画面截取装置及方法 |
CN102025930A (zh) * | 2009-09-15 | 2011-04-20 | 深圳市九洲电器有限公司 | 一种数字电视接收设备及其截图方法 |
US20120155833A1 (en) * | 2010-12-20 | 2012-06-21 | General Instrument Corporation | Method of Processing a Sequence of Coded Video Frames |
CN103391414A (zh) * | 2013-07-24 | 2013-11-13 | 杭州趣维科技有限公司 | 一种应用于手机平台的视频处理装置及处理方法 |
CN104023192A (zh) * | 2014-06-27 | 2014-09-03 | 深圳市中兴移动通信有限公司 | 一种录制视频的方法和装置 |
Family Cites Families (13)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6369835B1 (en) * | 1999-05-18 | 2002-04-09 | Microsoft Corporation | Method and system for generating a movie file from a slide show presentation |
US8069466B2 (en) * | 2005-08-04 | 2011-11-29 | Nds Limited | Advanced digital TV system |
US8199220B2 (en) * | 2006-12-06 | 2012-06-12 | Samsung Electronics Co., Ltd. | Method and apparatus for automatic image management |
US20080301169A1 (en) * | 2007-05-29 | 2008-12-04 | Tadanori Hagihara | Electronic apparatus of playing and editing multimedia data |
CN101621552B (zh) * | 2008-07-04 | 2013-10-09 | 深圳富泰宏精密工业有限公司 | 便携式电子装置 |
CN101510313A (zh) * | 2009-03-13 | 2009-08-19 | 腾讯科技(深圳)有限公司 | 一种gif生成方法、系统及媒体播放器 |
CN101931775A (zh) * | 2010-09-01 | 2010-12-29 | 中兴通讯股份有限公司 | 一种录像方法及装置 |
US9117483B2 (en) * | 2011-06-03 | 2015-08-25 | Michael Edward Zaletel | Method and apparatus for dynamically recording, editing and combining multiple live video clips and still photographs into a finished composition |
WO2014072844A1 (en) * | 2012-11-09 | 2014-05-15 | Idealounge (Pty) Ltd | Audiovisual recordings |
CN103873916A (zh) * | 2012-12-13 | 2014-06-18 | 深圳市快播科技有限公司 | 一种影片缩略图的处理方法及系统、视频播放器 |
TWI537813B (zh) * | 2013-01-25 | 2016-06-11 | 宏達國際電子股份有限公司 | 電子裝置及其照相機切換方法 |
KR102023179B1 (ko) * | 2013-02-21 | 2019-09-20 | 삼성전자주식회사 | 듀얼 카메라를 포함하는 전자장치에서 듀얼 리코딩 촬영을 위한 방법 및 장치 |
US9807316B2 (en) * | 2014-09-04 | 2017-10-31 | Htc Corporation | Method for image segmentation |
-
2014
- 2014-06-27 CN CN201410301103.1A patent/CN104023192B/zh active Active
-
2015
- 2015-06-15 US US15/322,296 patent/US10021302B2/en active Active
- 2015-06-15 EP EP15812532.8A patent/EP3151548B1/en active Active
- 2015-06-15 WO PCT/CN2015/081457 patent/WO2015196937A1/zh active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101370097A (zh) * | 2008-09-05 | 2009-02-18 | 深圳创维数字技术股份有限公司 | 数字电视机顶盒、电视视频画面截取装置及方法 |
CN102025930A (zh) * | 2009-09-15 | 2011-04-20 | 深圳市九洲电器有限公司 | 一种数字电视接收设备及其截图方法 |
US20120155833A1 (en) * | 2010-12-20 | 2012-06-21 | General Instrument Corporation | Method of Processing a Sequence of Coded Video Frames |
CN103391414A (zh) * | 2013-07-24 | 2013-11-13 | 杭州趣维科技有限公司 | 一种应用于手机平台的视频处理装置及处理方法 |
CN104023192A (zh) * | 2014-06-27 | 2014-09-03 | 深圳市中兴移动通信有限公司 | 一种录制视频的方法和装置 |
Non-Patent Citations (1)
Title |
---|
See also references of EP3151548A4 * |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11610391B2 (en) | 2019-12-30 | 2023-03-21 | Industrial Technology Research Institute | Cross-domain image comparison method and system using semantic segmentation |
TWI797420B (zh) * | 2019-12-30 | 2023-04-01 | 財團法人工業技術研究院 | 跨領域之畫面比較方法與系統 |
Also Published As
Publication number | Publication date |
---|---|
US20170134654A1 (en) | 2017-05-11 |
EP3151548A4 (en) | 2017-05-31 |
CN104023192B (zh) | 2016-04-13 |
EP3151548A1 (en) | 2017-04-05 |
US10021302B2 (en) | 2018-07-10 |
EP3151548B1 (en) | 2020-04-08 |
CN104023192A (zh) | 2014-09-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2015196937A1 (zh) | 一种录制视频的方法和装置 | |
JP7139515B2 (ja) | 動画撮像方法、動画撮像装置、電子機器、およびコンピューター読取可能な記憶媒体 | |
US11367465B2 (en) | Real time video special effects system and method | |
JP5851625B2 (ja) | 立体視映像処理装置、立体視映像処理方法及び立体視映像処理用プログラム | |
CN112804459A (zh) | 基于虚拟摄像头的图像展示方法、装置、存储介质及电子设备 | |
KR100726258B1 (ko) | 휴대단말의 사진파일 및 음성파일을 이용한 영상물 제작방법 | |
CN112235585B (zh) | 一种虚拟场景的直播方法、装置及系统 | |
TWI735552B (zh) | 將沈浸式視訊格式化用於傳統及沈浸式顯像元件之方法、裝置及串流 | |
US20230185518A1 (en) | Video playing method and device | |
WO2018076939A1 (zh) | 视频文件的处理方法和装置 | |
CN112019907A (zh) | 直播画面分流方法、计算机设备及可读存储介质 | |
CN112004041B (zh) | 视频录制方法、装置、终端及存储介质 | |
WO2023160234A1 (zh) | 转场动效生成方法、电子设备和存储介质 | |
CN106303288A (zh) | 合成演唱视频的方法、装置及系统 | |
US20150036020A1 (en) | Method for sharing original photos along with final processed image | |
WO2022166371A1 (zh) | 多景录像方法、装置及电子设备 | |
US20130044258A1 (en) | Method for presenting video content on a hand-held electronic device | |
CN112019906A (zh) | 直播方法、计算机设备及可读存储介质 | |
CN115002335B (zh) | 视频处理方法、装置、电子设备和计算机可读存储介质 | |
JP4321751B2 (ja) | 描画処理装置、描画処理方法および描画処理プログラム、並びにそれらを備えた電子会議システム | |
JP2015023317A5 (ja) | 画像管理装置及び画像管理方法、プログラム、並びに記憶媒体 | |
JP5238849B2 (ja) | 電子機器、電子機器の制御方法及び電子機器の制御プログラム | |
KR20080017747A (ko) | 동영상 편집 기능을 구비한 동영상 촬영 장치 및 방법 | |
US20170287521A1 (en) | Methods, circuits, devices, systems and associated computer executable code for composing composite content | |
JP5927515B2 (ja) | 画像編集方法、画像編集システム、及び画像編集プログラム |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 15812532 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
REEP | Request for entry into the european phase |
Ref document number: 2015812532 Country of ref document: EP |
|
WWE | Wipo information: entry into national phase |
Ref document number: 15322296 Country of ref document: US Ref document number: 2015812532 Country of ref document: EP |