CN108282164B - Data encoding and decoding method and device - Google Patents

Data encoding and decoding method and device Download PDF

Info

Publication number
CN108282164B
CN108282164B CN201710007305.9A CN201710007305A CN108282164B CN 108282164 B CN108282164 B CN 108282164B CN 201710007305 A CN201710007305 A CN 201710007305A CN 108282164 B CN108282164 B CN 108282164B
Authority
CN
China
Prior art keywords
data
hard
format
target data
data format
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710007305.9A
Other languages
Chinese (zh)
Other versions
CN108282164A (en
Inventor
边肖翔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201710007305.9A priority Critical patent/CN108282164B/en
Publication of CN108282164A publication Critical patent/CN108282164A/en
Application granted granted Critical
Publication of CN108282164B publication Critical patent/CN108282164B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M13/00Coding, decoding or code conversion, for error detection or error correction; Coding theory basic assumptions; Coding bounds; Error probability evaluation methods; Channel models; Simulation or testing of codes
    • H03M13/65Purpose and implementation aspects
    • H03M13/6502Reduction of hardware complexity or efficient processing
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M13/00Coding, decoding or code conversion, for error detection or error correction; Coding theory basic assumptions; Coding bounds; Error probability evaluation methods; Channel models; Simulation or testing of codes
    • H03M13/65Purpose and implementation aspects
    • H03M13/6569Implementation on processors, e.g. DSPs, or software implementations

Landscapes

  • Physics & Mathematics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The application discloses a data encoding and decoding method and a device, the scheme is that after a data set to be encoded or decoded is determined, a data format set supported by a hard encoder or a hard decoder is obtained, and if a data format which is not tested exists in the data format set, a target data format which needs to be tested is selected; and controlling the hard encoder or the hard decoder to encode or decode the target data based on the target data format while controlling the soft encoder or the soft decoder to encode or decode the target data currently processed, wherein if the data encoded by the hard encoder or decoded by the hard decoder is normal, the decoding of the soft encoder or the soft decoder can be terminated, and the data which is not processed in the data set is directly encoded or decoded by the hard encoder or the hard decoder. According to the scheme, the encoding and decoding modes can be reasonably selected, and the CPU occupancy rate is reduced to the maximum extent.

Description

Data encoding and decoding method and device
Technical Field
The present application relates to the field of data processing technologies, and in particular, to a method and an apparatus for encoding and decoding data.
Background
For example, because audio and video files contain a large amount of data, in order to reduce the data amount transmitted over a network under the condition that the audio and video files need to be transmitted, the audio and video files need to be encoded, and then the encoded audio or video data are transmitted over the network; correspondingly, at the playing end where the encoded audio and video data are received, the audio and video data can be decoded to realize the playing of the audio and video.
At present, the data coding and decoding modes include soft coding and decoding and hard coding and decoding, wherein the soft coding and decoding refers to coding or decoding realized by using a software algorithm; while hard-coding refers to implementing encoding or decoding based on hardware in the device. The compatibility of soft coding and decoding is higher, the realization of data coding or decoding is simpler, but the occupancy rate of a Central Processing Unit (CPU) is higher, and equipment is easy to generate heat due to the overweight load of the CPU; while the hard codec has high efficiency of data encoding or decoding, but is not compatible with all data formats, and even if a certain data format is compatible, the encoding or decoding may be unsuccessful. Therefore, how to reasonably select the encoding and decoding mode to reduce the occupancy rate of the CPU on the premise of ensuring successful encoding and decoding is a technical problem that needs to be solved urgently by technical personnel in the field.
Disclosure of Invention
In view of this, the present application provides a data encoding and decoding method and apparatus, which reduce the CPU occupancy to the maximum extent by reasonably selecting the encoding and decoding modes.
To achieve the above object, in one aspect, an embodiment of the present application provides a data encoding method, including:
determining a data set to be encoded;
acquiring a data format set supported by a hard encoder, wherein the data format set comprises at least one data format;
if the data format set has the data formats which are not tested, selecting a target data format to be tested from the data formats which are not tested in the data format set;
controlling a soft encoder to encode target data to be encoded currently in the data set, and controlling a hard encoder to encode the target data based on the target data format;
and if the data coded by the hard coder is normal, terminating the coding of the soft coder, and controlling the hard coder to code the data which is not coded in the data set based on the target data format.
On the other hand, an embodiment of the present application further provides a data decoding method, including:
Determining a data set to be decoded;
acquiring a data format set supported by a hard decoder, wherein the data format set comprises at least one data format;
if the data format set has the data formats which are not tested, selecting a target data format to be tested from the data formats which are not tested in the data format set;
controlling a soft decoder to decode target data to be decoded currently in the data set, and controlling a hard decoder to decode the target data based on the target data format;
if the data decoded by the hard decoder is normal, the decoding of the soft decoder is terminated, and the hard decoder is controlled to decode the data which is not decoded in the data set based on the target data format.
On the other hand, an embodiment of the present application further provides a data encoding apparatus, including:
the data determining unit is used for determining a data set to be coded;
the format acquisition unit is used for acquiring a data format set supported by a hard encoder, wherein the data format set comprises at least one data format;
the format selecting unit is used for selecting a target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set;
The encoding control unit is used for controlling the soft encoder to encode target data to be encoded currently in the data set and controlling the hard encoder to encode the target data based on the target data format;
and the coding selection unit is used for terminating the coding of the soft coder if the data coded by the hard coder is normal, and controlling the hard coder to code the data which is not coded in the data set based on the target data format.
On the other hand, an embodiment of the present application further provides a data decoding apparatus, including:
the data acquisition unit is used for determining a data set to be decoded;
a format acquiring unit, configured to acquire a data format set supported by a hard decoder, where the data format set includes at least one data format;
the format selecting unit is used for selecting a target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set;
a decoding control unit, configured to control a soft decoder to decode target data to be decoded currently in the data set, and control the hard decoder to decode the target data based on the target data format;
And the decoding selection unit is used for terminating the decoding of the soft decoder if the data decoded by the hard decoder is normal, and controlling the hard decoder to decode the data which is not decoded in the data set based on the target data format.
As can be seen from the above, in the embodiment of the present application, while the computer device encodes (or decodes) data by using the soft encoder (or the soft decoder), it will attempt to encode (or encode) data by using the hard encoder (or the hard decoder) according to the data format supported by the hard encoder (or the hard decoder), if the hard encoder encodes (or the hard decoder decodes) successfully, the soft encoding (or the soft decoding) mode will be terminated, and the data that has not been encoded (or decoded) in the data set to be encoded (to be decoded) will be encoded (or decoded) continuously by using the hard encoding (or the hard decoding) mode, so that on the premise of ensuring the encoding (or decoding) success, the encoding (or decoding) mode is reasonably selected, and the situation of excessive CPU resource consumption caused by using the soft encoding (or the soft decoding) mode alone is avoided, the situation that the temperature of the computer equipment is too high due to the too high load of the CPU is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following description are only the embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
FIG. 1 is a schematic diagram of a component structure of a computer device disclosed herein;
fig. 2 is a schematic diagram of an application scenario in which a data encoding and decoding method is applied according to the present application;
FIG. 3 is a schematic flow chart diagram illustrating an embodiment of a data encoding method disclosed herein;
FIG. 4 is a schematic diagram illustrating a flow interaction of a data encoding method in an application scenario of the present application;
FIG. 5 is a flow chart illustrating an embodiment of a data decoding method disclosed herein;
FIG. 6 is a schematic block diagram illustrating an exemplary embodiment of a data encoding apparatus according to the present application;
fig. 7 is a schematic diagram illustrating a component structure of an embodiment of a data decoding apparatus according to the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be described clearly and completely with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only some embodiments of the present application, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The data encoding and decoding method can be applied to any computer equipment with encoding and decoding functions, so that the encoding and decoding modes can be reasonably selected, the encoding and decoding efficiency is improved, and the processor resources occupied by encoding and decoding are reduced.
In the data encoding method of the embodiment of the application, after determining a data set to be encoded, a computer device obtains a data format set supported by a hard encoder, wherein the data format set comprises at least one data format; if the data formats which are not tested exist in the data format set, selecting a target data format to be tested from the data formats which are not tested; controlling a soft encoder to encode target data to be encoded currently in a data set, and controlling a hard encoder to encode the target data based on the target data format; if the data coded by the hard coder is normal, the coding of the soft coder is terminated, and the hard coder is controlled to code the data which is not coded in the data set based on the target data format.
Therefore, when the computer device utilizes the soft encoder to encode the data, the hard encoder is tried to encode the data according to the data format supported by the hard encoder, if the hard encoder is successfully encoded, the soft encoding mode is terminated, and the hard encoding mode is utilized to continuously encode the data which is not encoded in the data set to be encoded, so that the situation that the CPU resource consumption is too much due to the utilization of the soft encoding mode, and the temperature of the computer device is too high is avoided. In addition, in the process of trying hard coding, the computer device also utilizes soft coding to code the target data to be coded, so that before the data is successfully coded by adopting a hard coding mode, the data coding result obtained by coding the data by utilizing the soft coding can still be obtained, the time in the process of trying the hard coding mode to code the data is effectively utilized, and the time waste caused by trying the hard coding process is avoided.
Optionally, for a certain target data format, if the encoded data is not normal after the hard encoder encodes the target data based on the target data format, the operation of selecting the target data format to be tested from the data formats which are not tested in the data set if the data format set has the data format which is not tested yet is returned to be executed, so as to completely traverse all the data formats supported by the hard encoder.
Correspondingly, in the data decoding method of the embodiment of the application, after determining the data set to be decoded, the computer device obtains the data format set supported by the hard decoder, where the data format set includes at least one data format; if the data format set has the data formats which are not tested, selecting a target data format to be tested from the data formats which are not tested in the data format set; controlling a soft decoder to decode target data to be decoded currently in the data set, and controlling a hard decoder to decode the target data based on the target data format; if the data decoded by the hard decoder is normal, the decoding of the soft decoder is terminated, and the hard decoder is controlled to decode the data which is not decoded in the data set based on the target data format.
Therefore, when the computer device decodes the data by using the soft decoder, the hard decoder is tried to decode the data according to the data format supported by the hard decoder, if the hard decoder is successful, the soft decoding mode is terminated, and the data which is not decoded in the data set to be decoded is decoded continuously by using the hard decoding mode, so that the situation that the CPU resource consumption is excessive due to the use of the soft decoding mode and the temperature of the computer device is overhigh is avoided. In addition, in the process of attempting hard decoding, the computer device also decodes the target data to be decoded by using soft decoding, so that before the data is successfully decoded by using a hard decoding mode, the data decoding result obtained by decoding the data by using soft decoding can still be obtained, the time in the process of attempting hard decoding to decode the data is effectively used, and the time waste caused by attempting the hard decoding process is avoided.
Optionally, for a certain target data format, if the data decoded by the hard decoder is not normal, returning to execute the operation of selecting the target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set, so as to completely traverse all the data formats supported by the hard encoder, thereby being beneficial to improving the utilization rate of the hard encoder, reducing the probability of using the soft encoder, and effectively reducing the occupancy rate of the CPU.
It is understood that, in the embodiment of the present application, the computer device may be a computer as a server; or a mobile phone, a tablet computer, a desktop computer and other terminals.
It should be noted that in the embodiment of the present application, encoding and decoding are two mutually independent data processing stages of data.
The encoding and decoding stages may be performed in the same computer device, for example, the computer device encodes data and stores the encoded data, and the computer device may retrieve the stored encoded data and decode the encoded data to present the related content.
The two data processing processes of encoding and decoding may also be respectively performed by two different computer devices, for example, after data is encoded in one computer device, the encoded data is transmitted to another computer device, so as to output the content related to the data in the other computer device; accordingly, the other computer device, upon receiving the encoded data, can decode the encoded data to enable output of the data.
For example, referring to fig. 1, a schematic diagram of a component structure of a computer device for implementing encoding or decoding is shown. In fig. 1, the computer apparatus may include: processor 101, memory 102, communication interface 103.
Optionally, the computer device may further include: a display 104 and an input unit 105.
The processor 101, the memory 102, the communication interface 103, the display 104 and the input unit 105 are all communicated with each other through a communication bus 106.
In the embodiment of the present application, the processor 101 at least includes: a Graphics Processing Unit (GPU) 1012, which may be used as a hard encoder and a hard decoder for hard encoding and/or hard decoding data in the embodiments of the present application.
Optionally, the processor 101 may include a Central Processing Unit (CPU) 1011, which may assist the graphics processor to complete some related processes such as data format conversion and coding control related to hard coding and hard decoding, and may also implement soft coding and/or soft decoding on data in the embodiment of the present application. Of course, the central processing unit may also be replaced by an application-specific integrated circuit (ASIC), a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, etc.
The memory 102 is used to store one or more programs, which may include program code including computer operating instructions. The memory may comprise high-speed RAM memory, and may also include non-volatile memory, such as at least one disk memory.
The communication interface 103 may be an interface of a communication module, such as an interface of a GSM module.
The display 104 can be used to display the content corresponding to the decoded data; information entered by or provided to the user, as well as various graphical user interfaces of the computer device, which may be made up of any combination of graphics, text, pictures, etc., may also be displayed. The display may include a display panel, e.g., a display panel that may be configured in the form of a liquid crystal display, an organic light emitting diode, or the like. Further, the display may include a touch display panel with a capture touch event.
The input unit 105 may be used to receive input of user-input characters, numbers, etc., and to generate signal inputs related to user settings and function control. The input unit may include, but is not limited to, one or more of a physical keyboard, a mouse, a joystick, and the like.
It can be understood that fig. 1 is described by taking hardware for implementing hard coding and hard decoding in a computer device as a GPU as an example, but it can be understood that there are other possible cases for the hardware for implementing hard coding and hard decoding in the computer device, and details are not described here.
Of course, the computer device configuration shown in FIG. 1 is not intended to be limiting, and in actual practice a computer device may include more or less components than those shown in FIG. 1, or some combination of components.
For ease of understanding, the following describes an application scenario to which the embodiments of the present application are applied.
The encoding and decoding processes are respectively executed by different computer devices for example, and the data to be encoded and decoded are assumed to be multimedia data such as audio and video. Referring to fig. 2, it shows a schematic diagram of an application scenario of the present application, and in the application scenario of fig. 2, the application scenario includes:
At least one server 201 and at least one terminal 202.
Wherein the at least one server 201 may constitute a server cluster for providing multimedia servers to player clients.
In one possible scenario, the terminal 202 may be the player client, for example, the terminal may be a mobile phone, a tablet computer, or the like, which is installed with a player.
The server 201 may store or retrieve multimedia data from a database, which is available for the player client to play. Meanwhile, in this embodiment, the server may encode the multimedia data and transmit the encoded data to the player client 202 through the network.
For example, when the server receives a play request or a download request of the player client for the multimedia resource, the server obtains the multimedia data requested by the player client, and encodes the multimedia resource to encode the multimedia resource into a specified multimedia format, and the amount of data required to be transmitted can be obtained by encoding the multimedia data. For another example, when acquiring the multimedia data to be stored, the server may encode the multimedia data into a specified multimedia format, and then store the encoded multimedia data, so as to transmit the encoded multimedia data to the terminal in the following.
Correspondingly, the player client can acquire the encoded multimedia data from the server, decode the encoded multimedia data, and decode the multimedia data into a multimedia format suitable for being played by the player, so as to realize multimedia playing on the player.
In another possible case, the server 201 may also be a server that interconnects two or more terminals 202, in which case, the terminal 202 may transmit the multimedia resource to other terminals 202 through the server, and before the terminal 202 transmits the multimedia resource, data corresponding to the multimedia resource may also be encoded, and then the encoded multimedia data is transmitted to the server, so that the encoded multimedia data is transmitted to a specified terminal or terminals through the server. And a terminal receiving the encoded multimedia data can decode the encoded multimedia data.
In addition, when data is transmitted between the two servers, the data can be encoded and then transmitted.
Of course, fig. 2 is only a schematic diagram of an application scenario, in an actual application, two terminals may also be used as a receiving end and a sending end of data, respectively, a terminal used as a sending end may encode data to be transmitted and then transmit the encoded data to a receiving end, and a terminal used as a receiving end may decode the received encoded data.
It should be noted that, whether the encoding and the decoding are performed by one computer device or two computer devices, the specific implementation procedure is the same for any computer device to perform the encoding (or the decoding). In the following, a data encoding method and a data decoding method according to embodiments of the present application will be described in detail with reference to the above commonalities.
Referring to fig. 3, a flow chart of an embodiment of the data encoding method according to the present application is shown, and the method according to the present application may be implemented by any one of the computer devices mentioned above. The method of the embodiment can comprise the following steps:
s301, acquiring a data set to be coded;
all data in the data set are data to be encoded, and the data set to be encoded may include one or more frames of data. For example, the data set to be encoded may be a file containing multiple frames of data, for example, the data set to be encoded may be an audio file, a video file, an image file, or the like.
S302, generating a soft coding thread for controlling soft coding and a hard coding thread for controlling hard coding;
As a preferred implementation manner, in the embodiment of the present application, two threads are respectively generated by a computer device, so that soft coding and hard coding are respectively controlled by the two threads, and by parallel running of the two threads, soft coding and hard coding of data to be coded are simultaneously implemented.
It is to be understood that step S302 is an optional step, and in practical applications, the process of soft coding and hard coding may also be controlled directly by a processor in the computer device without threads.
S303, initializing a soft encoder through a soft encoding thread, and starting the soft encoder;
wherein the soft encoder may be understood as a program run in a computer device for implementing soft encoding.
Initialization of the soft encoder may be to set parameters, encoded data formats, etc. required for operation of the soft encoder in preparation for starting the soft encoder. After initializing the soft encoder, the soft encoder may be started by the soft encoding thread for subsequent encoding of data by the soft encoder.
Where initializing the soft encoder and starting the soft encoder are optional steps, the purpose of which is only to prepare for subsequent encoding with the soft encoder.
S304, acquiring a data format set supported by a hard encoder through a hard encoding thread;
wherein, the data format set comprises at least one data format. The data formats supported by the hardware encoder may also be referred to as encoding formats supported by the hardware encoder. For example, for YUV color space based encoding, the data format supported by the encoder may be NV12, NV21, YUYV, or the like.
It is understood that, due to different models, manufacturers, and the like of different computer devices, data formats supported by hard encoders in different computer devices may also differ, and in general, a hard encoder in a computer device supports at least one data format.
Optionally, the hard coding thread may communicate with the hard encoder through an interface connected to the hard encoder to obtain a data format set composed of all data formats supported by the hard encoder.
S305, detecting whether a data format which is not tested exists in a data format set supported by a hard encoder through a hard encoding thread, and if so, executing a step S306; if not, go to step S316;
in the embodiment of the application, each data format in the data format set is sequentially used as a target data format to be tested, and whether the hard encoder can correctly perform data encoding is tested on the premise that the hard encoder supports the target data format or not is tested until all the data formats in the data format set are tested.
S306, determining target data needing to be coded currently from a data set to be coded;
it can be understood that a data set contains a large amount of data, and when encoding is performed, the data needs to be sequentially encoded according to the data order in the data set, and in the embodiment of the present application, the data or the data segment that needs to be currently encoded is referred to as target data.
For example, it is assumed that each time encoding is performed, a minimum data unit is encoded, for example, the data unit may be a frame of data, or may be data of a specified number of bits, so that a data unit that needs to be currently encoded may be determined according to a data sequence in a data set, and data included in the data unit may be used as target data.
It should be noted that the sequence of step S306 and step S305 is not limited to that shown in fig. 3, and in practical applications, step S306 may also be before step S305, that is, after the computer device determines that the target data that is determined last time has been encoded, step S306 may be executed to determine the target data that needs to be encoded currently.
S307, respectively indicating a soft coding thread and a hard coding thread to code the target data;
Wherein, the step S307 is an optional step, and in practical applications, the computer device may directly execute the steps S308 and S309 without separately performing the instruction; in addition, when there is no soft coding thread or hard coding thread, the step S307 does not need to be executed.
S308, controlling a soft encoder to encode the target data through a soft encoding line;
optionally, the soft coding thread may detect whether the original data format of the target data is the data format supported by the soft encoder, and if not, convert the target data into the data format supported by the soft encoder, and then encode the format-converted target data.
Optionally, after the soft coding thread determines that the soft encoder completes encoding of the target data, the soft coding thread may report encoding completion information to the computer device, so that the computer device determines whether to continue to determine the target data to be encoded from the data that is not yet encoded in the data set.
S309, selecting a target data format which needs to be tested currently from the data formats which are not tested in the data format set through the hard coding thread;
in the embodiment of the present application, the data format to be tested selected this time is referred to as a target data format.
S310, detecting whether a format conversion relation converted from the original data format of the target data to the target data format belongs to a preset format conversion relation through a hard coding thread, and if so, executing a step S311; if not, returning to the step S305;
in the embodiment of the present application, before performing format conversion on the target data, a data format of the target data is referred to as an original data format, so as to distinguish a target data format to be converted subsequently.
It is understood that the data formats supported by the hard encoder are very limited, and although some data format conversion can be performed by the hard encoding thread, not all data formats can be converted into the target data format, and therefore, a format conversion relationship between two data formats that can be successfully converted can be preset, and the format conversion relationship may include a conversion relationship between at least one pair of formats. If the original data format and the target data format do not belong to a pair of formats in the preset format conversion relationship, the original data format cannot be successfully converted into the target data format, and under the condition, the target data cannot be successfully hard-coded naturally.
The step S310 is an optional step, and is intended to avoid that the format conversion fails due to directly performing the data format conversion of the subsequent step S311, thereby consuming data processing resources.
S311, converting the original data format of the target data into the target data format through the hard coding thread;
s312, controlling the hard encoder to encode the target data converted into the target data format through a hard coding thread;
it should be noted that, in the embodiment of the present application, the process of steps S308 and steps S309 to S312 are executed synchronously, that is, in the process of controlling the soft encoder to perform soft encoding on the target data, the data format conversion required for hard encoding on the target data is performed at the same time, and the hard encoder is controlled to perform hard encoding on the target data.
S313, detecting whether the encoded target data is normal through the hard coding thread, and if so, executing the step S314; if not, returning to the step S305;
the detection of whether the encoded target data is normal or not is actually to detect whether the encoded data is correct, the detection of whether the encoded target data is correct or not may be performed in various ways, and when the types of the data are different, the detection may be performed in different ways. For example, when the target data is video data, the first frame data encoded by the encoder is an I-frame, and the I-frame has a specific format standard, and whether the encoding is correct or not can be determined by the identification information of the header of the I-frame.
S314, stopping the operation of the soft encoder through the soft coding thread and stopping the soft coding thread;
s315, the hard coding thread controls the hard coder to code the uncoded data in the data set based on the target data format until all the data in the data set are coded.
It should be noted that, when the encoded target data is detected to be normal by the hard-coded thread, step S314 and step S315 may be executed at the same time, or step S315 may be executed after step S314 is executed.
It can be understood that if the encoding result is correct after the hard encoder encodes the target data converted into the target data format, it indicates that the encoding is successful, and also indicates that, on the premise of converting the target data to be encoded in the data set into the target data format, the hard encoder can correctly encode the data to be encoded in the data set.
Meanwhile, the soft encoder and the hard encoder perform data encoding in parallel before the hard encoder successfully encodes the data, so that when the hard encoder is tested to be in a certain target data format and can successfully encode the data, the hard encoder does not need to be used for re-encoding the data encoded by the soft encoder, and only the data which is not encoded in the data set needs to be encoded again, thereby avoiding the situation that the data encoding cannot be performed due to the fact that whether the hard encoder is tested to be feasible, and the time waste is caused, and further improving the encoding efficiency.
S316, stopping the operation of the hard encoder through the hard coding thread and stopping the hard coding thread;
and S317, controlling the soft encoder to encode the uncoded data in the data set through a soft encoding thread until all the data in the data set are encoded.
The sequence of step S316 and step S317 is not limited to that shown in fig. 3, and in practical applications, step S316 and step S317 may be executed simultaneously.
It will be appreciated that if all the data formats supported by the hard encoder are tested and the hard encoder is still unable to successfully encode the data, it means that the computer device is unable to encode the data to be encoded in the data set using the hard encoding method.
Of course, in order to ensure normal encoding of data, when all data formats supported by the hard encoder are tested and the hard encoder cannot correctly encode data, the hard encoder may be terminated, and the soft encoder may still be used to encode the uncoded data in the data set until all data in the data set are encoded. In the hard coding test process, the soft encoder is also used for encoding all the time, so that even if the hard coding test is unsuccessful, the data encoded by the soft encoder can still be used, the encoding time length cannot be additionally increased, and the encoding efficiency can be improved.
To facilitate understanding of the beneficial effects produced by the data encoding method according to the embodiment of the present application, the following describes the data encoding process according to the embodiment of the present application in conjunction with an application scenario, and for convenience of description, the following describes the application scenario shown in fig. 2 by taking the example that the data to be encoded is video data. For example, referring to fig. 4, which shows a flowchart of a data encoding method disclosed in the present application, it is assumed that the hard encoder in the server only supports two data formats, i.e., a first data format and a second data format, and it is assumed that the hard encoder can encode data in a video file based on the second data format. The method of the embodiment may include:
S401, the player client sends a video playing request to a server;
s402, the server responds to the video playing request and determines a video file requested by the player client;
s403, the server generates a soft coding thread and a hard coding thread;
s404, the server determines that the data formats supported by the GPU are a first data format and a second data format through a hard encoder thread;
s405, the server determines target video data needing encoding currently from the video file;
s406, the server controls the soft encoder to encode the target video data through the soft encoding thread, converts the original data format of the target video data into a first data format through the hard encoding thread, and controls the GPU to encode the target video data converted into the first data format;
in the embodiment of the present application, the GPU in the server is taken as an example for introduction, and of course, if the hard encoder in the server is other hardware, the GPU in the server is also applicable to the embodiment of the present application.
S407, the server transmits the encoding result of the soft encoder to the target video data to the player client;
s408, the server detects that the data coded by the GPU is incorrect, and determines target video data needing to be coded currently from video data which are not coded in the video file;
Step S407 may be performed simultaneously with the process of detecting whether the GPU encoded data is normal and determining the target video data in step S408, so as to improve data encoding efficiency and reduce encoding time consumption.
S409, the server controls the soft encoder to encode the target video data through the soft encoding thread, converts the original data format of the target video data into a second data format through the hard encoding thread, and controls the GPU to encode the target video data converted into the second data format;
s410, the server transmits the encoding result of the soft encoder on the target data to the player client.
As can be seen from step S407 and step S410, on the premise that the server does not determine that the video data can be correctly encoded by using the GPU (i.e., the hard encoder), the server can still transmit the encoded video data to the player client, and compared with the case that the video data is encoded by using the GPU after testing that the GPU can successfully encode the video data, the encoding efficiency and the data transmission efficiency can be improved.
S411, if the server detects that the data coded by the GPU based on the second data format is correct, the server terminates the soft coder and the soft coding thread;
S412 controls, through the hard-coded thread, the GPU to encode video data in the video file that has not been encoded based on the second data format.
And when the server determines that the GPU can successfully encode the video file based on the second data format, the method can be directly switched to the method of carrying out hard encoding on the data which are not encoded in the video file by using the GPU, so that the problem of overlarge CPU occupancy rate caused by using soft encoding is avoided.
S413, the server transmits the coding result of the GPU for coding the data in the video file to the player client.
Steps S412 and S413 are repeated until all video data in the video file is encoded and transmitted to the player client.
The following describes the data decoding method in detail according to the embodiment of the present application.
Referring to fig. 5, which shows a schematic flowchart of an embodiment of a data decoding method according to the present application, the method according to the embodiment of the present application may include:
s501, acquiring a data set to be decoded;
all data in the data set are data to be decoded, and the data set to be decoded may include one or more frames of data. For example, the data set to be decoded may be an audio file to be decoded, a video file, an image file, or the like.
It is understood that the data set may be pre-acquired or received in real-time. For example, in practical applications, the computer device may continuously receive data to be decoded in the form of a data stream, and if the computer device decodes the received encoded data in real time, the currently received data set may be the target data to be decoded subsequently; of course, if the speed of receiving data is greater than the decoding rate, the amount of data in the data set will be greater than the amount of data targeted.
S502, generating a soft decoding thread for controlling soft decoding and a hard decoding thread for controlling hard decoding;
as a preferred implementation manner, in the embodiment of the present application, two threads are respectively generated by a computer device, so that soft decoding and hard decoding are respectively controlled by the two threads, and soft decoding and hard decoding of data to be decoded are simultaneously implemented by parallel operation of the two threads.
It is understood that step S502 is an optional step, and the process of soft decoding and hard decoding directly controlled by the processor in the computer device is also applicable to the embodiment of the present application if not by a thread.
S503, initializing a soft decoder through a soft decoding thread, and starting the soft decoder;
wherein the soft decoder may be understood as a program run in a computer device for implementing soft decoding.
The initialization of the soft decoder may be similar to the initialization process of the previous soft encoder.
Where initializing the soft decoder and starting the soft decoder are optional steps, the purpose of which is simply to prepare for subsequent decoding with the soft decoder.
S504, acquiring a data format set supported by a hard decoder through a hard decoding thread;
wherein, the data format set comprises at least one data format. For the data formats and the process of obtaining the data format set, reference may be made to the related description of step S504.
S505, detecting whether a data format which is not tested exists in a data format set supported by a hard decoder through a hard decoding thread, if so, executing a step S506; if not, go to step S516;
in the embodiment of the application, each data format in the data format set is sequentially used as a target data format to be tested, and whether the hard decoder can correctly decode data is tested on the premise that the hard decoder supports the target data format or not is tested until all the data formats in the data format set are tested.
S506, determining target data needing to be decoded currently from a data set to be decoded;
the data set may include a large amount of data, and when decoding is performed, the data needs to be sequentially decoded according to a data sequence in the data set, and in this embodiment, the data or the data segment that needs to be decoded at present is referred to as target data.
It should be noted that the sequence of step S506 and step S505 is not limited to that shown in fig. 5, and in practical applications, step S506 may also be performed before step S505, and after the computer device determines that the target data determined last time has been decoded, step S506 may be performed to determine the target data that needs to be decoded currently.
And S507, respectively instructing the soft decoding thread and the hard decoding thread to decode the target data.
Wherein, the step S507 is an optional step, and in practical applications, the computer device may directly perform the steps S508 and S509 without separately performing an instruction; in addition, when there is no soft decoding thread or hard decoding thread, the step S507 does not need to be executed.
S508, controlling the soft decoder to decode the target data through a soft decoding thread.
Optionally, the soft decoding thread may detect whether the original data format of the target data is the data format supported by the soft decoder, and if not, convert the target data into the data format supported by the soft decoder, and then decode the format-converted target data.
Optionally, after the soft decoding thread determines that the soft decoder completes decoding of the target data, the soft decoding thread may report decoding completion information to the computer device, so that the computer device determines whether to continue to determine the target data to be decoded from the data that is not yet decoded in the data set.
S509, selecting a target data format to be tested currently from the data formats which are not tested in the data format set through the hard decoding thread;
in the embodiment of the present application, the data format to be tested selected this time is referred to as a target data format.
S510, detecting whether a format conversion relation converted from the original data format of the target data to the target data format belongs to a preset format conversion relation through a hard decoding thread, and if so, executing the step S511; if not, returning to the step S505;
In the embodiment of the present application, before format conversion is performed on the target data, a data format of the target data is referred to as an original data format, so as to distinguish a target data format to be converted subsequently.
The step S510 is an optional step, and is intended to avoid that the format conversion fails due to directly performing the data format conversion of the subsequent step S511, thereby consuming data processing resources.
S511, converting the original data format of the target data into the target data format through a hard decoding thread;
s512, controlling a hard decoder to decode the target data converted into the target data format through a hard decoding thread;
it should be noted that, in the embodiment of the present application, the process of step S508 and the process of steps S509 to S512 are executed synchronously, that is, in the process of controlling the soft decoder to perform soft decoding on the target data, the data format conversion required for hard decoding on the target data is performed at the same time, and the hard decoder is controlled to perform hard decoding on the target data.
S513, detecting whether the decoded target data is normal through a hard decoding thread, and if so, executing the step S514; if not, returning to the step S505;
The detection of whether the decoded target data is normal or not is actually to detect whether the decoded data is correct, and may be similar to the process of detecting whether the encoded data is normal or not, which is not described herein again.
S514, stopping the operation of the soft decoder through the soft decoding thread, and stopping the soft decoding thread;
and S515, controlling a hard decoder to decode undecoded data in the data set based on the target data format through a hard decoding thread until all data in the data set are decoded.
When the encoded target data is detected to be normal by the hard-coded thread, step S514 and step S515 may be executed at the same time, or step S515 may be executed after step S514 is executed.
It can be understood that if the decoding result is correct after the hard decoder decodes the target data converted into the target data format, it indicates that the decoding is successful, and also indicates that, on the premise of converting the target data to be decoded in the data set into the target data format, the hard decoder can correctly decode the data to be decoded in the data set.
Meanwhile, the soft decoder and the hard decoder perform data decoding in parallel before the hard decoder successfully decodes the data, so that when the hard decoder is tested to be capable of successfully decoding the data under a certain target data format, the hard decoder does not need to be used for decoding the data decoded by the soft decoder again, and only the data which is not decoded in the data set is decoded, thereby avoiding the situation that the data decoding cannot be performed due to the fact that whether the hard decoding is tested to be feasible, and causing time waste, and further improving the decoding efficiency.
S516, stopping the operation of the hard decoder through the hard decoding thread and stopping the hard decoding thread;
s517, the soft decoder is controlled by the soft decoding thread to decode the undecoded data in the data set until all the data in the data set are decoded.
The sequence of step S516 and step S517 is not limited to that shown in fig. 5, and in practical applications, step S516 and step S517 may be executed simultaneously.
It can be understood that if all data formats supported by the hard decoder are tested and the hard decoder still cannot successfully decode the data, it means that the computer device cannot decode the data to be decoded in the data set by using the hard decoding method.
Of course, in order to ensure normal decoding of data, if the computer device cannot decode data in a hard decoding manner, the hard decoder may be terminated, and the soft decoder may still be used to decode data that is not decoded in the data set until decoding of all data in the data set is completed. In the hard decoding test process, the soft decoder is also decoding all the time, so even if the hard decoding test is unsuccessful, the data decoded by the soft decoder can still be used, the decoding time length cannot be additionally increased, and the decoding efficiency can be improved.
A data encoding device of the present application is described below.
Referring to fig. 6, which shows a schematic structural diagram of an embodiment of a data encoding apparatus according to the present application, the data encoding apparatus may be applied to the aforementioned computer device, and the data encoding apparatus of the present embodiment may include:
a data determining unit 601, configured to determine a data set to be encoded;
a format obtaining unit 602, configured to obtain a data format set supported by a hard encoder, where the data format set includes at least one data format;
a format selecting unit 603, configured to select a target data format to be tested from data formats that have not been tested in the data format set if the data format set has data formats that have not been tested;
An encoding control unit 604, configured to control the soft encoder to encode target data to be currently encoded in the data set, and control the hard encoder to encode the target data based on the target data format;
a code selecting unit 605, configured to terminate the coding of the soft encoder if the data coded by the hard encoder is normal, and control the hard encoder to code the data that has not been coded in the data set based on the target data format.
Optionally, the data encoding apparatus may further include:
and a format traversing unit 606, configured to trigger a return operation to the format selecting unit if the data encoded by the hard encoder is not normal.
Optionally, the data encoding apparatus may further include:
and the soft coding switching unit is used for terminating the operation of the hard coder and controlling the soft coder to code the data which is not coded in the data set if the data coded by the hard coder is abnormal and no data format which is not tested exists in the data format set.
Optionally, the encoding control unit includes:
A first encoding control unit, configured to convert an original data format of target data into the target data format supported by the hard encoder while controlling the soft encoder to encode the target data to be currently encoded in the data set;
a second encoding control unit for controlling the hard encoder to encode the target data converted into the target data format.
Optionally, the data encoding apparatus may further include:
a format detection unit, configured to detect whether a format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship before the first encoding control unit converts the target data into the target data format supported by the hard encoder;
the first encoding control unit is configured to, while controlling the soft encoder to encode target data to be encoded currently in the data set, convert the target data into the target data format supported by the hard encoder if the format detection unit detects that a format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship.
Optionally, the data encoding apparatus further includes:
the thread generating unit is used for generating a soft coding thread for controlling soft coding and a hard coding thread for controlling hard coding before the format acquiring unit acquires the data format set supported by the hard coder;
the encoding control unit is specifically: and controlling a soft encoder to encode target data through the soft encoding thread, and controlling a hard encoder to encode the target data through the hard encoding thread, wherein the target data is data to be encoded currently in the target data.
A data decoding apparatus according to an embodiment of the present application is described below.
Referring to fig. 7, which shows a schematic structural diagram of an embodiment of a data decoding apparatus according to the present application, the apparatus of the present embodiment may include:
a data obtaining unit 701, configured to determine a data set to be decoded;
a format obtaining unit 702, configured to obtain a data format set supported by a hard decoder, where the data format set includes at least one data format;
a format selecting unit 703, configured to select a target data format to be tested from data formats that have not been tested in the data format set if the data format set has data formats that have not been tested;
A decoding control unit 704, configured to control a soft decoder to decode target data to be currently decoded in the data set, and control the hard decoder to decode the target data based on the target data format;
a decoding selecting unit 705, configured to terminate decoding by the soft decoder if the data decoded by the hard decoder is normal, and control the hard decoder to decode data in the data set that has not been decoded yet based on the target data format.
Optionally, the data decoding unit further includes:
and a format traversal unit 706, configured to trigger a return operation of the format selection unit if the data decoded by the hard decoder is not normal.
Optionally, the data decoding apparatus further includes:
a soft decoding switching unit, configured to terminate operation of the hard decoder and control the soft decoder to decode data in the data set that has not been decoded if the data decoded by the hard decoder is not normal and there is no data format in the data format set that has not been tested yet.
Optionally, the decoding control unit includes:
A first decoding control unit, configured to convert an original data format of target data into the target data format supported by the hard decoder while controlling the soft decoder to decode the target data to be decoded currently in the data set;
a second decoding control unit for controlling the hard decoder to decode the target data converted into the target data format.
Optionally, the data decoding apparatus further includes:
a format detection unit, configured to detect whether a format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship before the first decoding control unit converts the target data into the target data format supported by the hard decoder;
the first decoding control unit is specifically configured to, while controlling the soft decoder to decode target data to be decoded currently in the data set, convert the target data into the target data format supported by the hard decoder if a format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship.
Optionally, the data decoding unit further includes:
a thread generating unit, configured to generate a soft decoding thread for controlling soft decoding and a hard decoding thread for controlling hard decoding before the format acquiring unit acquires the data format set supported by the hard decoder;
the decoding control unit is specifically configured to control, by the soft decoding line, the soft decoder to decode target data, and at the same time, control, by the hard decoding line, the hard decoder to decode the target data, where the target data is data to be decoded currently in the target data.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. For the device-like embodiment, since it is basically similar to the method embodiment, the description is simple, and reference may be made to the partial description of the method embodiment for relevant points.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that it is obvious to those skilled in the art that various modifications and improvements can be made without departing from the principle of the present invention, and these modifications and improvements should also be considered as the protection scope of the present invention.

Claims (16)

1. A method of encoding data, comprising:
determining a data set to be encoded;
acquiring a data format set supported by a hard encoder, wherein the data format set comprises at least one data format;
if the data format set has the data formats which are not tested, selecting a target data format to be tested from the data formats which are not tested in the data format set;
Controlling a soft encoder to encode target data to be encoded currently in the data set, and controlling a hard encoder to encode the target data based on the target data format;
if the data coded by the hard coder is normal, the coding of the soft coder is terminated, and the hard coder is controlled to code the data which is not coded in the data set based on the target data format.
2. The data encoding method of claim 1, further comprising:
and if the data coded by the hard coder is abnormal, returning to execute the operation of selecting the target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set.
3. The data encoding method of claim 1 or 2, further comprising:
if the data coded by the hard coder is abnormal and the data format which is not tested yet does not exist in the data format set, the operation of the hard coder is terminated, and the soft coder is controlled to code the data which is not coded yet in the data set.
4. The data encoding method of claim 1, wherein controlling the soft encoder to encode target data to be currently encoded in the data set while controlling the hard encoder to encode the target data based on the target data format comprises:
when controlling a soft encoder to encode target data to be encoded currently in the data set, converting an original data format of the target data into the target data format supported by the hard encoder;
and controlling the hard encoder to encode the target data converted into the target data format.
5. The data encoding method of claim 4, further comprising, before converting the original data format of the target data into the target data format supported by the hard encoder:
detecting whether the format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship;
and if the format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship, executing the conversion of the target data into the target data format supported by the hard encoder.
6. The data encoding method of claim 1, further comprising, before the obtaining the set of data formats supported by the hard encoder:
generating a soft coding thread for controlling soft coding and a hard coding thread for controlling hard coding;
the controlling the hard encoder to encode the target data based on the target data format while controlling the soft encoder to encode the target data to be currently encoded in the data set includes:
and controlling a soft encoder to encode target data through the soft encoding thread, and controlling a hard encoder to encode the target data through the hard encoding thread, wherein the target data is data to be encoded currently in the target data.
7. A method of decoding data, comprising:
determining a data set to be decoded;
acquiring a data format set supported by a hard decoder, wherein the data format set comprises at least one data format;
if the data format set has the data formats which are not tested, selecting a target data format to be tested from the data formats which are not tested in the data format set;
Controlling a soft decoder to decode target data to be decoded currently in the data set, and controlling a hard decoder to decode the target data based on the target data format;
if the data decoded by the hard decoder is normal, the decoding of the soft decoder is terminated, and the hard decoder is controlled to decode the data which is not decoded in the data set based on the target data format.
8. The data decoding method of claim 7, further comprising:
and if the data decoded by the hard decoder is abnormal, returning to execute the operation of selecting the target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set.
9. The data decoding method according to claim 7 or 8, further comprising:
if the data decoded by the hard decoder is abnormal and the data format which is not tested yet does not exist in the data format set, the operation of the hard decoder is terminated, and the soft decoder is controlled to decode the data which is not decoded yet in the data set.
10. The data decoding method of claim 7, wherein controlling the soft decoder to decode target data currently to be decoded in the data set and controlling the hard decoder to decode the target data based on the target data format comprises:
when a soft decoder is controlled to decode target data to be decoded currently in the data set, converting an original data format of the target data into the target data format supported by the hard decoder;
and controlling the hard decoder to decode the target data converted into the target data format.
11. The data decoding method of claim 10, further comprising, before converting the original data format of the target data into the target data format supported by the hard decoder:
detecting whether the format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship;
and if the format conversion relationship from the original data format to the target data format belongs to a preset format conversion relationship, executing the conversion of the target data into the target data format supported by the hard decoder.
12. The data decoding method of claim 7, further comprising, before the obtaining the set of data formats supported by the hard decoder:
generating a soft decoding thread for controlling soft decoding and a hard decoding thread for controlling hard decoding;
the controlling the hard decoder to decode the target data based on the target data format while controlling the soft decoder to decode the target data to be decoded currently in the data set includes:
controlling a soft decoder to decode target data through the soft decoding thread, and simultaneously controlling the hard decoder to decode the target data through the hard decoding thread, wherein the target data is data to be decoded currently in the target data.
13. A data encoding apparatus, comprising:
the data determining unit is used for determining a data set to be coded;
the format acquisition unit is used for acquiring a data format set supported by a hard encoder, wherein the data format set comprises at least one data format;
the format selecting unit is used for selecting a target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set;
The encoding control unit is used for controlling the soft encoder to encode target data to be encoded currently in the data set and controlling the hard encoder to encode the target data based on the target data format;
and the coding selection unit is used for terminating the coding of the soft coder if the data coded by the hard coder is normal, and controlling the hard coder to code the data which is not coded in the data set based on the target data format.
14. The data encoding apparatus of claim 13, further comprising:
and the format traversing unit is used for triggering and returning to execute the operation of the format selecting unit if the data coded by the hard coder is abnormal.
15. A data decoding apparatus, comprising:
the data acquisition unit is used for determining a data set to be decoded;
the format acquisition unit is used for acquiring a data format set supported by a hard decoder, wherein the data format set comprises at least one data format;
the format selecting unit is used for selecting a target data format to be tested from the data formats which are not tested in the data format set if the data formats which are not tested exist in the data format set;
A decoding control unit, configured to control a soft decoder to decode target data to be decoded currently in the data set, and control the hard decoder to decode the target data based on the target data format;
and the decoding selection unit is used for terminating the decoding of the soft decoder if the data decoded by the hard decoder is normal, and controlling the hard decoder to decode the data which is not decoded in the data set based on the target data format.
16. The data decoding apparatus of claim 15, further comprising:
and the format traversing unit is used for triggering and returning to execute the operation of the format selecting unit if the data decoded by the hard decoder is abnormal.
CN201710007305.9A 2017-01-05 2017-01-05 Data encoding and decoding method and device Active CN108282164B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710007305.9A CN108282164B (en) 2017-01-05 2017-01-05 Data encoding and decoding method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710007305.9A CN108282164B (en) 2017-01-05 2017-01-05 Data encoding and decoding method and device

Publications (2)

Publication Number Publication Date
CN108282164A CN108282164A (en) 2018-07-13
CN108282164B true CN108282164B (en) 2022-07-15

Family

ID=62800593

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710007305.9A Active CN108282164B (en) 2017-01-05 2017-01-05 Data encoding and decoding method and device

Country Status (1)

Country Link
CN (1) CN108282164B (en)

Families Citing this family (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110858827B (en) * 2018-08-22 2023-03-24 浙江宇视科技有限公司 Broadcast starting acceleration method and device and computer readable storage medium
CN111147926B (en) * 2018-11-02 2022-05-06 杭州海康威视数字技术股份有限公司 Data transcoding method and device
CN111355997B (en) * 2018-12-21 2021-01-29 北京字节跳动网络技术有限公司 Video file generation method and device, mobile terminal and storage medium
CN111355960B (en) * 2018-12-21 2021-05-04 北京字节跳动网络技术有限公司 Method and device for synthesizing video file, mobile terminal and storage medium
CN111355978B (en) * 2018-12-21 2022-09-06 北京字节跳动网络技术有限公司 Video file processing method and device, mobile terminal and storage medium
CN109640116B (en) * 2018-12-24 2020-09-11 广州微算互联信息技术有限公司 Cloud mobile phone network video coding method and server
CN109862409B (en) * 2019-03-18 2021-03-26 广州市网星信息技术有限公司 Video decoding method, video playing method, device, system, terminal and storage medium
CN111757168B (en) * 2019-03-29 2022-08-19 腾讯科技(深圳)有限公司 Audio decoding method, device, storage medium and equipment
CN111953991B (en) * 2020-08-07 2022-05-20 山东金东数字创意股份有限公司 System and method for accelerating decoding of video CPU + GPU hardware based on windows platform
CN112165623A (en) * 2020-09-30 2021-01-01 广州光锥元信息科技有限公司 Soft and hard combined audio and video coding and decoding device
CN112422963B (en) * 2020-11-17 2024-05-31 杭州雾联科技有限公司 Cloud computer system, encoding method, encoding device, cloud computer equipment and storage medium
CN114640862A (en) * 2020-12-16 2022-06-17 西安诺瓦星云科技股份有限公司 Video processing method, device, computer readable storage medium and processor
CN113066140A (en) * 2021-03-29 2021-07-02 广州虎牙科技有限公司 Image encoding method, image encoding device, computer device, and storage medium
CN114071154A (en) * 2021-11-10 2022-02-18 湖南国科微电子股份有限公司 Data decoding method and device, electronic equipment and readable storage medium
CN115065824B (en) * 2022-08-18 2023-02-24 荣耀终端有限公司 Decoder determination method, device, chip, electronic equipment and medium
CN117235549B (en) * 2023-11-15 2024-06-04 军事科学院***工程研究院***总体研究所 Unmanned aerial vehicle anomaly detection method based on memory enhancement self-encoder integrated structure

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104185062B (en) * 2013-05-27 2018-11-09 南京中兴新软件有限责任公司 A kind of method and terminal of terminal processes video flowing
CN105872755A (en) * 2015-12-07 2016-08-17 乐视云计算有限公司 Video playing method and device

Also Published As

Publication number Publication date
CN108282164A (en) 2018-07-13

Similar Documents

Publication Publication Date Title
CN108282164B (en) Data encoding and decoding method and device
RU2011142767A (en) SYSTEM AND METHOD OF VIDEO COMPRESSION USING FEEDBACK, INCLUDING DATA CONNECTED TO SUCCESSFUL RECEPTION OF VIDEO CONTENT
CN110430441B (en) Cloud mobile phone video acquisition method, system, device and storage medium
RU2011142771A (en) SYSTEM AND METHOD OF VIDEO COMPRESSION BASED ON MEASUREMENTS OF WAITING TIME AND OTHER FEEDBACK
NZ595843A (en) System and method for multi-stream video compression using multiple encoding formats
JP2012521721A5 (en)
US10976986B2 (en) System and method for forwarding an application user interface
CN109309842B (en) Live broadcast data processing method and device, computer equipment and storage medium
JP2012521718A5 (en)
WO2018040427A1 (en) Screen interface sharing method and system
CN111669577A (en) Hardware decoding detection method and device, electronic equipment and storage medium
CN109525559B (en) Picture sharing method and system
CN108235075B (en) Video quality grade matching method, computer readable storage medium and terminal
US11196868B2 (en) Audio data processing method, server, client and server, and storage medium
CN109525852B (en) Live video stream processing method, device and system and computer readable storage medium
US10015395B2 (en) Communication system, communication apparatus, communication method and program
CN116450149B (en) Hardware decoding method, device and storage medium
EP2851797A2 (en) System and method for forwarding an application user interface
WO2023024832A1 (en) Data processing method and apparatus, computer device and storage medium
WO2021097892A1 (en) Translation system, translation method, translation machine, and storage medium
US8127044B2 (en) Method for the delivery of audio and video data sequences by a server
CN115988269A (en) Video playing method, device, system, electronic equipment and storage medium
CN112422961A (en) Data transmission method and device, display equipment and computer readable storage medium
WO2016154816A1 (en) Data processing method and device
CN106604117A (en) Screen mirroring method and system

Legal Events

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