CN113327302A - Picture processing method and device, storage medium and electronic device - Google Patents

Picture processing method and device, storage medium and electronic device Download PDF

Info

Publication number
CN113327302A
CN113327302A CN202110579397.4A CN202110579397A CN113327302A CN 113327302 A CN113327302 A CN 113327302A CN 202110579397 A CN202110579397 A CN 202110579397A CN 113327302 A CN113327302 A CN 113327302A
Authority
CN
China
Prior art keywords
picture
data
decoded
decoding
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.)
Pending
Application number
CN202110579397.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.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua 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 Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202110579397.4A priority Critical patent/CN113327302A/en
Publication of CN113327302A publication Critical patent/CN113327302A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/20Processor architectures; Processor configuration, e.g. pipelining
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/60Memory management

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The embodiment of the invention provides a picture processing method and device, a storage medium and an electronic device, wherein the method comprises the following steps: receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding; decoding a first picture to be decoded to obtain decoded data; carrying out format conversion on the decoded data to obtain converted data; and sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data. By the method and the device, the problem that decoding of the picture in the related technology is time-consuming is solved, and the effect of improving the picture guiding speed is achieved.

Description

Picture processing method and device, storage medium and electronic device
Technical Field
The embodiment of the invention relates to the field of image processing, in particular to a picture processing method and device, a storage medium and an electronic device.
Background
Currently storage IVSS/EVS products use a Master + Smart daughter card configuration. The intelligent daughter card receives data of the master through media such as a Peripheral Component Interconnect Express (PCIE)/network/Universal Serial Bus (USB), and then analyzes the data and reports an intelligent result to the master. In the face recognition intelligent function, a user needs to lead in a picture to establish a target base library, and then the target in the video stream can be automatically recognized intelligently and compared with the target in the target base library. Currently, the IVSS equipment already supports 50 million face base libraries, which means that a user can import 50 million face pictures (in a format of jpg/png and the like) at one time, and the daughter card models the pictures and then inserts the pictures into the comparison base library.
However, the main picture of the current face library imported picture modeling scheme is only responsible for picture issuing, and picture decoding and algorithm modeling are all completed by the intelligent daughter card. At present, because the hardware decoder of a System on a Chip (SOC) supports limited picture types, only the JPG picture of YUV color System which is the most basic color coding method is supported, and other image file format JPG format of CMYK, Portable Network Graphics (PNG) picture format, and the like are not supported. The unsupported picture needs to use soft solution, but the picture software decoding consumes a Central Processing Unit (CPU), the performance of the CPU of the ARM architecture of the SOC is not strong, the occupancy rate of the CPU of the daughter card is not low, and the decoding speed is slow, so that the picture software decoding becomes a short board for the guide map modeling data stream.
In view of the above technical problems, no effective solution has been proposed in the related art.
Disclosure of Invention
The embodiment of the invention provides a picture processing method and device, a storage medium and an electronic device, which are used for at least solving the problem of time consumption of decoding pictures in the related art.
According to an embodiment of the present invention, there is provided a picture processing method including:
receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding;
decoding a first picture to be decoded to obtain decoded data;
carrying out format conversion on the decoded data to obtain converted data;
and sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to a sub-card device, and the sub-card device is used for performing hardware decoding on the coded data.
According to another embodiment of the present invention, there is provided a picture processing method including: receiving conversion data sent by a CPU, wherein the conversion data is used for indicating format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding; carrying out hardware coding on the converted data to obtain coded data; and sending the coded data to a daughter card device to instruct the daughter card device to perform hardware decoding on the coded data.
According to another embodiment of the present invention, there is provided a picture processing method including: receiving encoded data sent by a GPU, wherein the encoded data is used for representing hardware coding of the GPU on converted data, the converted data is used for representing format conversion after a CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding; and carrying out hardware decoding on the coded data.
According to still another embodiment of the present invention, there is also provided a picture processing apparatus including: the first receiving module is used for receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding; the first decoding module is used for decoding the first picture to be decoded to obtain decoded data; the first conversion module is used for carrying out format conversion on the decoded data to obtain conversion data; the first sending module is used for sending the conversion data to an image processor GPU so as to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to a sub-card device, and the sub-card device is used for performing hardware decoding on the coded data.
In an exemplary embodiment, the first decoding module includes:
a first determining unit, configured to determine a format flag of the first to-be-decoded picture to determine a picture format of the first to-be-decoded picture; a second determining unit, configured to determine, from a picture soft decoding library, a target picture soft decoding corresponding to the picture format; a first decoding unit, configured to decode the first to-be-decoded picture by using the target picture soft decoding, so as to obtain the decoded data.
In an exemplary embodiment, the first conversion module includes: a third determining unit configured to determine pixel data in the decoded data; and the first conversion unit is used for converting the format of the pixel data into a color coding format to obtain the conversion data.
According to still another embodiment of the present invention, there is also provided a picture processing apparatus including: the second receiving module is used for receiving conversion data sent by the CPU, wherein the conversion data is used for indicating format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding; the first coding module is used for carrying out hardware coding on the converted data to obtain coded data; and the second sending module is used for sending the coded data to the daughter card equipment so as to instruct the daughter card equipment to perform hardware decoding on the coded data.
In an exemplary embodiment, the first encoding module includes: and a first encoding unit, configured to perform hardware encoding in a JPG format on the converted data to obtain the encoded data.
In an exemplary embodiment, the second sending module includes: a first storing unit, configured to store the encoded data in a queue to be sent; and the first sending unit is used for sending the coded data to the daughter card equipment in the queue to be sent.
According to still another embodiment of the present invention, there is also provided a picture processing apparatus including: a third receiving module, configured to receive encoded data sent by a GPU, where the encoded data is used to indicate hardware encoding performed by the GPU on conversion data, the conversion data is used to indicate format conversion performed by a CPU after decoding a first to-be-decoded picture, and a picture format of the first to-be-decoded picture does not support hardware decoding; and the second decoding module is used for carrying out hardware decoding on the coded data.
In an exemplary embodiment, the apparatus further includes: the fourth receiving module is used for receiving a second picture to be decoded sent by the main card device, wherein the second picture to be decoded supports hardware decoding; and the third decoding module is used for decoding the second picture to be decoded by utilizing hardware equipment.
According to a further embodiment of the present invention, there is also provided a computer-readable storage medium having a computer program stored thereon, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
According to yet another embodiment of the present invention, there is also provided an electronic device, including a memory in which a computer program is stored and a processor configured to execute the computer program to perform the steps in any of the above method embodiments.
According to the invention, a first picture to be decoded is received, wherein the picture format of the first picture to be decoded does not support hardware decoding; decoding a first picture to be decoded to obtain decoded data; carrying out format conversion on the decoded data to obtain converted data; and sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to a sub-card device, and the sub-card device is used for performing hardware decoding on the coded data. The picture format identification of the master slice is utilized, the slave slices do not support the parallel transcoding of the pictures in the hardware decoding format, and the transcoded pictures are sent to the daughter cards, so that the daughter cards completely use hardware for decoding. Therefore, the problem that decoding of the pictures in the related technology is time-consuming can be solved, and the effect of improving the picture guide speed is achieved.
Drawings
Fig. 1 is a block diagram of a hardware structure of a mobile terminal of a picture processing method according to an embodiment of the present invention;
FIG. 2 is a flowchart of a picture processing method according to an embodiment of the present invention;
FIG. 3 is a flow chart of a picture processing method according to an embodiment of the present invention (two);
fig. 4 is a flowchart (three) of a picture processing method according to an embodiment of the present invention;
FIG. 5 is an overall flow diagram according to a specific embodiment of the present invention;
FIG. 6 is a flow diagram of daughter card device processing according to an embodiment of the present invention;
FIG. 7 is a block diagram (one) of the structure of a picture processing apparatus according to an embodiment of the present invention;
FIG. 8 is a block diagram of the structure of a picture processing apparatus according to an embodiment of the present invention;
fig. 9 is a block diagram (iii) of the structure of a picture processing apparatus according to an embodiment of the present invention.
Detailed Description
Hereinafter, embodiments of the present invention will be described in detail with reference to the accompanying drawings in conjunction with the embodiments.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
The method embodiments provided in the embodiments of the present application may be executed in a mobile terminal, a computer terminal, or a similar computing device. Taking the operation on the mobile terminal as an example, fig. 1 is a hardware structure block diagram of the mobile terminal of a picture processing method according to an embodiment of the present invention. As shown in fig. 1, the mobile terminal may include one or more (only one shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a processing device such as a microprocessor MCU or a programmable logic device FPGA), and a memory 104 for storing data, wherein the mobile terminal may further include a transmission device 106 for communication functions and an input-output device 108. It will be understood by those skilled in the art that the structure shown in fig. 1 is only an illustration, and does not limit the structure of the mobile terminal. For example, the mobile terminal may also include more or fewer components than shown in FIG. 1, or have a different configuration than shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program and a module of an application software, such as a computer program corresponding to the picture processing method in the embodiment of the present invention, and the processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, so as to implement the method described above. The memory 104 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the mobile terminal over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used for receiving or transmitting data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a Network adapter (NIC), which can be connected to other Network devices through a base station so as to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
In the present embodiment, a picture processing method is provided, and fig. 2 is a flowchart (a) of a picture processing method according to an embodiment of the present invention, as shown in fig. 2, the flowchart includes the following steps:
step S202, receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding;
step S204, decoding a first picture to be decoded to obtain decoded data;
step S206, carrying out format conversion on the decoded data to obtain converted data;
and S208, sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to a sub-card device, and the sub-card device is used for performing hardware decoding on the coded data.
The execution subject of the above steps may be a CPU, etc., but is not limited thereto.
The present embodiments include, but are not limited to, application in a scene modeling a picture.
Receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding; decoding a first picture to be decoded to obtain decoded data; carrying out format conversion on the decoded data to obtain converted data; and sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to a sub-card device, and the sub-card device is used for performing hardware decoding on the coded data. The picture format identification of the master slice is utilized, the slave slices do not support the parallel transcoding of the pictures in the hardware decoding format, and the transcoded pictures are sent to the daughter cards, so that the daughter cards completely use hardware for decoding. Therefore, the problem that decoding of the pictures in the related technology is time-consuming can be solved, and the effect of improving the picture guide speed is achieved.
In an exemplary embodiment, decoding a first picture to be decoded, resulting in decoded data, includes:
s1, determining the format flag of the first picture to be decoded so as to determine the picture format of the first picture to be decoded;
s2, determining a target picture soft decoding corresponding to the picture format from the picture soft decoding library;
and S3, decoding the first picture to be decoded by using the target picture soft decoding to obtain decoded data.
In this embodiment, the picture soft decoding library includes a jpg soft decoding library or a PNG soft decoding library, and picture decoding is performed by the CPU.
In an exemplary embodiment, format converting the decoded data to obtain converted data includes:
s1, determining pixel data in the decoded data;
s2, the format of the pixel data is converted into a color coding format, resulting in converted data.
In this embodiment, the format of the decoded pixel data is converted into YUV by using a CPU (the daughter card device only supports YUV color system hard solution).
In the present embodiment, a picture processing method is provided, and fig. 3 is a flowchart (ii) of the picture processing method according to the embodiment of the present invention, as shown in fig. 3, the flowchart includes the following steps:
step S302, receiving conversion data sent by a CPU, wherein the conversion data is used for indicating format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
step S304, carrying out hardware coding on the converted data to obtain coded data;
step S306, the coded data are sent to the daughter card equipment so as to instruct the daughter card equipment to perform hardware decoding on the coded data.
The execution subject of the above steps may be a GPU, etc., but is not limited thereto.
The present embodiments include, but are not limited to, application in a scene modeling a picture.
Through the steps, conversion data sent by a CPU is received, wherein the conversion data is used for representing format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding; carrying out hardware coding on the conversion data to obtain coded data; and sending the coded data to a daughter card device to instruct the daughter card device to perform hardware decoding on the coded data. The picture format identification of the master slice is utilized, the slave slices do not support the parallel transcoding of the pictures in the hardware decoding format, and the transcoded pictures are sent to the daughter cards, so that the daughter cards completely use hardware for decoding. Therefore, the problem that decoding of the pictures in the related technology is time-consuming can be solved, and the effect of improving the picture guide speed is achieved.
In an exemplary embodiment, hardware encoding the converted data to obtain encoded data includes:
and S1, carrying out JPG format hardware coding on the converted data to obtain coded data.
In this embodiment, for example, an integrated graphics card (GPU) with an idle x86 chip is used for JPG hardware encoding.
In one exemplary embodiment, transmitting encoded data to a daughter card device includes:
s1, storing the coded data into a queue to be sent;
and S2, sending the coded data to the daughter card equipment in the queue to be sent.
In this embodiment, for example, the encoded JPG picture is saved in a transcoding queue to be sent.
In the present embodiment, a picture processing method is provided, and fig. 4 is a flowchart (three) of a picture processing method according to an embodiment of the present invention, and as shown in fig. 4, the flowchart includes the following steps:
step S402, receiving coded data sent by a GPU, wherein the coded data is used for representing hardware coding of the GPU on the converted data, the converted data is used for representing format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
in step S404, the encoded data is hardware decoded.
The execution subject of the above steps may be a GPU, etc., but is not limited thereto.
The present embodiments include, but are not limited to, application in a scene modeling a picture.
Through the steps, the coded data sent by the GPU are received, wherein the coded data are used for representing hardware coding of the GPU on the converted data, the converted data are used for representing format conversion after the CPU decodes the first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding; hardware decoding is performed on the encoded data. The picture format identification of the master slice is utilized, the slave slices do not support the parallel transcoding of the pictures in the hardware decoding format, and the transcoded pictures are sent to the daughter cards, so that the daughter cards completely use hardware for decoding. Therefore, the problem that decoding of the pictures in the related technology is time-consuming can be solved, and the effect of improving the picture guide speed is achieved.
In an exemplary embodiment, the method further includes:
s1, receiving a second picture to be decoded sent by the main card device, wherein the second picture to be decoded supports hardware decoding;
and S2, decoding the second picture to be decoded by using hardware equipment.
In the embodiment, an integrated graphics card (GPU) with an idle x86 chip is used for JPG hardware encoding.
The invention is illustrated below with reference to specific examples:
in the embodiment, a powerful and idle x86 CPU of the master card is used to identify the picture that the daughter card does not support hardware, transcode the picture format into the JPG format supported by hardware decoding in a mode of soft decoding and then hard coding, and then issue the daughter card, so that the picture decoding speed of the daughter card is increased, and the goal of improving the performance of the picture guide service is achieved. As shown in fig. 5, it is a specific flowchart of this embodiment, and includes the following steps:
s501: receiving a picture to be modeled imported by a user (for example, 50 ten thousand pictures are issued);
s502: firstly, carrying out format identification on a picture;
s503: if the identification format sub card supports hardware decoding, directly sending the picture to the sub card and traversing the next picture;
s504: identifying that the format daughter card hardware decoding does not support, marking the picture format, sending the picture into a picture transcoding task in a non-blocking mode, and traversing the next picture;
s505: the transcoding task is executed as a single thread, and the picture to be transcoded is blocked and waited for;
s506: after receiving the picture sent in S503, finding a corresponding picture soft decoding library (jpg soft decoding library/PNG soft decoding library, etc.) according to the marked picture format, and decoding the picture through the CPU;
s507: and converting the format of the pixel data obtained after decoding into YUV (the daughter card only supports YUV color system hard solution) by using a CPU.
S508: in order to improve the coding speed, an integrated graphics card (GPU) with an idle x86 chip is used for JPG hardware coding.
S509: the coded JPG picture is stored in a transcoding queue to be sent;
s510: and when the next picture does not exist in S502 or S503, which means that the supported format picture is sent, next, sending the picture in the transcoding queue to be sent to the daughter card.
The processing logic of the daughter card is simpler, after the picture of the main card is received, the picture can be decoded by directly using hardware, and the time consumption for introducing the picture soft solution is greatly shortened, as shown in fig. 6.
In summary, in the embodiment, by using the characteristics of redundant master CPU and GPU resources of the IVSS device and the powerful performance of x86, the master identifies the picture format, and the slave does not support parallel transcoding of the picture in the hardware decoding format, and transmits the transcoded picture to the slave card, so that the smart slave card completely uses hardware decoding, thereby achieving the goal of increasing the speed of image guidance.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
In this embodiment, an image processing apparatus is further provided, and the apparatus is used to implement the foregoing embodiments and preferred embodiments, and the description of the apparatus is omitted for brevity. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 7 is a block diagram (a) of a picture processing apparatus according to an embodiment of the present invention, and as shown in fig. 7, the apparatus includes:
a first receiving module 72, configured to receive a first to-be-decoded picture, where a picture format of the first to-be-decoded picture does not support hardware decoding;
a first decoding module 74, configured to decode a first picture to be decoded to obtain decoded data;
a first conversion module 76, configured to perform format conversion on the decoded data to obtain converted data;
and the first sending module 78 is configured to send the conversion data to the GPU, so as to instruct the GPU to perform hardware encoding on the conversion data, so as to obtain encoded data, where the GPU is further configured to send the encoded data to the daughter card device, and the daughter card device is configured to perform hardware decoding on the encoded data.
In an exemplary embodiment, the first decoding module includes:
a first determining unit, configured to determine a format flag of the first to-be-decoded picture to determine a picture format of the first to-be-decoded picture;
a second determining unit, configured to determine, from a picture soft decoding library, a target picture soft decoding corresponding to the picture format;
a first decoding unit, configured to decode the first to-be-decoded picture by using the target picture soft decoding, so as to obtain the decoded data.
In an exemplary embodiment, the first conversion module includes:
a third determining unit configured to determine pixel data in the decoded data;
and the first conversion unit is used for converting the format of the pixel data into a color coding format to obtain the conversion data.
Fig. 8 is a block diagram (ii) of the structure of a picture processing apparatus according to an embodiment of the present invention, and as shown in fig. 8, the apparatus includes:
the second receiving module 82 is configured to receive conversion data sent by the CPU, where the conversion data is used to indicate format conversion after the CPU decodes the first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
a first encoding module 84, configured to perform hardware encoding on the converted data to obtain encoded data;
and a second sending module 86, configured to send the encoded data to the daughter card device, so as to instruct the daughter card device to perform hardware decoding on the encoded data.
In an exemplary embodiment, the first encoding module includes:
and a first encoding unit, configured to perform hardware encoding in a JPG format on the converted data to obtain the encoded data.
In an exemplary embodiment, the second sending module includes:
a first storing unit, configured to store the encoded data in a queue to be sent;
and the first sending unit is used for sending the coded data to the daughter card equipment in the queue to be sent.
Fig. 9 is a block diagram (three) of the structure of a picture processing apparatus according to an embodiment of the present invention, as shown in fig. 9, the apparatus including:
the third receiving module 92 is configured to receive encoded data sent by the GPU, where the encoded data is used to indicate hardware encoding performed by the GPU on the converted data, the converted data is used to indicate format conversion performed by the CPU after the CPU decodes the first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
and a second decoding module 94, configured to perform hardware decoding on the encoded data.
In an exemplary embodiment, the apparatus further includes:
the fourth receiving module is used for receiving a second picture to be decoded sent by the main card device, wherein the second picture to be decoded supports hardware decoding;
and the third decoding module is used for decoding the second picture to be decoded by utilizing hardware equipment.
It should be noted that, the above modules may be implemented by software or hardware, and for the latter, the following may be implemented, but not limited to: the modules are all positioned in the same processor; alternatively, the modules are respectively located in different processors in any combination.
Embodiments of the present invention also provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program is arranged to perform the steps of any of the above-mentioned method embodiments when executed.
In the present embodiment, the above-described computer-readable storage medium may be configured to store a computer program for executing the above steps.
In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to: various media capable of storing computer programs, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
Embodiments of the present invention also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the above method embodiments.
In an exemplary embodiment, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
In an exemplary embodiment, the processor may be configured to execute the above steps by a computer program.
For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary embodiments, and details of this embodiment are not repeated herein.
It will be apparent to those skilled in the art that the various modules or steps of the invention described above may be implemented using a general purpose computing device, they may be centralized on a single computing device or distributed across a network of computing devices, and they may be implemented using program code executable by the computing devices, such that they may be stored in a memory device and executed by the computing device, and in some cases, the steps shown or described may be performed in an order different than that described herein, or they may be separately fabricated into various integrated circuit modules, or multiple ones of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the principle of the present invention should be included in the protection scope of the present invention.

Claims (13)

1. An image processing method, comprising:
receiving a first picture to be decoded, wherein the picture format of the first picture to be decoded does not support hardware decoding;
decoding the first picture to be decoded to obtain decoded data;
carrying out format conversion on the decoded data to obtain converted data;
and sending the conversion data to an image processor GPU to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is also used for sending the coded data to sub-card equipment, and the sub-card equipment is used for performing hardware decoding on the coded data.
2. The method of claim 1, wherein decoding the first picture to be decoded to obtain decoded data comprises:
determining a format flag of the first picture to be decoded so as to determine a picture format of the first picture to be decoded;
determining target picture soft decoding corresponding to the picture format from a picture soft decoding library;
and decoding the first picture to be decoded by utilizing the target picture soft decoding to obtain the decoding data.
3. The method of claim 1, wherein converting the format of the decoded data to obtain converted data comprises:
determining pixel data in the decoded data;
and converting the format of the pixel data into a color coding format to obtain the conversion data.
4. An image processing method, comprising:
receiving conversion data sent by a CPU, wherein the conversion data is used for representing format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
carrying out hardware coding on the conversion data to obtain coded data;
and sending the coded data to a daughter card device to instruct the daughter card device to perform hardware decoding on the coded data.
5. The method of claim 4, wherein hardware encoding the transformed data to obtain encoded data comprises:
and carrying out JPG format hardware coding on the conversion data to obtain the coded data.
6. The method of claim 4, wherein transmitting the encoded data to a daughter card device comprises:
storing the coded data into a queue to be sent;
and transmitting the coded data to the daughter card equipment in a queue to be transmitted.
7. An image processing method, comprising:
receiving encoded data sent by a GPU, wherein the encoded data is used for representing hardware coding of the GPU on conversion data, the conversion data is used for representing format conversion after a CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
and carrying out hardware decoding on the coded data.
8. The method of claim 7, further comprising:
receiving a second picture to be decoded sent by a main card device, wherein the second picture to be decoded supports hardware decoding;
and decoding the second picture to be decoded by utilizing hardware equipment.
9. A picture processing apparatus, comprising:
the device comprises a first receiving module, a second receiving module and a decoding module, wherein the first receiving module is used for receiving a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
the first decoding module is used for decoding the first picture to be decoded to obtain decoded data;
the first conversion module is used for carrying out format conversion on the decoded data to obtain conversion data;
the first sending module is used for sending the conversion data to an image processor GPU so as to instruct the GPU to perform hardware coding on the conversion data to obtain coded data, wherein the GPU is further used for sending the coded data to sub-card equipment, and the sub-card equipment is used for performing hardware decoding on the coded data.
10. A picture processing apparatus, comprising:
the second receiving module is used for receiving conversion data sent by the CPU, wherein the conversion data is used for representing format conversion after the CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
the first coding module is used for carrying out hardware coding on the conversion data to obtain coded data;
and the second sending module is used for sending the coded data to the daughter card equipment so as to instruct the daughter card equipment to perform hardware decoding on the coded data.
11. A picture processing apparatus, comprising:
the third receiving module is used for receiving coded data sent by a GPU, wherein the coded data is used for representing hardware coding of the GPU on converted data, the converted data is used for representing format conversion after a CPU decodes a first picture to be decoded, and the picture format of the first picture to be decoded does not support hardware decoding;
and the second decoding module is used for carrying out hardware decoding on the coded data.
12. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the method of any one of claims 1 to 3, or carries out the method of any one of claims 4 to 6, or carries out the method of any one of claims 7 to 8.
13. An electronic apparatus comprising a memory and a processor, wherein the memory has stored therein a computer program, and wherein the processor is arranged to execute the computer program to perform the method of any of claims 1 to 3, or to perform the method of any of claims 4 to 6, or to implement the method of any of claims 7 to 8.
CN202110579397.4A 2021-05-26 2021-05-26 Picture processing method and device, storage medium and electronic device Pending CN113327302A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110579397.4A CN113327302A (en) 2021-05-26 2021-05-26 Picture processing method and device, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110579397.4A CN113327302A (en) 2021-05-26 2021-05-26 Picture processing method and device, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN113327302A true CN113327302A (en) 2021-08-31

Family

ID=77416868

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110579397.4A Pending CN113327302A (en) 2021-05-26 2021-05-26 Picture processing method and device, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN113327302A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114760495A (en) * 2022-03-21 2022-07-15 南京芯驰半导体科技有限公司 Video hardware decoding method and system based on video processing unit

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101778270A (en) * 2009-01-13 2010-07-14 深圳市同洲电子股份有限公司 Method for accelerating the image displaying speed, system and digital television receiving terminal
CN103179431A (en) * 2013-03-21 2013-06-26 福建升腾资讯有限公司 Method for redirecting, transcoding and separating audio/video under VDI (Virtual Desktop Infrastructure) condition
CN104104897A (en) * 2014-06-27 2014-10-15 北京奇艺世纪科技有限公司 Mobile terminal video editing method and device
CN108432257A (en) * 2016-01-08 2018-08-21 华为技术有限公司 Jpeg image to compression GPU texture transcoder
CN111147926A (en) * 2018-11-02 2020-05-12 杭州海康威视数字技术股份有限公司 Data transcoding method and device
CN112379949A (en) * 2021-01-14 2021-02-19 腾讯科技(深圳)有限公司 Data processing method, device, equipment and storage medium
CN112422978A (en) * 2020-11-16 2021-02-26 浙江宇视科技有限公司 Intelligent transcoding method and device, electronic equipment and storage medium
CN112422963A (en) * 2020-11-17 2021-02-26 杭州雾联科技有限公司 Cloud computer system, encoding method, device, equipment and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101778270A (en) * 2009-01-13 2010-07-14 深圳市同洲电子股份有限公司 Method for accelerating the image displaying speed, system and digital television receiving terminal
CN103179431A (en) * 2013-03-21 2013-06-26 福建升腾资讯有限公司 Method for redirecting, transcoding and separating audio/video under VDI (Virtual Desktop Infrastructure) condition
CN104104897A (en) * 2014-06-27 2014-10-15 北京奇艺世纪科技有限公司 Mobile terminal video editing method and device
CN108432257A (en) * 2016-01-08 2018-08-21 华为技术有限公司 Jpeg image to compression GPU texture transcoder
CN111147926A (en) * 2018-11-02 2020-05-12 杭州海康威视数字技术股份有限公司 Data transcoding method and device
CN112422978A (en) * 2020-11-16 2021-02-26 浙江宇视科技有限公司 Intelligent transcoding method and device, electronic equipment and storage medium
CN112422963A (en) * 2020-11-17 2021-02-26 杭州雾联科技有限公司 Cloud computer system, encoding method, device, equipment and storage medium
CN112379949A (en) * 2021-01-14 2021-02-19 腾讯科技(深圳)有限公司 Data processing method, device, equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114760495A (en) * 2022-03-21 2022-07-15 南京芯驰半导体科技有限公司 Video hardware decoding method and system based on video processing unit

Similar Documents

Publication Publication Date Title
CN107292808B (en) Image processing method and device and image coprocessor
CN102413150B (en) Server and virtual desktop control method and virtual desktop control system
CN108900843B (en) Monochrome image compression method, apparatus, medium, and electronic device
US11196868B2 (en) Audio data processing method, server, client and server, and storage medium
CN111669577A (en) Hardware decoding detection method and device, electronic equipment and storage medium
WO2020083019A1 (en) Decoding method based on multi-core processor, terminal device and storage medium
CN107835509B (en) Method, device, system, equipment and storage medium for interconnection between equipment
CN115767092A (en) Image transmission method, cloud desktop, image transmission system, image transmission equipment and product
CN113327302A (en) Picture processing method and device, storage medium and electronic device
CN115225881B (en) Data transmission method, device, equipment and storage medium
CN114218175A (en) Resource cross-platform sharing method and device, terminal equipment and storage medium
CN109104581B (en) Wireless screen transmission method, system and receiving terminal
CN116668691A (en) Picture compression transmission method and device and terminal equipment
CN113099270B (en) File storage method, decoding method, device, storage medium and electronic device
CN113507530A (en) Data forwarding method, related system and device and storage medium
TWI669947B (en) Image transcoding method, computational apparatus, and storage medium
CN112188562A (en) Multicast scheduling method and device for relay base station, storage medium and electronic device
CN112929706A (en) Video data playback method, device, storage medium, and electronic device
CN112073739A (en) Mobile recording and broadcasting control system and method
CN111447453B (en) Image processing method and device
CN109451313A (en) A kind of method for video coding, system and electronic equipment and storage medium
CN114567632B (en) Progressive coding edge intelligent image transmission method, system, equipment and medium
CN116204201B (en) Service processing method and device
CN117914459A (en) Semantic synchronization method, device and storage medium based on fixed image
CN114520918A (en) Data transmission method and related equipment

Legal Events

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

Application publication date: 20210831

RJ01 Rejection of invention patent application after publication