[go: up one dir, main page]

CN111757120A - Data decoding method, electronic equipment and machine-readable storage medium - Google Patents

Data decoding method, electronic equipment and machine-readable storage medium Download PDF

Info

Publication number
CN111757120A
CN111757120A CN202010575146.4A CN202010575146A CN111757120A CN 111757120 A CN111757120 A CN 111757120A CN 202010575146 A CN202010575146 A CN 202010575146A CN 111757120 A CN111757120 A CN 111757120A
Authority
CN
China
Prior art keywords
media data
streaming media
main processor
coprocessor
code stream
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
CN202010575146.4A
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.)
Hangzhou Hikvision Digital Technology Co Ltd
Original Assignee
Hangzhou Hikvision Digital 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 Hangzhou Hikvision Digital Technology Co Ltd filed Critical Hangzhou Hikvision Digital Technology Co Ltd
Priority to CN202010575146.4A priority Critical patent/CN111757120A/en
Publication of CN111757120A publication Critical patent/CN111757120A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/44Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/2624Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects for obtaining an image which is composed of whole input images, e.g. splitscreen
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/268Signal distribution or switching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/76Television signal recording
    • H04N5/765Interface circuits between an apparatus for recording and another apparatus

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The embodiment of the invention provides a data decoding method, electronic equipment and a machine-readable storage medium, wherein the data decoding method is applied to the electronic equipment, the electronic equipment comprises a main processor and a coprocessor, and the main processor acquires streaming media data and code stream attribute parameters of the streaming media data; and sending the streaming media data and the code stream attribute parameters to the coprocessor, wherein the code stream attribute parameters represent the coding and decoding characteristics of the streaming media data, so that after receiving the streaming media data and the code stream attribute parameters, the coprocessor can correspondingly configure a decoder according to the code stream attribute parameters, and the configured decoder is used for decoding the streaming media data. The coprocessor configures the decoder correspondingly according to the code stream attribute parameters, the decoder can decode the stream media data adaptively, the application range of the electronic equipment for data decoding is wider, and the data decoding performance of the electronic equipment is enhanced.

Description

Data decoding method, electronic equipment and machine-readable storage medium
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data decoding method, an electronic device, and a machine-readable storage medium.
Background
With the continuous development of computer technology, people's demands for remote work and learning become more and more common, and it is desired to display remote streaming media data such as video, audio, document data and the like on local electronic equipment, so how to implement streaming media data sharing becomes a key for implementing remote work and learning. One electronic device acquires the streaming media data of the other electronic device through network transmission, external storage device copy and other modes, and locally displays the acquired streaming media data, so that the streaming media data is shared.
The streaming media data acquired by the electronic device is often encoded streaming media data, and the streaming media data can be normally displayed only after being decoded. However, in practical applications, the format of the streaming media data and the specified codec mode are predefined between the electronic devices, that is, the codec mode of the electronic devices is generally fixed, and only the streaming media data with a specific format can be decoded, which results in poor data decoding performance of the electronic devices.
Disclosure of Invention
An object of an embodiment of the present invention is to provide a data decoding method, an electronic device, and a machine-readable storage medium, so as to enhance data decoding performance of the electronic device. The specific technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides a data decoding method, which is applied to an electronic device, where the electronic device includes a main processor and a coprocessor, and the method includes:
the main processor acquires streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
the coprocessor receives streaming media data and code stream attribute parameters sent by a main processor; configuring a decoder according to the code stream attribute parameters; the streaming media data is decoded with a decoder.
Optionally, the step of acquiring, by the main processor, the streaming media data and the stream attribute parameter of the streaming media data includes:
the main processor obtains streaming media data input by an application program when the application program calls a media playing interface and generated code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
Optionally, the main processor and the coprocessor are connected through a network;
the main processor sends the streaming media data and the code stream attribute parameters to the coprocessor, and the steps comprise:
the main processor packages the streaming media data and the code stream attribute parameters to obtain a packaged data packet; sending the data packet to a coprocessor through a network according to a preset network protocol;
the step that the coprocessor receives the streaming media data and the code stream attribute parameters sent by the main processor comprises the following steps:
the coprocessor receives a data packet sent by a main processor; and decapsulating the data packet to obtain streaming media data and a code stream attribute parameter.
Optionally, the electronic device further comprises a display screen;
after the step of the coprocessor decoding the streaming media data with the decoder, the method further comprises:
the coprocessor sends the decoded streaming media data to a main processor;
and the main processor displays the received decoded streaming media data on a display screen.
Optionally, the main processor is connected with the coprocessor through a multimedia interface;
the step that the coprocessor sends the decoded streaming media data to the main processor comprises the following steps:
the coprocessor sends the decoded streaming media data to a main processor in the form of a multimedia signal through a multimedia interface;
the step that the main processor displays the received decoded streaming media data on a display screen comprises the following steps:
and the main processor displays the received multimedia signal on a display screen.
Optionally, the streaming media data includes multiple paths of streaming media data;
the method for decoding the streaming media data by the coprocessor comprises the following steps of:
the coprocessor utilizes a decoder to decode each path of streaming media data respectively; and splicing the decoded streaming media data according to a preset splicing mode.
In a second aspect, an embodiment of the present invention provides an electronic device, which includes a main processor, a coprocessor, and at least one machine-readable storage medium;
a machine-readable storage medium stores machine-executable instructions executable by a host processor and/or a coprocessor;
the main processor is caused by machine executable instructions to perform the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
the coprocessor is caused by machine executable instructions to implement the steps of: receiving streaming media data and code stream attribute parameters sent by a main processor; configuring a decoder according to the code stream attribute parameters; the streaming media data is decoded with a decoder.
Optionally, when the main processor implements the step of obtaining the streaming media data and the code stream attribute parameter of the streaming media data, the following is specifically implemented: the method comprises the steps of obtaining streaming media data input by an application program when a media playing interface is called and generating code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
Optionally, the main processor and the coprocessor are connected through a network;
when the main processor realizes the step of sending the streaming media data and the code stream attribute parameters to the coprocessor, the method specifically realizes that: packaging the streaming media data and the code stream attribute parameters to obtain a packaged data packet; sending the data packet to a coprocessor through a network according to a preset network protocol;
when the coprocessor realizes the step of receiving the streaming media data and the code stream attribute parameters sent by the main processor, the following steps are specifically realized: the coprocessor receives a data packet sent by a main processor; and decapsulating the data packet to obtain streaming media data and a code stream attribute parameter.
Optionally, the electronic device further comprises a display screen;
the coprocessor, caused by the machine executable instructions, further implements the steps of: sending the decoded streaming media data to a main processor;
the main processor is caused by machine executable instructions to perform the further steps of: and displaying the received decoded streaming media data on a display screen.
Optionally, the main processor is connected with the coprocessor through a multimedia interface;
when the coprocessor implements the step of sending the decoded streaming media data to the main processor, the following is specifically implemented: sending the decoded streaming media data to a main processor in the form of a multimedia signal through a multimedia interface;
when the main processor realizes the step of displaying the received decoded streaming media data on a display screen, the following steps are specifically realized: and displaying the received multimedia signal on a display screen.
Optionally, the streaming media data includes multiple paths of streaming media data;
when the coprocessor implements the step of decoding the streaming media data by using the decoder, the following is specifically implemented: decoding each path of streaming media data by using a decoder; and splicing the decoded streaming media data according to a preset splicing mode.
In a third aspect, embodiments of the present invention provide a machine-readable storage medium having stored therein machine-executable instructions executable by a host processor and/or a coprocessor;
the machine executable instructions, when executed by the host processor, perform the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
when executed by the coprocessor, the machine-executable instructions implement the steps of: receiving streaming media data and code stream attribute parameters sent by a main processor; configuring a decoder according to the code stream attribute parameters; the streaming media data is decoded with a decoder.
Embodiments of the present invention also provide a computer program product containing instructions, which when run on a computer, cause the computer to execute the data decoding method provided in the first aspect.
The embodiment of the invention has the following beneficial effects:
the embodiment of the invention provides a data decoding method, electronic equipment and a machine-readable storage medium, wherein the data decoding method is applied to the electronic equipment, the electronic equipment comprises a main processor and a coprocessor, and the main processor acquires streaming media data and code stream attribute parameters of the streaming media data; and sending the streaming media data and the code stream attribute parameters to the coprocessor, wherein the code stream attribute parameters represent the coding and decoding characteristics of the streaming media data, so that after receiving the streaming media data and the code stream attribute parameters, the coprocessor can correspondingly configure a decoder according to the code stream attribute parameters, and the configured decoder is used for decoding the streaming media data. The coprocessor correspondingly configures the decoder according to the code stream attribute parameters after receiving the stream media data and the code stream attribute parameters of the stream media data, and the configured decoder can adaptively decode the received stream media data.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a flowchart illustrating a data decoding method according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating a data decoding method according to another embodiment of the present invention;
FIG. 3 is a flowchart illustrating a data decoding method according to another embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the 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 invention.
In order to enhance the data decoding performance of the electronic device, the embodiment of the invention provides a data decoding method, the electronic device and a machine-readable storage medium. Next, a data decoding method provided in an embodiment of the present invention will be described first. The method is applied to electronic equipment, and the electronic equipment can be display equipment with a display function, such as a television, a conference panel and the like, and can also be hardware equipment with core processing capability, such as a personal computer, a server and the like. The electronic equipment comprises a main processor and a coprocessor, wherein the main processor mainly provides core processing functions of the electronic equipment, such as target identification, data operation, control and the like, and the coprocessor mainly provides a streaming media data decoding function. The data decoding method provided by the embodiment of the invention is specifically realized by the interaction of a main processor and a coprocessor in the electronic equipment.
As shown in fig. 1, a data decoding method provided by an embodiment of the present invention may include the following steps.
S101, the main processor 10 obtains streaming media data and a stream attribute parameter of the streaming media data.
The code stream attribute parameters represent the coding and decoding characteristics of the stream media data.
S102, the main processor 10 sends the streaming media data and the stream attribute parameter to the coprocessor 20.
And S103, the coprocessor 20 configures a decoder according to the code stream attribute parameters, and decodes the streaming media data by using the decoder.
By applying the embodiment of the invention, the main processor acquires the streaming media data and the code stream attribute parameters of the streaming media data; and sending the streaming media data and the code stream attribute parameters to the coprocessor, wherein the code stream attribute parameters represent the coding and decoding characteristics of the streaming media data, so that after receiving the streaming media data and the code stream attribute parameters, the coprocessor can correspondingly configure a decoder according to the code stream attribute parameters, and the configured decoder is used for decoding the streaming media data. The coprocessor correspondingly configures the decoder according to the code stream attribute parameters after receiving the stream media data and the code stream attribute parameters of the stream media data, and the configured decoder can adaptively decode the received stream media data.
As a main processor providing a core processing function of an electronic device, when streaming media data that needs to be locally displayed by the electronic device exists, the main processor may first acquire the streaming media data, and since the streaming media data may be transmitted from another electronic device or copied from an external memory, the streaming media data may be acquired by the main processor through a transmission interface between the electronic device and another electronic device, or acquired by the processor from an external memory connected to the electronic device. When the streaming media data is acquired, the code stream attribute parameters of the streaming media data can be acquired, and the code stream attribute parameters represent the encoding and decoding characteristics of the streaming media data, that is, the code stream attribute parameters stipulate the relevant information of how to encode and decode the streaming media data. The code stream attribute parameter may be carried in the streaming media data, or may be obtained by analyzing the streaming media data after the streaming media data is obtained.
Optionally, S101 may specifically be: the main processor 10 obtains streaming media data input by an application program when calling a media playing interface and generated code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
Generally, a user of an electronic device may check streaming media data by running a third party APP (Application, Application program) such as a cloud conference, a cloud study, and the like, and when the third party APP is run, input streaming media data to be checked, the APP may call a media playing interface (for example, a MediaPlayer interface of an Android system), and the media playing interface is a standard decoding interface of an operating system of the electronic device, and can provide a playing service for the streaming media data, and a decoding mode of the streaming media data is agreed. The media playing interface can analyze the corresponding code stream attribute parameters according to the format of the stream media data. Therefore, the main processor can intercept the streaming media data and the code stream attribute parameters from the media playing interface when the application program calls the media playing interface. The main processing may obtain, in addition to the stream attribute parameters of the streaming media data, pre-configured decoding-related parameters such as decoder initialization parameters and display parameters. The codestream attribute parameters, decoder initialization parameters, display parameters, etc. may be sent to the co-processor together.
Therefore, in the embodiment of the invention, the electronic device does not need to make special limitation on the third party APP, does not require that the third party APP can only run the streaming media data in the fixed format, and can call the standard media playing interface from the third party APP, and the adaptive decoding operation is realized by the self-defined co-processing mode of the electronic device, so that the non-inductive adaptation to the third party APP can be realized.
After acquiring the streaming media data and the code stream attribute parameters, the main processor sends the streaming media data and the code stream attribute parameters to the coprocessor and the coprocessor decodes the streaming media data and the code stream attribute parameters. After the coprocessor receives the streaming media data and the code stream attribute parameters, the code stream attribute parameters represent the coding and decoding characteristics of the streaming media data, so that a decoder can be correspondingly configured according to the code stream attribute parameters, and the configured decoder can decode the streaming media data in a targeted manner, so that the decoder is more flexible, and therefore, the electronic equipment can decode the streaming media data in different formats adaptively, and the data decoding performance of the electronic equipment is improved.
Optionally, the main processor 10 and the coprocessor 20 are connected via a network.
Correspondingly, S102 may specifically be: the main processor 10 encapsulates the streaming media data and the code stream attribute parameters to obtain an encapsulated data packet; the data packet is sent to the coprocessor 20 via the network according to a predetermined network protocol.
The coprocessor 20 decapsulates the data packet after receiving the data packet sent by the main processor 10, and thus obtains the streaming media data and the code stream attribute parameters.
In an implementation manner of the embodiment of the present invention, the main processor and the coprocessor may be connected via a network, and accordingly, the main processor needs to encapsulate the streaming media data and the attribute parameters of the code stream before sending the streaming media data and the attribute parameters of the code stream, generally, data encapsulation is performed based on a network Protocol, for example, the main processor and the coprocessor are connected via a network that satisfies Transmission Control Protocol (TCP)/Internet Protocol (IP), when performing data encapsulation, encapsulation is performed according to the TCP/IP requirement, and accordingly, when receiving a data packet sent by the main processor, the coprocessor decapsulates the data packet, so as to obtain the streaming media data and the attribute parameters of the code stream, and a specific decapsulating process is also determined according to a format requirement of a specific network Protocol, and will not be described in detail herein.
The main processor 10 and the coprocessor 20 may be connected through a USB, a serial port, or the like, in addition to the above network connection, which is not described in detail herein.
Optionally, the streaming media data is multiple paths of streaming media data.
Correspondingly, the step of decoding, by the coprocessor 20 in S103, the streaming media data by using a decoder may specifically be: the coprocessor 20 decodes each path of streaming media data by using a decoder; and splicing the decoded streaming media data according to a preset splicing mode.
The coprocessor may provide multi-channel decoding, that is, the input streaming media data may be multi-channel streaming media data, for example, in some scenarios, cameras are deployed at different positions, and each camera may acquire a video at a different position, so that the streaming media data transmitted to the electronic device may be multi-channel, the coprocessor may decode each channel of streaming media data separately using a decoder, and the decoding of each channel of streaming media data may be performed synchronously or asynchronously. In addition, one decoder may decode each path of streaming media data, or a plurality of decoders having the same structure may decode each path of streaming media data, respectively, and this is not particularly limited. Because the multiple paths of streaming media data are stored and displayed respectively, the storage and display are not convenient for a user to check, and for the convenience of the user to check, the coprocessor can splice the decoded multiple paths of streaming media data according to a preset splicing mode.
After the coprocessor obtains the decoded streaming media data, the streaming media data can be stored locally or in a storage medium of the electronic device, and the coprocessor waits for a main processor or other units to obtain the streaming media data when necessary. Of course, in an implementation manner, after obtaining the decoded streaming media data, the coprocessor may directly send the obtained streaming media data to the main processor, and the main processor performs processing such as storage and display.
Based on the embodiment shown in fig. 1, an embodiment of the present invention further provides a data decoding method, which is applied to an electronic device that includes a main processor 10, a coprocessor 20 and a display screen 30, and as shown in fig. 2, the following steps may be included.
S201, the main processor 10 obtains the streaming media data and the stream attribute parameter of the streaming media data.
The code stream attribute parameters represent the coding and decoding characteristics of the stream media data.
S202, the main processor 10 sends the streaming media data and the stream attribute parameter to the coprocessor 20.
S203, the coprocessor 20 configures a decoder according to the bit stream attribute parameter, and decodes the streaming media data by using the decoder.
S204, the coprocessor 20 sends the decoded streaming media data to the main processor 10.
S205, the main processor 10 displays the decoded streaming media data on the display screen 30.
In the embodiment of the invention, the electronic equipment processing comprises a main processor, a coprocessor and a display screen, wherein the display screen is used for displaying the streaming media data. The display function of the display screen is specifically controlled by the main processor, so that after the coprocessor obtains the decoded streaming media data, the decoded streaming media data can be sent to the main processor, the main processor controls the display screen to display the decoded streaming media data, the specific display control process can be that the decoded streaming media data is sent to the display screen in a display driving instruction mode, and the display screen displays the decoded streaming media data according to the display driving instruction.
Optionally, the main processor 10 is connected to the coprocessor 20 via a multimedia interface.
S204 may specifically be: the coprocessor 20 transmits the decoded streaming media data to the main processor 10 in the form of a multimedia signal through a multimedia interface.
S205 may specifically be: the main processor 10 displays the received multimedia signal on a display screen.
A conventional way to insert and lose streaming media data between a main processor and a coprocessor is that the coprocessor stores decoded streaming media data into a specified storage medium (e.g., a Dynamic Random Access Memory (DRAM)) of an electronic device, and the main processor reads the streaming media data from the specified storage medium. It can be seen that this way of interaction between processors is complex. In an implementation manner of the embodiment of the present invention, the main processor and the coprocessor are connected through a Multimedia Interface, for example, through an HDMI (High Definition Multimedia Interface), so that the coprocessor can directly send decoded streaming media data to the main processor through the Multimedia Interface in the form of a Multimedia signal, and the main processor can directly display the received Multimedia signal on the display screen.
As shown in fig. 3, a specific process of an electronic device implementing a data decoding method is provided, where the electronic device runs an Android system, and in a running process of a third-party APP, a MediaPlayer interface of the Android system is called, and a main processor intercepts, in the MediaPlayer interface, each code stream (including streaming media data and code stream attribute parameters) transmitted through the MediaPlayer interface, performs code stream encapsulation, and sends the encapsulated code stream to a coprocessor through a network. The coprocessor receives the code stream through the network, decapsulates the code stream to obtain multiple paths of videos, decodes each path of video according to received code stream attribute parameters to obtain multiple pictures, performs screen splitting and splicing on the multiple pictures to obtain spliced pictures, finally outputs the spliced pictures to the main processor through the HDMI, and the main processor displays the received HDMI signals on a display screen connected with the main processor.
An embodiment of the present invention further provides an electronic device, as shown in fig. 4, including a main processor 401, a coprocessor 402, and at least one machine-readable storage medium 403;
the machine-readable storage medium 403 stores machine-executable instructions executable by the main processor 401 and/or the coprocessor 402;
the main processor 401 is caused by machine executable instructions to implement the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor 402;
the coprocessor 402 is caused by machine executable instructions to perform the following steps: receiving streaming media data and a code stream attribute parameter sent by a main processor 401; configuring a decoder according to the code stream attribute parameters; the streaming media data is decoded with a decoder.
Optionally, when the main processor 401 implements the step of obtaining the streaming media data and the stream attribute parameter of the streaming media data, the following is specifically implemented: the method comprises the steps of obtaining streaming media data input by an application program when a media playing interface is called and generating code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
Optionally, the main processor 401 and the coprocessor 402 are connected via a network;
when the main processor 401 implements the step of sending the streaming media data and the code stream attribute parameters to the coprocessor 402, the following is specifically implemented: packaging the streaming media data and the code stream attribute parameters to obtain a packaged data packet; sending the data packet to the coprocessor 402 through the network according to a preset network protocol;
when the coprocessor 402 implements the step of receiving the streaming media data and the code stream attribute parameters sent by the main processor 401, the following is specifically implemented: the coprocessor 402 receives a data packet sent by the main processor 401; and decapsulating the data packet to obtain streaming media data and a code stream attribute parameter.
Optionally, the electronic device further comprises a display screen;
the coprocessor 402 is caused by machine executable instructions to perform the following steps: sending the decoded streaming media data to the main processor 401;
the main processor 401, as prompted by the machine executable instructions, further implements the steps of: and displaying the received decoded streaming media data on a display screen.
Optionally, the main processor 401 is connected to the coprocessor 402 through a multimedia interface;
when the coprocessor 402 implements the step of sending the decoded streaming media data to the main processor 401, the following is specifically implemented: sending the decoded streaming media data to the main processor 401 in the form of a multimedia signal through the multimedia interface;
when the main processor 401 implements the step of displaying the received decoded streaming media data on the display screen, the following is specifically implemented: and displaying the received multimedia signal on a display screen.
Optionally, the streaming media data includes multiple paths of streaming media data;
when the coprocessor 402 implements the step of decoding the streaming media data by using the decoder, the following is specifically implemented: decoding each path of streaming media data by using a decoder; and splicing the decoded streaming media data according to a preset splicing mode.
The Memory may include a RAM (Random Access Memory) or an NVM (Non-volatile Memory), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field-Programmable Gate Array) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component.
The memory 403 may be connected with the main processor 401 and the coprocessor 402 by a wired or wireless connection, and the electronic device may communicate with other devices by a wired or wireless communication interface. Fig. 4 is only an example of data transmission through the bus, and the connection method is not limited to a specific connection method.
By applying the embodiment of the invention, the main processor acquires the streaming media data and the code stream attribute parameters of the streaming media data; and sending the streaming media data and the code stream attribute parameters to the coprocessor, wherein the code stream attribute parameters represent the coding and decoding characteristics of the streaming media data, so that after receiving the streaming media data and the code stream attribute parameters, the coprocessor can correspondingly configure a decoder according to the code stream attribute parameters, and the configured decoder is used for decoding the streaming media data. The coprocessor correspondingly configures the decoder according to the code stream attribute parameters after receiving the stream media data and the code stream attribute parameters corresponding to the stream media data, and the configured decoder can adaptively decode the received stream media data.
Additionally, embodiments of the present invention provide a machine-readable storage medium having stored therein machine-executable instructions executable by a host processor and/or a coprocessor;
the machine executable instructions, when executed by the host processor, perform the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
when executed by the coprocessor, the machine-executable instructions implement the steps of: receiving streaming media data and code stream attribute parameters sent by a main processor; configuring a decoder according to the code stream attribute parameters; the streaming media data is decoded with a decoder.
By applying the embodiment of the invention, the main processor acquires the streaming media data and the code stream attribute parameters of the streaming media data; and the coprocessor can correspondingly configure the decoder according to the code stream attribute parameters after receiving the streaming media data and the code stream attribute parameters, and the configured decoder is used for decoding the streaming media data. The coprocessor correspondingly configures the decoder according to the code stream attribute parameters after receiving the stream media data and the code stream attribute parameters corresponding to the stream media data, and the configured decoder can adaptively decode the received stream media data.
In a further embodiment provided by the embodiments of the present invention, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform any of the above-mentioned data decoding methods.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the application to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored on a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website, computer, server, or data center to another website, computer, server, or data center via wire (e.g., coaxial cable, fiber, DSL (Digital Subscriber Line)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., a floppy Disk, a hard Disk, a magnetic tape), an optical medium (e.g., a DVD (digital versatile Disk)), or a semiconductor medium (e.g., an SSD (Solid State Disk)), etc.
It is 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.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the electronic device, the machine-readable storage medium, and the computer program product embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and in relation to the description, reference may be made to some portions of the description of the method embodiments.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (13)

1. A method of decoding data for use in an electronic device, the electronic device including a main processor and a co-processor, the method comprising:
the main processor acquires streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
the coprocessor receives the streaming media data and the code stream attribute parameters sent by the main processor; configuring a decoder according to the code stream attribute parameters; decoding the streaming media data with the decoder.
2. The method of claim 1, wherein the obtaining, by the main processor, streaming media data and codestream attribute parameters of the streaming media data comprises:
the main processor obtains streaming media data input by an application program when calling a media playing interface and generated code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
3. The method of claim 1, wherein the host processor and the coprocessor are connected via a network;
the main processor sends the streaming media data and the code stream attribute parameters to the coprocessor, and the method comprises the following steps:
the main processor packages the streaming media data and the code stream attribute parameters to obtain a packaged data packet; according to a preset network protocol, the data packet is sent to the coprocessor through the network;
the coprocessor receives the streaming media data and the code stream attribute parameters sent by the main processor, and the method comprises the following steps:
the coprocessor receives the data packet sent by the main processor; and decapsulating the data packet to obtain the streaming media data and the code stream attribute parameters.
4. The method of claim 1, wherein the electronic device further comprises a display screen;
after the co-processor decodes the streaming media data with the decoder, the method further comprises:
the coprocessor sends the decoded streaming media data to the main processor;
and the main processor displays the received decoded streaming media data on the display screen.
5. The method of claim 4, wherein the host processor is connected to the coprocessor via a multimedia interface;
the coprocessor sends the decoded streaming media data to the main processor, and the method comprises the following steps:
the coprocessor sends the decoded streaming media data to the main processor in the form of multimedia signals through the multimedia interface;
the main processor displays the received decoded streaming media data on the display screen, and the method comprises the following steps:
and the main processor displays the received multimedia signal on the display screen.
6. The method of claim 1, wherein the streaming media data comprises multiple paths of streaming media data;
the coprocessor utilizes the decoder to decode the streaming media data, and comprises:
the coprocessor respectively decodes each path of streaming media data by using the decoder; and splicing the decoded streaming media data according to a preset splicing mode.
7. An electronic device comprising a main processor, a co-processor, and at least one machine-readable storage medium;
the machine-readable storage medium stores machine-executable instructions executable by the main processor and/or the coprocessor;
the main processor is caused by machine executable instructions to perform the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
the co-processor is caused by machine executable instructions to perform the steps of: receiving the streaming media data and the code stream attribute parameters sent by the main processor; configuring a decoder according to the code stream attribute parameters; decoding the streaming media data with the decoder.
8. The electronic device according to claim 7, wherein the main processor, when implementing the acquiring of the streaming media data and the stream attribute parameter of the streaming media data, implements: the method comprises the steps of obtaining streaming media data input by an application program when a media playing interface is called and generating code stream attribute parameters, wherein the media playing interface is used for providing playing service for the streaming media data.
9. The electronic device of claim 7, wherein the main processor and the coprocessor are connected via a network;
when the main processor sends the streaming media data and the code stream attribute parameters to the coprocessor, the following steps are specifically realized: packaging the streaming media data and the code stream attribute parameters to obtain a packaged data packet; according to a preset network protocol, the data packet is sent to the coprocessor through the network;
when the coprocessor receives the streaming media data and the code stream attribute parameters sent by the main processor, the following steps are specifically realized: receiving the data packet sent by the main processor; and decapsulating the data packet to obtain the streaming media data and the code stream attribute parameters.
10. The electronic device of claim 7, further comprising a display screen;
the co-processor, as caused by the machine executable instructions, further implements the steps of: sending the decoded streaming media data to the main processor;
the main processor, caused by machine executable instructions, further implements the steps of: and displaying the received decoded streaming media data on the display screen.
11. The electronic device of claim 10, wherein the main processor is coupled to the coprocessor via a multimedia interface;
when the coprocessor sends the decoded streaming media data to the main processor, the following specific implementation is implemented: sending the decoded streaming media data to the main processor in the form of a multimedia signal through the multimedia interface;
when the main processor displays the received decoded streaming media data on the display screen, the following steps are specifically implemented: and displaying the received multimedia signal on the display screen.
12. The electronic device of claim 7, wherein the streaming media data comprises multiple paths of streaming media data;
when the coprocessor decodes the streaming media data by using the decoder, the following specific implementation is implemented: decoding each path of streaming media data by using the decoder; and splicing the decoded streaming media data according to a preset splicing mode.
13. A machine-readable storage medium having stored therein machine-executable instructions executable by a host processor and/or a coprocessor;
the machine executable instructions, when executed by the main processor, implement the steps of: acquiring streaming media data and a code stream attribute parameter of the streaming media data, wherein the code stream attribute parameter represents the coding and decoding characteristics of the streaming media data; sending the streaming media data and the code stream attribute parameters to the coprocessor;
the machine executable instructions, when executed by the coprocessor, implement the steps of: receiving the streaming media data and the code stream attribute parameters sent by the main processor; configuring a decoder according to the code stream attribute parameters; decoding the streaming media data with the decoder.
CN202010575146.4A 2020-06-22 2020-06-22 Data decoding method, electronic equipment and machine-readable storage medium Pending CN111757120A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010575146.4A CN111757120A (en) 2020-06-22 2020-06-22 Data decoding method, electronic equipment and machine-readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010575146.4A CN111757120A (en) 2020-06-22 2020-06-22 Data decoding method, electronic equipment and machine-readable storage medium

Publications (1)

Publication Number Publication Date
CN111757120A true CN111757120A (en) 2020-10-09

Family

ID=72675684

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010575146.4A Pending CN111757120A (en) 2020-06-22 2020-06-22 Data decoding method, electronic equipment and machine-readable storage medium

Country Status (1)

Country Link
CN (1) CN111757120A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113676769A (en) * 2021-08-23 2021-11-19 北京字跳网络技术有限公司 Video decoding method, device, storage medium and program product

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130188739A1 (en) * 2012-01-25 2013-07-25 Onecodec, Ltd. Systems and methods for encoding, sharing, and decoding of multimedia
CN105959797A (en) * 2016-05-25 2016-09-21 青岛海信电器股份有限公司 Video decoding method and digital TV
CN108881918A (en) * 2017-11-29 2018-11-23 北京视联动力国际信息技术有限公司 A kind of processing method of multi-channel video and a kind of multimedia terminal
CN109889894A (en) * 2019-03-13 2019-06-14 苏州科达科技股份有限公司 Media file coding/decoding method, device and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130188739A1 (en) * 2012-01-25 2013-07-25 Onecodec, Ltd. Systems and methods for encoding, sharing, and decoding of multimedia
CN105959797A (en) * 2016-05-25 2016-09-21 青岛海信电器股份有限公司 Video decoding method and digital TV
CN108881918A (en) * 2017-11-29 2018-11-23 北京视联动力国际信息技术有限公司 A kind of processing method of multi-channel video and a kind of multimedia terminal
CN109889894A (en) * 2019-03-13 2019-06-14 苏州科达科技股份有限公司 Media file coding/decoding method, device and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113676769A (en) * 2021-08-23 2021-11-19 北京字跳网络技术有限公司 Video decoding method, device, storage medium and program product
CN113676769B (en) * 2021-08-23 2023-03-31 北京字跳网络技术有限公司 Video decoding method, device and storage medium

Similar Documents

Publication Publication Date Title
US11336953B2 (en) Video processing method, electronic device, and computer-readable medium
CN103475953B (en) A kind of media control method and equipment based on desktop cloud
WO2017095885A1 (en) Method and apparatus for transmitting video data
US20190028668A1 (en) System and method for streaming multimedia data
US20170195617A1 (en) Image processing method and electronic device
CN102099774A (en) Apparatus and method for providing user interface service in a multimedia system
WO2015176648A1 (en) Method and device for transmitting data in intelligent terminal to television terminal
KR20130096868A (en) Method for transmitting stream and electronic device for the method thereof
CN108965430A (en) Image acquisition method, device, computer equipment and storage medium
CN109725970A (en) The method, apparatus and electronic equipment that applications client window is shown
CN115022725B (en) Video playback method and device
CN110990109B (en) A splicing screen echo method, terminal, system and storage medium
WO2018209869A1 (en) Information sharing method and device during miracast, and storage medium
CN110582021B (en) Information processing method and device, electronic equipment and storage medium
CN104639501B (en) A kind of method of data stream transmitting, equipment and system
CN111757120A (en) Data decoding method, electronic equipment and machine-readable storage medium
US20170134454A1 (en) System for cloud streaming service, method for still image-based cloud streaming service and apparatus therefor
KR20190003729A (en) Method and apparatus for mpeg media transport integration in content distribution networks
US20180352285A1 (en) Method for providing a remote personal computer service to a digital device
CN114503569B (en) AV1 codec for real-time video communication
CN110769241B (en) Video frame processing method and device, user side and storage medium
EP3229478B1 (en) Cloud streaming service system, image cloud streaming service method using application code, and device therefor
CN104247364B (en) Video transmission method, device, and system applied to remote desktop
CN107872683B (en) Video data processing method, device, equipment and storage medium
WO2024066755A1 (en) Image display method and apparatus, and electronic device

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20201009