CN109640114A - Video compiles transcoding compression method, device, equipment and computer readable storage medium - Google Patents

Video compiles transcoding compression method, device, equipment and computer readable storage medium Download PDF

Info

Publication number
CN109640114A
CN109640114A CN201811520587.3A CN201811520587A CN109640114A CN 109640114 A CN109640114 A CN 109640114A CN 201811520587 A CN201811520587 A CN 201811520587A CN 109640114 A CN109640114 A CN 109640114A
Authority
CN
China
Prior art keywords
video
video source
transcoding
frame image
coding
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.)
Pending
Application number
CN201811520587.3A
Other languages
Chinese (zh)
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.)
Shenzhen Onething Technology Co Ltd
Original Assignee
Shenzhen Onething Technology 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 Shenzhen Onething Technology Co Ltd filed Critical Shenzhen Onething Technology Co Ltd
Priority to CN201811520587.3A priority Critical patent/CN109640114A/en
Publication of CN109640114A publication Critical patent/CN109640114A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs
    • H04N21/2343Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs involving reformatting operations of video signals for distribution or compliance with end-user requests or end-user device requirements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display

Abstract

The invention discloses a kind of videos to compile transcoding compression method, comprising: receives after the video source for compiling transcoding, carries out hard coded to every frame image in video source, obtain the log of record encoded information;After all images frame in video source completes above-mentioned hard coded, the log according to record encoded information carries out secondary coding to corresponding frame image, obtains the es stream of the secondary coding result of the frame image;After all images frame in video source completes above-mentioned secondary coding, the es stream of the secondary coding result of every frame image in video source is packaged, after encapsulation, is exported as the video after video source transcoding.The process of first coding is transferred in non-cpu package and carries out hard coded by the present invention, to reduce the load pressure of CPU.The invention also discloses a kind of device based on the above method, equipment and computer readable storage mediums.

Description

Video compiles transcoding compression method, device, equipment and computer readable storage medium
Technical field
The present invention relates to technical field of video compression, compile transcoding compression method more particularly to a kind of video.The present invention is also It is related to a kind of video and compiles transcoding compression set, equipment and computer readable storage medium.
Background technique
HEVC (High Efficiency Video Coding, high efficiency Video coding)/it is H.265 a kind of current new one H.264/AVC, the video compression standard in generation, compression efficiency are higher by about 50% than most widely used at present.It is led in video on demand Domain can encode to generate the higher video program of quality using 2pass, that is, the mode that encodes twice generates height The compression video of quality.Wherein, the encoded information that the 2nd coding will be generated when being encoded using first time, these encoded information packets Every frame even information of each macro block are included, text file is saved as with certain format, is used for subsequent 2nd coding input. The process specifically includes that
Carry out the coding of 1pass to every frame image using CPU first, encoding target is the frame for generating HEVC format, and raw At corresponding 1pass log;Then 2pass coding is carried out using CPU according to the log of 1pass, finally to raw after 2pass coding At es stream be packaged, export transcoding after new video.
By above procedure it is found that process 1pass is encoded using CPU, i.e., by the way of soft coding, which pair The occupancy of CPU and memory is all relatively more, causes biggish burden to CPU.
Therefore, it is those skilled in the art that the low video of load pressure for how providing a kind of CPU, which compiles transcoding compression scheme, The current problem to be solved of member.
Summary of the invention
The object of the present invention is to provide a kind of videos to compile transcoding compression method, and the process of the first coding is transferred to non-CPU Hard coded is carried out in component, to reduce the load pressure of CPU;It is a further object of the present invention to provide one kind to be based on the above method Device, equipment and computer readable storage medium.
In order to solve the above technical problems, the present invention provides a kind of videos to compile transcoding compression method, comprising:
It receives after the video source for compiling transcoding, hard coded is carried out to every frame image in the video source, obtain record and compile The log of code information;
Log pair after all images frame in the video source completes above-mentioned hard coded, according to the record encoded information Corresponding frame image carries out secondary coding, obtains the elementary stream es stream of the secondary coding result of the frame image;
After all images frame in the video source completes above-mentioned secondary coding, to every frame image in the video source The es stream of secondary coding result is packaged, and after encapsulation, is exported as the video after the video source transcoding.
Preferably, every frame image in the video source carries out hard coded, obtains the log of record encoded information Process specifically:
Es stream is decapsulated and decoded to every frame image in the video source, obtains yuv image;
Hard coded is carried out to every frame yuv image, obtains the es flow data of HEVC format;
The es flow data for decoding the HEVC format obtains the log of the record encoded information.
Preferably, the log according to the record encoded information carries out soft coding to corresponding frame image, obtains The secondary coding result of the frame image es stream process include:
It is decapsulated and is decoded es stream again to every frame image in the video source, obtain the yuv image;
Log according to the record encoded information carries out global Data Rate Distribution to frame yuv image, after being assigned, according to According to global code rate allocation result and quantized value best relative formula, the optimized amount of each macro block on frame yuv image is calculated Change value;Entropy coding is carried out according to the optimization quantized value, obtains the es stream of the secondary coding result of the frame image.
Preferably, the mode of the hard coded specifically: according to the hardware compression for supporting the synchronous QSV function of high-speed video The hard coded that circuit carries out.
Preferably, the mode of the secondary coding specifically: the soft coding carried out according to CPU.
In order to solve the above technical problems, the present invention also provides a kind of videos to compile transcoding compression set, comprising:
First encoding module carries out every frame image in the video source for receiving after the video source for compiling transcoding Hard coded obtains the log of record encoded information;After all images frame in the video source completes above-mentioned hard coded, triggering two Secondary coding module;
The secondary coding module, for carrying out two to corresponding frame image according to the log of the record encoded information Secondary coding obtains the elementary stream es stream of the secondary coding result of the frame image;All images frame in the video source is completed After above-mentioned secondary coding, output module is triggered;
The output module, the es stream for the secondary coding result to every frame image in the video source seal Dress, after encapsulation, is exported as the video after the video source transcoding.
In order to solve the above technical problems, the present invention also provides a kind of videos to compile transcoding compression device, described device includes Memory and processor, the video that be stored on the memory to run on the processor compile transcoding condensing routine, institute It states when video volume transcoding condensing routine is executed by the processor and realizes following method:
It receives after the video source for compiling transcoding, hard coded is carried out to every frame image in the video source, obtain record and compile The log of code information;
Log pair after all images frame in the video source completes above-mentioned hard coded, according to the record encoded information Corresponding frame image carries out secondary coding, obtains the elementary stream es stream of the secondary coding result of the frame image;
After all images frame in the video source completes above-mentioned secondary coding, to every frame image in the video source The es stream of secondary coding result is packaged, and after encapsulation, is exported as the video after the video source transcoding.
Preferably, the video is compiled when transcoding condensing routine is executed by the processor and is implemented in the video source Every frame image carry out hard coded, obtain record encoded information log process are as follows:
Es stream is decapsulated and decoded to every frame image in the video source, obtains yuv image;
Hard coded is carried out to every frame yuv image, obtains the es flow data of HEVC format;
The es flow data for decoding the HEVC format obtains the log of the record encoded information.
Preferably, the equipment is the node for forming CDN network or block chain network.
In order to solve the above technical problems, the present invention also provides a kind of computer readable storage mediums, which is characterized in that institute It states and is stored with video volume transcoding condensing routine on computer readable storage medium, the video compiles transcoding condensing routine can be by one Or multiple processors execute, to realize that the video as described in any of the above item compiles transcoding compression method.
The present invention provides a kind of videos to compile transcoding compression method, is receiving after the video source for compiling transcoding, first to view Every frame image in frequency source carries out hard coded, obtains the log of record encoded information, later the day according to the record encoded information Will carries out secondary coding, obtains final coding result, and export after being packaged to final coding result, completes the volume of video source Transcoding compression process.As it can be seen that, when encode for the first time to every frame image in video source, not being using CPU in the present invention Carry out soft coding, but by the way of hard coded, hard coded refer to using except non-CPU video card or chip carry out Coding, this coding mode by first coding operation separated from CPU come out so that entirely compile transcoding process in, CPU and The occupancy of memory reduces, to reduce the load pressure of CPU.The present invention also provides a kind of dresses based on the above method It sets, equipment and computer readable storage medium.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to institute in the prior art and embodiment Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the invention Example, for those of ordinary skill in the art, without creative efforts, can also obtain according to these attached drawings Obtain other attached drawings.
Fig. 1 is the flow chart for the process that a kind of video provided by the invention compiles transcoding compression method;
Fig. 2 is the flow chart for the process that a kind of video comprising deterministic process provided by the invention compiles transcoding compression method;
Fig. 3 is the process for the process that another video comprising deterministic process provided by the invention compiles transcoding compression method Figure;
Fig. 4 is the flow chart for the specific embodiment that a kind of video provided by the invention compiles transcoding compression method;
Fig. 5 is the structural schematic diagram that a kind of video provided by the invention compiles transcoding compression set.
Specific embodiment
Core of the invention is to provide a kind of video volume transcoding compression method, and the process of the first coding is transferred to non-CPU Hard coded is carried out in component, to reduce the load pressure of CPU;Another core of the invention is to provide a kind of based on the above method Device, equipment and computer readable storage medium.
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is A part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art Every other embodiment obtained without making creative work, shall fall within the protection scope of the present invention.
The description and claims of this application and term " first ", " second ", " third ", " in above-mentioned attached drawing The (if present)s such as four " are to be used to distinguish similar objects, without being used to describe a particular order or precedence order.It should manage The data that solution uses in this way are interchangeable under appropriate circumstances, so that the embodiments described herein can be in addition to illustrating herein Or the sequence other than the content of description is implemented.In addition, term " includes " and " having " and their any deformation, it is intended that Cover it is non-exclusive include, for example, containing the process, method, system, product or equipment of a series of steps or units need not limit In step or unit those of is clearly listed, but may include be not clearly listed or for these process, methods, produce The other step or units of product or equipment inherently.
It should be noted that the description for being related to " first ", " second " etc. in the present invention is used for description purposes only, and cannot It is interpreted as its relative importance of indication or suggestion or implicitly indicates the quantity of indicated technical characteristic.Define as a result, " the One ", the feature of " second " can explicitly or implicitly include at least one of the features.In addition, the skill between each embodiment Art scheme can be combined with each other, but must be based on can be realized by those of ordinary skill in the art, when technical solution Will be understood that the combination of this technical solution is not present in conjunction with there is conflicting or cannot achieve when, also not the present invention claims Protection scope within.
The present invention provides a kind of videos to compile transcoding compression method, shown in Figure 1, and Fig. 1 is one kind provided by the invention Video compiles the flow chart of the process of transcoding compression method;This method comprises:
Step s1: receiving after the video source for compiling transcoding, carries out hard coded to every frame image in video source, is recorded The log of encoded information;
Hard coded refers to the coding using video card or chip progress except non-CPU, and the present invention passes through for the first time When coding, by the way of hard coded, by first time, the operation of coding is separated from CPU, to reduce the load pressure of CPU Power.
Step s2: the log pair after all images frame in video source completes above-mentioned hard coded, according to record encoded information Corresponding frame image carries out secondary coding, obtains the basic code stream es stream of the secondary coding result of the frame image;
It is understood that it is preferred that the executing subject of secondary coding is different from the executing subject of hard coded;Mesh of the invention Be CPU caused by being encoded by CPU and content in order to solve at present during carrying out secondary coding to video The excessive situation of pressure.Therefore, it is separated from CPU by the operation of first time coding, is transferred to and it is executed by hard coded device Afterwards, if secondary coding is also encoded with first time using if identical executing subject, the resource that will lead to the executing subject is accounted for With more, therefore there is also the problems in script CPU.Therefore, in order to avoid encode twice by same executing subject execute and The high problem of the caused executing subject resource occupation, the present invention in enable for the first time coding (i.e. above-mentioned hard coded) when execution master Body is different from executing subject when secondary coding.
Step s3: after all images frame in video source completes above-mentioned secondary coding, to every frame image in video source The es stream of secondary coding result is packaged, and after encapsulation, is exported as the video after video source transcoding.
Wherein, es stream is also elementary stream, is the continuous bit stream comprising video, audio or data.Wherein, in video source When image data originally receives, and with the form presence of es stream.
The present invention provides a kind of videos to compile transcoding compression method, is receiving after the video source for compiling transcoding, first to view Every frame image in frequency source carries out hard coded, obtains the log of record encoded information, later the day according to the record encoded information Will carries out secondary coding, obtains final coding result, and export after being packaged to final coding result, completes the volume of video source Transcoding compression process.As it can be seen that, when encode for the first time to every frame image in video source, not being using CPU in the present invention Soft coding is carried out, but by the way of hard coded, the operation of the first coding has been separated from CPU by this coding mode Come, so that entirely compiling in transcoding process, the occupancy of CPU and memory is reduced, to reduce the load pressure of CPU.
Wherein, the process that whether all images frame in step s2 in determining video source completes above-mentioned hard coded may is that Before or after carrying out hard coded to every frame image, judge the picture frame for not carrying out hard coded whether is saved in video source, if It is then to enter secondary coding process, otherwise, the picture frame that selection does not carry out hard coded repeats this step operation;
The process whether all images frame in step s3 in determining video source completes above-mentioned secondary coding can be, right Before or after every frame image carries out secondary coding, judge the picture frame for not carrying out secondary coding whether is saved in video source, if It is then to enter encapsulation process, otherwise, the picture frame that selection does not carry out secondary coding repeats this step operation.
Shown in Figure 2, Fig. 2 is the mistake that a kind of video comprising deterministic process provided by the invention compiles transcoding compression method The flow chart of journey;If being carried out after every frame image carries out hard coded and after carrying out secondary coding to every frame image above-mentioned Judgement, then process of the invention includes:
Step s111: the video source of transcoding to be compiled is received;
Step s1121: carrying out hard coded to the frame image for not carrying out hard coded in video source, obtains record coding letter The log of breath;
Step s1131: judge the picture frame for not carrying out hard coded whether is saved in video source, if so, return step S1121, if it is not, entering step s1211;
Step s1211: the log according to the corresponding record encoded information of a frame image for not carrying out secondary coding is to the frame Image carries out secondary coding, obtains the basic code stream es stream of the secondary coding result of the frame image;
Step s1221: judge the picture frame for not carrying out secondary coding whether is saved in video source, if so, return step S1211, if it is not, entering step s13;
Step s13: after all images frame in video source completes above-mentioned secondary coding, to every frame image in video source The es stream of secondary coding result is packaged, and after encapsulation, is exported as the video after video source transcoding.
Shown in Figure 3, Fig. 3 is that another video comprising deterministic process provided by the invention compiles transcoding compression method The flow chart of process;If being carried out before every frame image carries out hard coded and before carrying out secondary coding to every frame image Judgement is stated, then process of the invention includes:
Step s111: the video source of transcoding to be compiled is received;
Step s1122: judge the picture frame for not carrying out hard coded whether is saved in video source, if so, entering step S1132, if it is not, entering step s1212;
Step s1132: carrying out hard coded to the frame image for not carrying out hard coded in video source, obtains record coding letter The log of breath;Return step s1122;
Step s1212: judge the picture frame for not carrying out secondary coding whether is saved in video source, if so, entering step S1222, if it is not, entering step s13;
Step s1222: the log according to the corresponding record encoded information of a frame image for not carrying out secondary coding is to the frame Image carries out secondary coding, obtains the basic code stream es stream of the secondary coding result of the frame image;Return to return step s1212;
Step s13: after all images frame in video source completes above-mentioned secondary coding, to every frame image in video source The es stream of secondary coding result is packaged, and after encapsulation, is exported as the video after video source transcoding.
The above is only two kinds of specific embodiments, in step s2 and step s3, specifically before being encoded still Carry out above-mentioned judgement operation later, the present invention is not especially limited.
In an advantageous embodiment, shown in Figure 4, Fig. 4 is that a kind of video provided by the invention compiles transcoding compression side The flow chart of the specific embodiment of method;The process of step s1 specifically:
Step s11: decapsulating every frame image in video source and decodes es stream, obtains yuv image;
It is understood that every frame image needs in video source are transmitted with encapsulation mode, therefore, originally receive Afterwards, it needs to decapsulate image and can just obtain image data.Also, the image data in video source is the form flowed with es It transmits, the data content in es stream can not be read under the es manifold formula, it is therefore desirable to which decoding es stream first obtains yuv image. Yuv is a kind of color coding mode, and y refers to luminance signal, and u, v refer to carrier chrominance signal.
Step s12: hard coded is carried out to every frame yuv image, obtains the es flow data of HEVC format;
HEVC is high efficiency Video coding, in the present embodiment, compiles transcoding mode using the video based on HEVC, therefore It needs the encoding target setting of hard coded (encoding for the first time) are as follows: coding obtains the frame of HEVC format, wherein HEVC format The form that is flowed with es of frame exist.
Step s13: the es flow data of decoding HEVC format obtains the log of record encoded information.
Due to that can not read the data content in es stream under es manifold formula, therefore, it is necessary to decode the es fluxion of HEVC format According to, after obtaining decoded information, these decoded informations include encoded information, such as present encoding a frame image frame level information and These encoded informations are converted to the log of text formatting by macro-block level information etc..
It is understood that in current first time cataloged procedure, after the completion of encoding first time, after coding can be generated The log of es stream and record encoded information can also seal the es stream after coding later before entering second of coding Dress.And in the present embodiment, before entering second of coding, do not need to be packaged the es stream of HEVC format, because after Continuous second of coding does not use the es stream of HEVC format, but has only used the log of record encoded information, therefore reduce The step of encapsulation operation is conciliate in encapsulation, can reduce cataloged procedure improves code efficiency.
Further, shown in Figure 4, the process of step s2 includes:
Step s21: decapsulating every frame image in video source again and decodes es stream, obtains yuv image;
I.e. during encoding for second, it is also required to that the original image frame in video source is decapsulated and solved first Code es stream.The reason of yuv image decoded when why not encoded here using first time directly is because of yuv image Data volume it is larger, if when saving after first time encodes to wait second of coding if use, yuv image during this Very big memory space can be occupied, therefore, influences the progress of normal encoding.Therefore the present invention does not save solution when encoding first time The yuv image that code obtains, but when encoding for second, it obtains again.
Step s22: the log according to record encoded information carries out global Data Rate Distribution to frame yuv image, is assigned Afterwards, according to global code rate allocation result and quantized value best relative formula, the excellent of each macro block on frame yuv image is calculated Change quantized value;Entropy coding is carried out according to optimization quantized value, obtains the es stream of the secondary coding result of the frame image.
Cataloged procedure includes the processes such as prediction-transformation-code rate control-quantization-entropy coding.It is encoded for the first time in the present invention Process be currently it is identical, i.e., experience the above process after generate actual code stream and record encoded information log.But second Rate control process in secondary cataloged procedure is modified in common cataloged procedure, is no longer the volume according to previous frame The code rate of code adjusts the quantized value of the every macro block of every frame when exporting fructufy, but includes according to what is generated in encoding for the first time before The log of encoded information to carry out frame yuv image global Data Rate Distribution, and by a quantized value best relative formula, calculates Meet the optimal quantized value of each macro block out.Wherein, quantized value best relative formula here is a similar regression curve Formula, in order to obtain preferably globally optimal solution as quantized value.
It is understood that being carried out since first time coding is transferred in the component different from encoding for the second time by the present invention Mode, therefore the mode handled compared to whole cataloged procedures by CPU, the invention enables the parts in second of cataloged procedure Operation can be carried out when first time encoding unfinished by different components, as operated in step s21 to accelerate parallel The entire processing speed for compiling transcoding process, improves and compiles transcoding efficiency.
In a preferred embodiment, the mode of above-mentioned hard coded specifically: according to the hard of the synchronous QSV function of support high-speed video The hard coded that part coding-decoding circuit (Quick Sync Video, high-speed video are synchronous) carries out.Wherein, QSV is Intel HD aobvious Block the newest video code conversion function that has, i.e. QSV have the function of to realize encoded for the first time in the present invention needed for transcoding, and And the interface for receiving yuv image is provided on QSV.On HD video card of new generation, Intel strengthens the general-purpose computations of core video card Ability increases the support to video code conversion, shortens the consumption of conversion time.Intel Quick Sync Video technology passes through Processor hardware decodes to carry out operation, makes Video Quality Metric lighter.
In addition, hardware compression circuit can be video card GPU, dedicated DSP (Digital Signal here Processing, Digital Signal Processing), FPGA (Field-Programmable Gate Array, field-programmable gate array Column), ASIC (Application Specific Integrated Circuits, specific integrated circuit) chip etc. and its periphery Circuit composition, certainly, this is not limited by the present invention.
Preferably, in order to keep higher volume transcoded quality, in the present embodiment, by the decoding in abovementioned steps s13 The operation setting of es stream is the soft decoding carried out according to CPU, sets the mode of secondary coding to the soft volume carried out according to CPU Code.
The present invention also provides a kind of videos to compile transcoding compression set, shown in Figure 5, and Fig. 5 is provided by the invention one Kind video compiles the structural schematic diagram of transcoding compression set.The device includes:
First encoding module compiles every frame image in video source for receiving after the video source for compiling transcoding firmly Code obtains the log of record encoded information;After all images frame in video source completes above-mentioned hard coded, secondary coding mould is triggered Block;
Secondary coding module, for carrying out secondary coding to corresponding frame image according to the log of record encoded information, Obtain the es stream of the secondary coding result of the frame image;After all images frame in video source completes above-mentioned secondary coding, triggering Output module;
Output module, the es stream for the secondary coding result to every frame image in video source are packaged, have encapsulated Bi Hou is exported as the video after video source transcoding.
It may or may not be physically separated with upper module, it can it is in one place, or can also To be distributed on multiple network modules.Some or all of the modules therein can be selected to realize this reality according to the actual needs Apply the purpose of a scheme.
The present invention also provides a kind of videos to compile transcoding compression device, and device includes memory and processor, on memory The video that be stored with to run on a processor compiles transcoding condensing routine, and video is compiled real when transcoding condensing routine is executed by processor Existing following method:
It receives after the video source for compiling transcoding, hard coded is carried out to every frame image in video source, obtain record coding letter The log of breath;
After all images frame in video source completes above-mentioned hard coded, the log according to record encoded information is to corresponding one Frame image carries out secondary coding, obtains the es stream of the secondary coding result of the frame image;
After all images frame in video source completes above-mentioned secondary coding, to the secondary coding of every frame image in video source As a result es stream is packaged, and after encapsulation, is exported as the video after video source transcoding.
Preferably, video is compiled when transcoding condensing routine is executed by processor and is implemented to every frame figure in video source As carrying out hard coded, the process of the log of record encoded information is obtained are as follows:
Elementary stream es stream is decapsulated and decoded to every frame image in video source, obtains yuv image;
Hard coded is carried out to every frame yuv image, obtains the es flow data of HEVC format;
The es flow data for decoding HEVC format obtains the log of record encoded information.
It can also include memory, processor and bus that the video, which compiles transcoding compression device,.
Wherein, memory includes at least a type of readable storage medium storing program for executing, and the readable storage medium storing program for executing includes flash memory, hard Disk, multimedia card, card-type memory (for example, SD or DX memory etc.), magnetic storage, disk, CD etc..Memory is one It can be the internal storage unit that video compiles transcoding compression device in a little embodiments, such as the video compiles the hard of transcoding compression device Disk.Memory is also possible to the External memory equipment that video compiles transcoding compression device in further embodiments, such as video is compiled The plug-in type hard disk being equipped on transcoding compression device, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, flash card (Flash Card) etc..Further, memory can also both include that video is compiled The internal storage unit of transcoding compression device also includes External memory equipment.Memory can be not only used for storage and be installed on video The application software and Various types of data of transcoding compression device are compiled, such as video compiles the code etc. of transcoding condensing routine, can be also used for Temporarily store the data that has exported or will export.
Processor can be central processing unit (Central Processing Unit, CPU), control in some embodiments Device, microcontroller, microprocessor or other data processing chips processed, program code or processing for being stored in run memory Data, such as execute video and compile transcoding condensing routine etc..
The bus can be Peripheral Component Interconnect standard (peripheral for connecting processor and memory Component interconnect, abbreviation PCI) bus or expanding the industrial standard structure (extended industry Standard architecture, abbreviation EISA) bus etc..The bus can be divided into address bus, data/address bus, control always Line etc..
Further, it can also include network interface that video, which compiles transcoding compression device, and network interface is external defeated for receiving Video after the video source and output transcoding that enter.Network interface optionally may include wireline interface and/or wireless interface (such as WI-FI interface, blue tooth interface etc.), commonly used in establishing communication connection between the equipment and other electronic equipments.
Optionally, which can also include user interface, and user interface may include display (Display), input Unit such as keyboard (Keyboard), optional user interface can also include standard wireline interface and wireless interface.It is optional Ground, in some embodiments, display can be light-emitting diode display, liquid crystal display, touch-control liquid crystal display and OLED (Organic Light-Emitting Diode, Organic Light Emitting Diode) touches device etc..Wherein, display can also be appropriate Referred to as display screen or display unit compile the information handled in transcoding compression device and for showing visually for being shown in video The user interface of change.
In the present embodiment, video, which compiles transcoding compression device, can be PC (Personal Computer, PC), It is also possible to the terminal devices such as smart phone, tablet computer, palm PC, portable computer.Preferably, which is composition The node of CDN network or block chain network.
The present invention also provides a kind of computer readable storage mediums, which is characterized in that on computer readable storage medium It is stored with video and compiles transcoding condensing routine, video is compiled transcoding condensing routine and can be executed by one or more processor, to realize As the video of any of the above item compiles transcoding compression method.
If the module that video compiles in transcoding compression set is realized in the form of software function module and as independent production Product when selling or using, can store in a computer readable storage medium.Based on this understanding, the skill of the application Substantially all or part of the part that contributes to existing technology or the technical solution can be with soft in other words for art scheme The form of part product embodies, which is stored in a storage medium, including some instructions are to make It obtains a computer equipment (can be personal computer, server or the network equipment etc.) and executes each embodiment of the application The all or part of the steps of the method.And storage medium above-mentioned include: USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic or disk etc. it is various It can store the medium of program code.
The present invention also provides a kind of computer program products, which is characterized in that including computer instruction, when it is being calculated When being run on machine, allows computer to execute video described in above-mentioned any of the above item and compile transcoding compression method.
The computer program product includes one or more computer instructions.Load and execute on computers the meter When calculation machine program instruction, entirely or partly generate according to process or function described in the embodiment of the present invention.The computer can To be general purpose computer, special purpose computer, computer network or other programmable devices.The computer instruction can be deposited Storage in a computer-readable storage medium, or from a computer readable storage medium to another computer readable storage medium Transmission, for example, the computer instruction can pass through wired (example from a web-site, computer, server or data center Such as coaxial cable, optical fiber, Digital Subscriber Line (DSL)) or wireless (such as infrared, wireless, microwave) mode to another website Website, computer, server or data center are transmitted.The computer readable storage medium can be computer and can deposit Any usable medium of storage either includes that the data storages such as one or more usable mediums integrated server, data center are set It is standby.The usable medium can be magnetic medium, (for example, floppy disk, hard disk, tape), optical medium (for example, DVD) or partly lead Body medium (such as solid state hard disk Solid State Disk, SSD) etc..
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description, The specific work process of equipment and computer readable storage medium, can refer to corresponding processes in the foregoing method embodiment, This is repeated no more.
In several embodiments provided herein, it should be understood that disclosed device, device and method can be with It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the module It divides, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple module or components It can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown or The mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, the indirect coupling of device or module It closes or communicates to connect, can be electrical property, mechanical or other forms.
In the above-described embodiments, can come wholly or partly by software, hardware, firmware or any combination thereof real It is existing.When implemented in software, it can entirely or partly realize in the form of a computer program product.
It should also be noted that, in the present specification, relational terms such as first and second and the like be used merely to by One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning Covering non-exclusive inclusion, so that the process, method, article or equipment for including a series of elements not only includes that A little elements, but also including other elements that are not explicitly listed, or further include for this process, method, article or The intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence "including a ...", is not arranged Except there is also other identical elements in the process, method, article or apparatus that includes the element.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills Art field, is included within the scope of the present invention.

Claims (10)

1. a kind of video compiles transcoding compression method characterized by comprising
It receives after the video source for compiling transcoding, hard coded is carried out to every frame image in the video source, obtain record coding letter The log of breath;
After all images frame in the video source completes above-mentioned hard coded, the log according to the record encoded information is to correspondence A frame image carry out secondary coding, obtain the secondary coding result of the frame image elementary stream es stream;
After all images frame in the video source completes above-mentioned secondary coding, to the secondary of every frame image in the video source The es stream of coding result is packaged, and after encapsulation, is exported as the video after the video source transcoding.
2. video according to claim 1 compiles transcoding compression method, which is characterized in that described to every in the video source Frame image carries out hard coded, obtains the process of the log of record encoded information specifically:
Elementary stream es stream is decapsulated and decoded to every frame image in the video source, obtains yuv image;
Hard coded is carried out to every frame yuv image, obtains the es flow data of high efficiency Video coding HEVC format;
The es flow data for decoding the HEVC format obtains the log of the record encoded information.
3. video according to claim 1 compiles transcoding compression method, which is characterized in that described encode according to the record is believed The log of breath carries out soft coding to corresponding frame image, obtains the process packet of the es stream of the secondary coding result of the frame image It includes:
It is decapsulated and is decoded es stream again to every frame image in the video source, obtain the yuv image;
Log according to the record encoded information carries out global Data Rate Distribution to frame yuv image, after being assigned, according to complete The optimization quantized value of each macro block on frame yuv image is calculated in office code rate allocation result and quantized value best relative formula; Entropy coding is carried out according to the optimization quantized value, obtains the es stream of the secondary coding result of the frame image.
4. video according to claim 1-3 compiles transcoding compression method, which is characterized in that the side of the hard coded Formula specifically: according to the hard coded for supporting the hardware compression circuit of the synchronous QSV function of high-speed video to carry out.
5. video according to claim 4 compiles transcoding compression method, which is characterized in that the mode of the secondary coding is specific Are as follows: the soft coding carried out according to CPU.
6. a kind of video compiles transcoding compression set characterized by comprising
First encoding module compiles every frame image in the video source for receiving after the video source for compiling transcoding firmly Code obtains the log of record encoded information;After all images frame in the video source completes above-mentioned hard coded, secondary volume is triggered Code module;
The secondary coding module, for carrying out secondary volume to corresponding frame image according to the log of the record encoded information Code obtains the elementary stream es stream of the secondary coding result of the frame image;All images frame in the video source is completed above-mentioned After secondary coding, output module is triggered;
The output module, the es stream for the secondary coding result to every frame image in the video source are packaged, envelope After dress, exported as the video after the video source transcoding.
7. a kind of video compiles transcoding compression device, which is characterized in that described device includes memory and processor, the memory On be stored with the video that can run on the processor and compile transcoding condensing routine, it is described that the video compiles transcoding condensing routine Processor realizes following method when executing:
It receives after the video source for compiling transcoding, hard coded is carried out to every frame image in the video source, obtain record coding letter The log of breath;
After all images frame in the video source completes above-mentioned hard coded, the log according to the record encoded information is to correspondence A frame image carry out secondary coding, obtain the secondary coding result of the frame image es stream;
After all images frame in the video source completes above-mentioned secondary coding, to the secondary of every frame image in the video source The es stream of coding result is packaged, and after encapsulation, is exported as the video after the video source transcoding.
8. video as claimed in claim 7 compiles transcoding compression device, which is characterized in that the video compiles transcoding condensing routine quilt Specific implementation carries out hard coded to every frame image in the video source when processor executes, and obtains record encoded information The process of log are as follows:
Elementary stream es stream is decapsulated and decoded to every frame image in the video source, obtains yuv image;
Hard coded is carried out to every frame yuv image, obtains the es flow data of HEVC format;
The es flow data for decoding the HEVC format obtains the log of the record encoded information.
9. video according to claim 7 compiles transcoding compression device, which is characterized in that the equipment is composition CDN network Or the node of block chain network.
10. a kind of computer readable storage medium, which is characterized in that be stored with video volume on the computer readable storage medium Transcoding condensing routine, the video are compiled transcoding condensing routine and can be executed by one or more processor, to realize as right is wanted Video described in asking any one of 1 to 5 compiles transcoding compression method.
CN201811520587.3A 2018-12-12 2018-12-12 Video compiles transcoding compression method, device, equipment and computer readable storage medium Pending CN109640114A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811520587.3A CN109640114A (en) 2018-12-12 2018-12-12 Video compiles transcoding compression method, device, equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811520587.3A CN109640114A (en) 2018-12-12 2018-12-12 Video compiles transcoding compression method, device, equipment and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN109640114A true CN109640114A (en) 2019-04-16

Family

ID=66073189

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811520587.3A Pending CN109640114A (en) 2018-12-12 2018-12-12 Video compiles transcoding compression method, device, equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN109640114A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111654706A (en) * 2020-05-06 2020-09-11 济南浪潮高新科技投资发展有限公司 Video compression method, device, equipment and medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140161172A1 (en) * 2012-12-11 2014-06-12 Jason N. Wang Software hardware hybrid video encoder
CN104768063A (en) * 2015-04-07 2015-07-08 天脉聚源(北京)教育科技有限公司 Video coding method and device
CN105376568A (en) * 2015-12-22 2016-03-02 广州通达汽车电气股份有限公司 Optimization method of ABR video coding code rate control
CN106210884A (en) * 2016-07-13 2016-12-07 腾讯科技(深圳)有限公司 The code-transferring method of video file and device
CN107852495A (en) * 2015-09-21 2018-03-27 谷歌有限责任公司 Low time delay video code twice
CN108810545A (en) * 2018-07-04 2018-11-13 中南大学 Method for video encoding, device, computer-readable medium and electronic equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140161172A1 (en) * 2012-12-11 2014-06-12 Jason N. Wang Software hardware hybrid video encoder
CN104768063A (en) * 2015-04-07 2015-07-08 天脉聚源(北京)教育科技有限公司 Video coding method and device
CN107852495A (en) * 2015-09-21 2018-03-27 谷歌有限责任公司 Low time delay video code twice
CN105376568A (en) * 2015-12-22 2016-03-02 广州通达汽车电气股份有限公司 Optimization method of ABR video coding code rate control
CN106210884A (en) * 2016-07-13 2016-12-07 腾讯科技(深圳)有限公司 The code-transferring method of video file and device
CN108810545A (en) * 2018-07-04 2018-11-13 中南大学 Method for video encoding, device, computer-readable medium and electronic equipment

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111654706A (en) * 2020-05-06 2020-09-11 济南浪潮高新科技投资发展有限公司 Video compression method, device, equipment and medium
CN111654706B (en) * 2020-05-06 2022-06-28 山东浪潮科学研究院有限公司 Video compression method, device, equipment and medium

Similar Documents

Publication Publication Date Title
CN103609117B (en) Code and decode the method and device of image
CN105163127A (en) Video analysis method and device
CN108881916A (en) The video optimized processing method and processing device of remote desktop
CN103281539A (en) Method, device and terminal for image encoding and decoding processing
CN104023235A (en) Indexed color history in image coding
CN104159150A (en) Cloud terminal, cloud server, media data stream playing system and method
CN102074257A (en) Software and hardware-decoding general multi-media playing equipment and playing method thereof
CN106385592A (en) Image compression method and device
CN106253981A (en) A kind of data transmission method and the first electronic equipment
CN105430408A (en) H264 hardware decoding system based on three platforms including Intel, AMD and Nvidia
CN109889894A (en) Media file coding/decoding method, device and storage medium
CN104834649B (en) It can realize the smart machine and multiple-equipment team working method of more equipment collaborations
US10931968B2 (en) Method and apparatus for encoding or decoding video content including regions having looping videos of different loop lengths
CN105144726A (en) Custom data indicating nominal range of samples of media content
CN109640114A (en) Video compiles transcoding compression method, device, equipment and computer readable storage medium
CN103686195A (en) Video information processing method and video information processing equipment
CN109495742B (en) Video frame coding method, device and equipment
US20210233572A1 (en) Video processing method, electronic device, and storage medium
CN109076211A (en) Renewal step by step in case of motion
CN102123275A (en) Video component data information acquiring and extracting method
CN109379591A (en) Picture code-transferring method, electronic device and computer readable storage medium
CN105791819B (en) The decompression method and device of a kind of frame compression method of image, image
CN109451313A (en) A kind of method for video coding, system and electronic equipment and storage medium
CN102685542A (en) High definition multimedia interface testing system and method
CN109640087A (en) A kind of intra prediction mode decision method, device and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190416

RJ01 Rejection of invention patent application after publication