Image transmission method and device, equipment and storage medium
By splitting and filling image frames of large-sized images, the problem that the video transmission interface cannot transmit large-sized images is solved, the transmission of high-resolution images is realized, and binary data transmission is supported, which improves transmission flexibility and saves costs.
Patent Information
- Application Number
- CN202311260668.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-26
- Publication Date
- 2025-03-28
AI Technical Summary
The video transmission interface in the prior art cannot transmit large-sized images and cannot be used for the transmission of binary data.
By splitting the target image, multiple sub-images and image splitting information are obtained, image information is generated based on image splitting information and sub-image position information, sub-images are filled into image frames, and these image frames are sent through the video transmission interface. Finally, the receiving end combines the sub-images to generate the target image based on the image information.
The ability to transmit large-size images through the video transmission interface is realized, and the transmission of binary data is supported during the transmission process, which improves the flexibility of information transmission and saves manufacturing costs.
Smart Images

Figure CN119728882A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of data transmission, and in particular, to an image transmission method, apparatus, device and storage medium. Background Art
[0002] At present, in a video processing system, when a plurality of video processing modules transmit video data, the video processing modules generally transmit video data to each other through a video transmission interface. However, in the process of transmitting video data through the video transmission interface, if the size of the transmitted image exceeds the maximum resolution of the video transmission interface, the transmission of the image cannot be completed. For example, an HDMI interface with a maximum resolution of 3840x2160 cannot transmit an image with a resolution of 4000*3000. In addition, since the video transmission interface performs color space conversion when sending and receiving data, the video transmission interface cannot be used for the transmission of binary data.
[0003] In summary, the video transmission interface in the prior art has the technical problem of being unable to transmit large-size images. Summary of the invention
[0004] The embodiments of the present invention provide an image transmission method, apparatus, device and storage medium, which can use a video transmission interface to transmit large-size images, solving the technical problem that the video transmission interface in the prior art cannot transmit large-size images. In addition, the image transmission method of the embodiments of the present invention can transmit binary data through the video transmission interface while transmitting the image.
[0005] In a first aspect, an embodiment of the present invention provides an image transmission method, which is applicable to a sending end, wherein the sending end and the receiving end are connected via a video transmission interface, and the method includes:
[0006] Splitting the target image to obtain at least two sub-images and image splitting information;
[0007] Fill each sub-image into the corresponding image frame;
[0008] Generate image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame;
[0009] The image information is filled into the image frame where the corresponding sub-image is located to generate a sending frame, and the sending frame is sent to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each sending frame to generate the target image.
[0010] In a second aspect, an embodiment of the present invention provides another image transmission method, which is applicable to a receiving end, where the receiving end and the transmitting end are connected via a video transmission interface, and the method includes:
[0011] receiving a transmission frame sent by a transmitting end through a video transmission interface, wherein the transmission frame includes a sub-image and image information, wherein the sub-image is obtained by splitting a target image by the transmitting end, and the image information includes position information of the sub-image in the transmission frame and image splitting information of the target image, wherein the image splitting information is generated in the process of splitting the target image;
[0012] Parse each sent frame to obtain the sub-image and image information in the sent frame;
[0013] After receiving all the sent frames, determining the combination of sub-images in all the sent frames according to the image information of each sent frame;
[0014] All sub-images are combined according to the combination method to generate the target image.
[0015] In a third aspect, an embodiment of the present invention provides an image transmission device, which is applicable to a sending end, and the sending end and the receiving end are connected through a video transmission interface, and the device includes:
[0016] An image splitting module is used to split the target image to obtain at least two sub-images and image splitting information;
[0017] An image filling module, used to fill each sub-image into the corresponding image frame;
[0018] An image information generating module, used for generating image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame;
[0019] The frame sending module is used to fill the image information into the image frame where the corresponding sub-image is located to generate a sending frame, and send the sending frame to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end can combine the sub-images in all the sending frames according to the image information in each sending frame to generate a target image.
[0020] In a fourth aspect, an embodiment of the present invention provides an image transmission device, which is applicable to a receiving end, the receiving end and the transmitting end are connected via a video transmission interface, and the device includes:
[0021] A frame receiving module is used to receive a transmission frame sent by a transmitting end through a video transmission interface, wherein the transmission frame includes a sub-image and image information, wherein the sub-image is obtained by splitting a target image by the transmitting end, and the image information includes position information of the sub-image in the transmission frame and image splitting information of the target image, wherein the image splitting information is generated in the process of splitting the target image;
[0022] The frame parsing module is used to parse each sent frame and obtain the sub-image and image information in the sent frame;
[0023] A combination mode determination module is used to determine the combination mode of sub-images in all the sent frames according to the image information of each sent frame after receiving all the sent frames;
[0024] The image restoration module is used to combine all sub-images according to the combination method to generate a target image.
[0025] In a fifth aspect, an embodiment of the present invention provides an image transmission device, the image transmission device comprising a processor and a memory;
[0026] The memory is used to store the computer program and transmit the computer program to the processor;
[0027] The processor is used to execute an image transmission method according to the instructions in the computer program.
[0028] In a sixth aspect, an embodiment of the present invention provides a storage medium storing computer executable instructions, which, when executed by a computer processor, are used to execute an image transmission method as in the first aspect and the second aspect.
[0029] As described above, the embodiments of the present invention provide an image transmission method, apparatus, device and storage medium. When transmitting a target image with a higher resolution, the embodiments of the present invention first need to split the target image to obtain multiple sub-images and image splitting information. Afterwards, based on the image splitting information and the position information of the sub-image in each image frame, the image information corresponding to each image frame is generated, and the image information is filled into the image frame where the corresponding sub-image is located to generate a sending frame. Finally, the sending frame is sent to the receiving end through the video transmission interface. After receiving all the sending frames, the receiving end can combine the sub-images in all the sending frames according to the image information in each sending frame, so as to restore the target image.
[0030] The embodiment of the present invention splits a high-resolution image into multiple sub-images, fills the multiple sub-images into multiple image frames respectively, and sends the image frames to a receiving end through a video transmission interface, so that the receiving end can subsequently restore the target image based on the sub-images in the image frames. The embodiment of the present invention can transmit high-resolution images through a video transmission interface, so that when transmitting images, it is not necessary to be limited to the maximum resolution supported by the video transmission interface, which solves the technical problem that high-resolution images cannot be transmitted through a video transmission interface in the prior art. In addition, the embodiment of the present invention can fill image information into image frames and transmit them through a video transmission interface, so that there is no need to set up an additional information transmission interface between the sending end and the receiving end for information transmission, which improves the flexibility of information transmission and saves certain manufacturing costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 A schematic flow chart of an image transmission method provided by an embodiment of the present invention.
[0032] Figure 2 A schematic diagram of a transmission end and a reception end connected to each other is provided in an embodiment of the present invention.
[0033] Figure 3 A schematic diagram of a transmitting end generating a transmitting frame provided in an embodiment of the present invention.
[0034] Figure 4 A schematic flow chart of another image transmission method provided by an embodiment of the present invention.
[0035] Figure 5 A schematic diagram of splitting a target image provided by an embodiment of the present invention.
[0036] Figure 6 A schematic diagram of a sub-image area in an image frame provided by an embodiment of the present invention.
[0037] Figure 7 A schematic diagram of filling a sub-image in a sub-image area provided by an embodiment of the present invention.
[0038] Figure 8 A schematic diagram of filling a sub-image in a sub-image area provided by an embodiment of the present invention.
[0039] Fig. 9 A schematic diagram of a frame header information area and a frame tail information area in an image frame provided by an embodiment of the present invention.
[0040] Fig.10 A schematic diagram of using the Y component for encoding provided by an embodiment of the present invention.
[0041] Fig.11A schematic diagram of the structure of another image frame provided by an embodiment of the present invention.
[0042] Fig.12 A schematic diagram of the structure of a target image provided by an embodiment of the present invention.
[0043] Fig.13 A schematic diagram of a sending frame provided by an embodiment of the present invention.
[0044] Fig.14 A schematic diagram of another sending frame provided by an embodiment of the present invention.
[0045] Fig.15 A schematic flow chart of another image transmission method provided by an embodiment of the present invention.
[0046] Fig.16 A schematic structural diagram of an image transmission device provided by an embodiment of the present invention.
[0047] Fig.17 A schematic structural diagram of another image transmission device provided by an embodiment of the present invention.
[0048] Fig.18 A schematic diagram of the structure of an image transmission device provided by an embodiment of the present invention.
[0049] Reference numerals:
[0050] A transmitting end 10 , a receiving end 20 , and a video transmission interface 30 . DETAILED DESCRIPTION
[0051] The following description and accompanying drawings fully illustrate the specific embodiments of the present application so that those skilled in the art can practice them. The examples represent possible variations only. Unless explicitly required, separate components and functions are optional, and the order of operation can vary. The parts and features of some embodiments may be included in or replace the parts and features of other embodiments. The scope of the embodiments of the present application includes the entire scope of the claims, and all available equivalents of the claims. In this article, each embodiment may be represented individually or generally by the term "invention", which is only for convenience, and if more than one invention is disclosed in fact, it is not intended to automatically limit the scope of the application to any single invention or inventive concept. In this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, without requiring or implying any actual relationship or order between these entities or operations. Moreover, the term "include", "comprise" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method or device including a series of elements includes not only those elements, but also other elements that are not explicitly listed. The various embodiments are described in a progressive manner herein, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other. As for the structures, products, etc. disclosed in the embodiments, since they correspond to the parts disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the description of the method part.
[0052] like Figure 1 As shown, Figure 1 The flowchart of an image transmission method provided by an embodiment of the present invention is applicable to a sending end, wherein the sending end can be implemented by software and / or hardware, and the sending end can be composed of two or more physical entities, or can be composed of one physical entity. Figure 2 As shown, in the embodiment of the present invention, the transmitting end 10 and the receiving end 20 are connected via a video transmission interface 30, wherein the video transmission interface refers to an interface for transmitting video data, and the video transmission interface can be selected according to actual needs. For example, in the present embodiment, the video transmission interface can be HDMI (High Definition Multimedia Interface), MIPI (Mobile Industry Processor Interface), CSI (Camera Serial Interface), etc. In the present embodiment, the video transmission interface is not specifically limited. The image transmission method provided in the embodiment of the present invention comprises the following steps:
[0053] Step 101: split a target image to obtain at least two sub-images and image splitting information.
[0054] In this embodiment, the transmitting end first needs to obtain the target image to be transmitted and determine the resolution of the target image. After that, the transmitting end needs to further determine whether the resolution of the target image exceeds the maximum resolution supported by the video transmission interface. If the resolution of the target image exceeds the maximum resolution supported by the video transmission interface, the transmitting end needs to split the target image into at least two sub-images and generate image splitting information of the target image. In one embodiment, the transmitting end can generate image splitting information according to the splitting method of the target image, for example, the image splitting information includes the resolution of each sub-image after splitting and the original position of each sub-image in the target image.
[0055] Step 102: Fill each sub-image into the corresponding image frame.
[0056] After splitting the target image into multiple sub-images, the sender needs to fill each sub-image into the corresponding image frame. In this embodiment, the number of image frames is at least two, and the number of sub-images in each image frame is determined by the resolution of the sub-image. For example, assuming that each image frame can only be filled with image data with a maximum resolution of 3840×2100, when filling the sub-image, only one sub-image with a resolution of 3840×2100 can be filled in the image frame, or a sub-image of 3840×900 and a sub-image of 160×1000 can be filled in the image frame.
[0057] Step 103: Generate image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame.
[0058] After filling the sub-images into the image frame, the sender needs to further determine the sub-images in each image frame, and then obtain the position information of each sub-image in each image frame, wherein the position information includes the position coordinates of each sub-image in each image frame. Afterwards, the sender needs to generate image information corresponding to each image frame based on the image segmentation information and the position information of the sub-images in each image frame. Exemplarily, the sender can obtain the resolution of each sub-image in the image frame and the position of the sub-image in the target image in the image segmentation information, and then generate the image information corresponding to each image frame in combination with the position information of the sub-image in the image frame.
[0059] Step 104, fill the image information into the image frame where the corresponding sub-image is located to generate a sending frame, and send the sending frame to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each sending frame to generate a target image.
[0060] After the sending end generates the image information corresponding to each image frame, it needs to fill the image information into the image frame where the corresponding sub-image is located to generate a sending frame. The specific process is as follows: Figure 3 In one embodiment, the sending end may fill the image information into the frame header information and frame footer information of the image frame where the sub-image is located to generate a sending frame.
[0061] After generating the transmission frame, the transmitting end can send each transmission frame to the receiving end through the video transmission interface. After receiving the transmission frame, the receiving end parses the transmission frame and extracts the sub-image and image information from the transmission frame. When the receiving end receives all the transmission frames, it can parse the image information and sub-image in each transmission frame, and combine the sub-images in all the transmission frames according to the image information, so as to restore the target image. For example, the receiving end can obtain the corresponding sub-image in the transmission frame according to the position information in the image information, and then splice and combine each sub-image according to the position of each sub-image in the target image in the image information, so as to restore the target image.
[0062] As described above, an embodiment of the present invention provides an image transmission method. When transmitting a target image with a higher resolution, the embodiment of the present invention first needs to split the target image to obtain multiple sub-images and image splitting information. Afterwards, based on the image splitting information and the position information of the sub-image in each image frame, the image information corresponding to each image frame is generated, and the image information is filled into the image frame where the corresponding sub-image is located to generate a sending frame. Finally, the sending frame is sent to the receiving end through the video transmission interface. After receiving all the sending frames, the receiving end can combine the sub-images in all the sending frames according to the image information in each sending frame, so as to restore the target image.
[0063] The embodiment of the present invention splits a high-resolution image into multiple sub-images, fills the multiple sub-images into multiple image frames respectively, and sends the image frames to a receiving end through a video transmission interface, so that the receiving end can subsequently restore the target image based on the sub-images in the image frames. The embodiment of the present invention can transmit high-resolution images through a video transmission interface, so that when transmitting images, it is not necessary to be limited to the maximum resolution supported by the video transmission interface, which solves the technical problem that high-resolution images cannot be transmitted through a video transmission interface in the prior art. In addition, the embodiment of the present invention can fill image information into image frames and transmit them through a video transmission interface, so that there is no need to set up an additional information transmission interface between the sending end and the receiving end for information transmission, which improves the flexibility of information transmission and saves certain manufacturing costs.
[0064] like Figure 4 As shown, Figure 4 A flow chart of another image transmission method provided by an embodiment of the present invention is shown as follows: Figure 4 The image transmission method shown is a specific embodiment of the above-mentioned image transmission method. The image transmission method provided by the embodiment of the present invention includes:
[0065] Step 201: split the target image to obtain at least two sub-images and image splitting information.
[0066] In this embodiment, the maximum resolution supported by the video transmission interface is 3840×2160. Assuming that the resolution of the target image to be sent is 4000×3000, since the resolution of the target image exceeds the maximum resolution supported by the video transmission interface, the target image needs to be split into two image frames for transmission. For example, the target image can be split into five sub-images, such as Figure 5 As shown, the resolution of sub-image A is 3840×2100, the resolution of sub-image B is 3840×900, and the resolutions of sub-image C, sub-image D, and sub-image E are all 160×1000.
[0067] Step 202: Fill each sub-image into the image data information of the corresponding image frame, where the image frame includes the image data information.
[0068] In this embodiment, the image frame includes image data information, and the image data information is used to store image data. Figure 6 As shown, Figure 6: is a structural diagram of an image frame, in which a sub-image area is provided, wherein the data information in the sub-image area is the image data information. When filling a sub-image into an image frame, the sub-image is filled into the sub-image area of the image frame, thereby writing the image data corresponding to the sub-image into the image data information. In addition, in this embodiment, the size of the sub-image area is limited. For example, when the resolution of the image frame is 3840×2160, the size of the sub-image area can be set to 3840×2100, that is, the resolution of the sub-image filled into the sub-image area cannot exceed 3840×2100. Figure 5 The sub-image shown is used for illustration, Figure 5 The sub-image shown needs to be filled into two image frames, and the sub-image A can be filled into the sub-image area of the first image frame, such as Figure 7 As shown, sub-image B, sub-image C, sub-image D and sub-image F are filled into the sub-image area of the second image frame, as shown in FIG. Figure 8 After the sub-image is filled into the sub-image area of the image frame, the image data of the sub-image is written into the image data information of the image frame.
[0069] Step 203: Determine the resolution of each sub-image and the first coordinate of the sub-image in the target image according to the image segmentation information.
[0070] After filling the sub-images into the image information data in the corresponding image frame, the sending end needs to further determine the resolution of each sub-image and the first coordinate of the sub-image in the target image according to the image splitting information. In this embodiment, the image splitting information is generated according to the splitting method of the sub-image, and the image splitting information includes the number of split sub-images and the position of the splitting point of the sub-image on the target image when the sub-image is split. The sending end can then determine the resolution of each sub-image and the original first coordinate of the sub-image in the target image according to the image splitting information, wherein the first coordinate is the coordinate in the image coordinate system established on the target image.
[0071] Step 204: Determine the second coordinates of the sub-image in each image frame in the image frame.
[0072] After determining the resolution and first coordinates of the sub-image in each image frame, the transmitting end can further determine the second coordinates of the sub-image in each image frame in the image frame. Similarly, an image coordinate system can be established in the image frame in advance, and then the second coordinates of the sub-image in the image frame can be determined according to the position filled by the sub-image in the sub-image area.
[0073] Step 205 : Generate image information corresponding to each image frame according to the resolution of the sub-image in each image frame, the first coordinate of the sub-image, and the second coordinate of the sub-image.
[0074] After determining the second coordinate of the sub-image in the image frame, the sending end needs to further generate image information corresponding to the image frame where the sub-image is located based on the resolution of the sub-image in each image frame, the first coordinate of the sub-image and the second coordinate of the sub-image.
[0075] Step 206: Fill the image information into the frame header information and frame footer information of the corresponding image frame, where the image frame includes the frame header information and the frame footer information.
[0076] In this embodiment, each image frame includes frame header information and frame footer information. Fig. 9 As shown, each image frame also includes a frame header information area and a frame tail information area, wherein the frame header information area is used to store the frame header information, and the frame tail information area is located in the storage frame tail information. After the sending end generates the image information corresponding to each image frame, the image information can be filled into the frame header information area and the frame tail information area of the corresponding image frame, that is, the image information is written into the frame header information and the frame tail information of the corresponding image frame, so as to transmit the image information through the image frame. In one embodiment, the data in the frame header information and the frame tail information are shown in Table 1:
[0077]
[0078]
[0079] Table 1
[0080] Regions are used to describe each sub-image in the image frame. The structure definition of the sub-image block is shown in Table 2:
[0081] Data Types Data name Data Definition int16_t startX4k The X coordinate of the sub-image position in the sent frame int16_t startY4k Y coordinate of the sub-image position in the sent frame int16_t rgnWidth Width of sub-image int16_t rgnHigh Sub-image height int16_t startXOrg The X coordinate of the sub-image in the target image int16_t StartYOrg The Y coordinate of the sub-image in the target image
[0082] Table 2
[0083] The data in startX4k and startY4k can be obtained from the second coordinate, the data in rgnWidth and rgnHigh can be obtained from the resolution of the sub-image, and the data in startXOrg and StartYOrg can be obtained from the first coordinate.
[0084] Among them, in this embodiment, the data in the frame header information is the same as the data in the frame tail information, and the frame tail information is used to ensure the integrity of the entire frame information to avoid receiving only part of the data of the sent frame. In addition, in the frame header information and the frame tail information, the extendInfo area can contain additional information data, and the field size can be expanded according to the amount of additional information data. Exemplarily, when the sending end fills the image information into the image frame where the corresponding sub-image is located, it also fills the binary data to be transmitted into the image frame, that is, fills the binary data to be transmitted into the extendInfo area of the frame header information and the frame tail information to transmit the binary data through the image frame. Even when there is no data transmission interface between the sending end and the receiving end, binary data can be transmitted between the sending end and the receiving end through the video transmission interface.
[0085] Step 207, encode the frame header information and frame tail information of the image frame to generate a sending frame, and send the sending frame to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each sending frame to generate a target image.
[0086] After the image information is filled into the frame header information and the frame tail information, the color gamut space will be transformed during the transmission of the image frame through the video transmission interface, which causes the data in the frame header information and the frame tail information to change. Based on this, in order to ensure that the frame header information and the frame tail information can be accurately transmitted, the frame header information and the frame tail information need to be further encoded in this embodiment to avoid the change of the frame header information and the frame tail information. In this embodiment, the image frame adopts the YUV encoding format, that is, the image frame is a YUV image. Among them, YUV is a color encoding method, YUV is a type of true-color color space (color space), "Y" represents brightness (Luminance or Luma), that is, grayscale value, "U" and "V" represent chrominance (Chrominance or Chroma), which is used to describe the color and saturation of the image, and is used to specify the color of the pixel. In this embodiment, when encoding the frame header information and the frame tail information of the image frame, the Y component in the YUV component is used to encode the frame header information and the frame tail information. The reason is that when the color gamut space is transformed, the Y component in the YUV component changes the least. After the Y component is used to encode the frame header information and the frame trailer information, the change of the frame header information and the frame trailer information during the transmission process can be reduced as much as possible. Specifically, when the Y component is used to encode the frame header information and the frame trailer information, the high bit of the Y component is used to encode the frame header information and the frame trailer information. For example, Fig.10As shown, the high 4 bits of the Y component are used for encoding, and the YUV data range clamping is not considered, and 2 Y components are used to represent 1 Byte. (If the Y data has a range clamping, the high 2 bits of the Y component can be used for encoding.) If the resolution of the image frame is 3840×2160, according to the above encoding method, when the image frame is only used to transmit data information (without filling sub-images), each image frame can transmit a maximum of 3.9MB of data.
[0087] In another embodiment, in order to prevent different sub-images in the image frame from interfering with each other during the color gamut space transformation, a gap interval may be set in the image frame, and the gap interval is used to store additional data generated after the sub-image is transformed in the color gamut space. Fig.11 shown.
[0088] After encoding the frame header information and frame tail information in the image frame, a transmission frame can be generated. After that, the transmission end needs to further send the transmission frame to the receiving end so that the receiving end can accept the transmission frame. After receiving the transmission frame, the receiving end can parse the transmission frame, parse the sub-image from the image data information of the transmission frame, and decode the frame header information and frame tail information in the transmission frame to obtain the image information in the frame header information. After confirming that all transmission frames corresponding to the target image sent by the transmission frame have been received, the receiving end can combine all sub-images according to the sub-images and image information parsed in each transmission frame to restore the target image.
[0089] For example, Fig.12 As shown, Fig.12 is the target image to be transmitted in the embodiment of the present invention. The sending end splits the target image to obtain sub-images. After the sub-images and image information are filled into the image frame, the generated sending frames are respectively as follows: Fig.13 and Fig.14 Afterwards, the sender can Fig.11 and Fig.12 The sending frame shown in FIG. 1 is sent to the receiving end. After receiving the sending frame, the receiving end can combine the sub-images contained in the sending frame to restore the image as shown in FIG. Fig.12 The target image is shown.
[0090] As described above, an embodiment of the present invention provides an image transmission method. The embodiment of the present invention fills the multiple sub-images into the image data information of multiple image frames respectively after splitting the high-resolution image into multiple sub-images, and fills the image information into the frame header information and frame footer information in the image frame, and uses the Y component to encode the frame header information and frame footer information to generate a transmission frame. Finally, the transmission frame is sent to the receiving end through the video transmission interface, so that the subsequent receiving end can restore the target image according to the sub-images in the transmission frame. The embodiment of the present invention can be used to transmit high-resolution images through the video transmission interface by splitting the sub-images and filling the sub-images into the image data information of the image frame. When transmitting the image, it is not necessary to be limited to the maximum resolution supported by the video transmission interface, which solves the technical problem that high-resolution images cannot be transmitted through the video transmission interface in the prior art. In addition, the embodiment of the present invention can fill the image information into the frame header information and frame footer information of the image frame, and use the Y component in YUV to encode the frame header information and frame footer information, so as to reduce the change of data during the transmission process through the video transmission interface, and ensure the accuracy of the frame header information and frame footer information when transmitting. At the same time, the embodiment of the present invention can also fill the binary data to be transmitted into the frame header and frame tail, so that the transmission of binary data can be realized through the video transmission interface. There is no need to set up an additional information transmission interface between the sending end and the receiving end to transmit the binary data. While improving the flexibility of information transmission, it also saves a certain manufacturing cost.
[0091] like Fig.15 As shown, Fig.15 A method flow chart of an image transmission method provided by an embodiment of the present invention. The image transmission method provided by an embodiment of the present invention is applicable to a receiving end, and the receiving end and the transmitting end are connected through a video transmission interface. The method includes:
[0092] Step 301: Receive a sending frame sent by a sending end through a video transmission interface. The sending frame includes a sub-image and image information. The sub-image is obtained by splitting a target image by the sending end. The image information includes position information of the sub-image in the sending frame and image splitting information of the target image. The image splitting information is generated in the process of splitting the target image.
[0093] In this embodiment, the receiving end is used to receive the sending frame transmitted by the sending end through the video transmission interface. The specific generation process of the sending frame can refer to the above embodiment and will not be repeated in this embodiment.
[0094] Step 302: parse each sent frame to obtain sub-images and image information in the sent frame.
[0095] After receiving the transmission frame, the receiving end parses the transmission frame to obtain the sub-image and image information in the transmission frame. Based on the above embodiment, the transmission frame includes frame header information, frame tail information and image data information, the frame header information and the frame tail information are filled with the encoded image information, and the image data information is filled with the sub-image.
[0096] In step 302, each transmitted frame is parsed to obtain sub-images and image information in the transmitted frame, including:
[0097] Step 3021: parse each sent frame to determine the frame header information, frame footer information, and image data information in each sent frame.
[0098] Step 3022: decode the frame header information and frame tail information of each transmitted frame to obtain image information.
[0099] Step 3023: parse the image data information of each sent frame to obtain a sub-image.
[0100] In this embodiment, when the receiving end parses the transmitted frame, it first needs to parse out the frame header information, frame trailer information and image data information in each transmitted frame. Afterwards, the receiving end decodes the frame header information and frame trailer information of each transmitted frame to obtain the image information stored in the frame header information and frame trailer information. When the frame header information and frame trailer information store additional binary data, the additional binary data can also be parsed from the frame header information and frame trailer information. At the same time, the receiving end needs to parse the image data information to obtain the sub-image in the transmitted frame.
[0101] In one embodiment, after the receiving end parses the frame header information and frame footer information of each sub-image, the following steps are further included:
[0102] Step 3024: Compare the frame header information and frame tail information of each transmitted frame to obtain a comparison result.
[0103] Step 3024: Determine the integrity of each transmitted frame based on the comparison result.
[0104] In one embodiment, the receiving end also needs to verify the integrity of the transmitted frame. Specifically, after parsing the frame header information and frame tail information in each transmitted frame, it is also necessary to compare the frame header information and frame tail information of each transmitted frame to determine whether the data of the frame header information and the data of the frame tail information are consistent, and obtain a comparison result. After obtaining the comparison result, it is necessary to verify the integrity of each transmitted frame based on the comparison result. If the data of the frame header information and the data of the frame tail information in the comparison result are consistent, it means that the data of the transmitted frame is complete; if the data of the frame header information and the data of the frame tail information in the comparison result are inconsistent, it means that the data in the transmitted frame is incomplete.
[0105] Step 303: After receiving all the sent frames, determine the combination method of the sub-images in all the sent frames according to the image information of each sent frame.
[0106] After receiving all the transmission frames corresponding to the target image sent by the transmitting end, the receiving end can determine the combination mode of each sub-image in all the transmission frames according to the image information in each transmission frame. Exemplarily, the receiving end can determine whether the last image frame of the target image is received according to the total number of sub-frames and sub-frame numbers in the frame header information and the frame tail information. If so, the combination mode of all sub-images is determined according to the first coordinate of each sub-image in the target image in each transmission frame, and the second coordinate and resolution of each sub-image in the image frame.
[0107] Step 304: Combine all sub-images according to the combination method to generate a target image.
[0108] After the combination method of the sub-images is determined, all the sub-images can be combined according to the combination method to generate a target image.
[0109] The embodiment of the present invention splits a high-resolution image into multiple sub-images, fills the multiple sub-images into multiple image frames respectively, and sends the image frames to a receiving end through a video transmission interface, so that the receiving end can subsequently restore the target image based on the sub-images in the image frames. The embodiment of the present invention can transmit high-resolution images through a video transmission interface, so that when transmitting images, it is not necessary to be limited to the maximum resolution supported by the video transmission interface, which solves the technical problem that high-resolution images cannot be transmitted through a video transmission interface in the prior art. In addition, the embodiment of the present invention can fill image information into image frames and transmit them through a video transmission interface, so that there is no need to set up an additional information transmission interface between the sending end and the receiving end for information transmission, which improves the flexibility of information transmission and saves certain manufacturing costs.
[0110] like Fig.16 As shown, Fig.16 A schematic diagram of the structure of an image transmission device provided by an embodiment of the present invention, Fig.16 The image transmission device shown is suitable for a transmitting end, the transmitting end and the receiving end are connected via a video transmission interface, and the device includes:
[0111] An image splitting module 401 is used to split a target image to obtain at least two sub-images and image splitting information;
[0112] An image filling module 402 is used to fill each sub-image into a corresponding image frame;
[0113] An image information generating module 403, configured to generate image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame;
[0114] The frame sending module 404 is used to fill the image information into the image frame where the corresponding sub-image is located to generate a sending frame, and send the sending frame to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each sending frame to generate a target image.
[0115] Based on the above embodiment, the image frame includes image data information;
[0116] The image filling module 402 is specifically used to fill each sub-image into the image data information of the corresponding image frame.
[0117] Based on the above embodiment, the image information generating module 403 includes:
[0118] A first coordinate determination submodule, used to determine the resolution of each sub-image and the first coordinate of the sub-image in the target image according to the image segmentation information;
[0119] A second coordinate determination submodule, used to determine a second coordinate of a sub-image in each image frame in the image frame;
[0120] The image information generating submodule is used to generate image information corresponding to each image frame according to the resolution of the sub-image in each image frame, the first coordinate of the sub-image and the second coordinate of the sub-image.
[0121] Based on the above embodiment, the image frame includes frame header information and frame tail information, and the frame sending module 404 includes:
[0122] An information filling submodule, used to fill the image information into the frame header information and frame footer information of the corresponding image frame;
[0123] The encoding submodule is used to encode the frame header information and frame tail information of the image frame to generate a sending frame.
[0124] Based on the above embodiment, the image frame adopts the YUV encoding format;
[0125] The encoding submodule is specifically used to encode the frame header information and the frame tail information using the Y component in the YUV component.
[0126] On the basis of the above embodiment, the frame sending module 404 is used to fill the image information into the image frame where the corresponding sub-image is located, and is also used to fill the binary data to be transmitted into the image frame.
[0127] The image transmission device provided in the embodiment of the present invention is included in the image transmission equipment and can be used to execute the image transmission method provided in the above embodiment, and has corresponding functions and beneficial effects.
[0128] It is worth noting that in the embodiment of the above-mentioned image transmission device, the various units and modules included are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.
[0129] like Fig.17 As shown, Fig.17 A schematic diagram of the structure of an image transmission device provided by an embodiment of the present invention, Fig.17 The image transmission device shown is suitable for a receiving end, the transmitting end and the receiving end are connected via a video transmission interface, and the device includes:
[0130] The frame receiving module 501 is used to receive a transmission frame sent by a transmitting end through a video transmission interface. The transmission frame includes a sub-image and image information. The sub-image is obtained by splitting a target image by the transmitting end. The image information includes position information of the sub-image in the transmission frame and image splitting information of the target image. The image splitting information is generated in the process of splitting the target image.
[0131] The frame parsing module 502 is used to parse each transmitted frame and obtain sub-images and image information in the transmitted frame;
[0132] The combination mode determination module 503 is used to determine the combination mode of the sub-images in all the transmitted frames according to the image information of each transmitted frame after receiving all the transmitted frames;
[0133] The image restoration module 504 is used to combine all sub-images according to the combination mode to generate a target image.
[0134] On the basis of the above embodiment, the transmitted frame includes frame header information, frame tail information and image data information, the frame header information and the frame tail information are filled with the encoded image information, the image data information is filled with the sub-image, and the frame parsing module 502 includes:
[0135] The frame parsing submodule is used to parse each sent frame and determine the frame header information, frame footer information and image data information in each sent frame;
[0136] The decoding submodule is used to decode the frame header information and frame tail information of each transmitted frame to obtain image information;
[0137] The sub-image analysis sub-module is used to analyze the image data information of each sent frame to obtain a sub-image.
[0138] Based on the above embodiment, it also includes:
[0139] The frame header and frame tail comparison module is used to compare the frame header information and frame tail information of each sent frame to obtain the comparison result;
[0140] The frame check module is used to determine the integrity of each sent frame based on the comparison result.
[0141] The image transmission device provided in the embodiment of the present invention is included in the image transmission equipment and can be used to execute the image transmission method provided in the above embodiment, and has corresponding functions and beneficial effects.
[0142] It is worth noting that in the embodiment of the above-mentioned image transmission device, the various units and modules included are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.
[0143] This embodiment also provides an image transmission device, such as Fig.18 As shown, Fig.18 A schematic diagram of the structure of an image transmission device provided by an embodiment of the present invention, the image transmission device 60 includes a processor 600 and a memory 601;
[0144] The memory 601 is used to store the computer program 602 and transmit the computer program 602 to the processor 600;
[0145] The processor 600 is used to execute the steps in the above-mentioned embodiment of the image transmission method according to the instructions in the computer program 602.
[0146] Exemplarily, the computer program 602 may be divided into one or more modules / units, one or more modules / units are stored in the memory 601, and are executed by the processor 600 to complete the present application. One or more modules / units may be a series of computer program instruction segments capable of completing specific functions, and the instruction segments are used to describe the execution process of the computer program 602 in the image transmission device 60.
[0147] The image transmission device 60 may be a computing device such as a desktop computer, a notebook, a PDA, or a cloud server. The image transmission device 60 may include, but is not limited to, a processor 600 and a memory 601. Those skilled in the art will appreciate that Fig.18It is only an example of the image transmission device 60 and does not constitute a limitation of the image transmission device 60. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the image transmission device 60 may also include input and output devices, network access devices, buses, etc.
[0148] The processor 600 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0149] The memory 601 may be an internal storage unit of the image transmission device 60, such as a hard disk or memory of the image transmission device 60. The memory 601 may also be an external storage device of the image transmission device 60, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the image transmission device 60. Further, the memory 601 may also include both an internal storage unit of the image transmission device 60 and an external storage device. The memory 601 is used to store computer programs and other programs and data required by the image transmission device 60. The memory 601 may also be used to temporarily store data that has been output or is to be output.
[0150] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0151] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0152] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0153] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0154] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store computer programs.
[0155] An embodiment of the present invention further provides a storage medium containing computer executable instructions, wherein the computer executable instructions are used to perform an image transmission method when executed by a computer processor, the method comprising the following steps:
[0156] Splitting the target image to obtain at least two sub-images and image splitting information;
[0157] Fill each sub-image into the corresponding image frame;
[0158] Generate image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame;
[0159] The image information is filled into the image frame where the corresponding sub-image is located to generate a sending frame, and the sending frame is sent to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each sending frame to generate the target image.
[0160] Or including the following steps:
[0161] receiving a transmission frame sent by a transmitting end through a video transmission interface, wherein the transmission frame includes a sub-image and image information, wherein the sub-image is obtained by splitting a target image by the transmitting end, and the image information includes position information of the sub-image in the transmission frame and image splitting information of the target image, wherein the image splitting information is generated in the process of splitting the target image;
[0162] Parse each sent frame to obtain the sub-image and image information in the sent frame;
[0163] After receiving all the sent frames, determining the combination of sub-images in all the sent frames according to the image information of each sent frame;
[0164] All sub-images are combined according to the combination method to generate the target image.
[0165] Note that the above are only preferred embodiments of the present invention and the technical principles used. Those skilled in the art will understand that the embodiments of the present invention are not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the protection scope of the embodiments of the present invention. Therefore, although the embodiments of the present invention are described in more detail through the above embodiments, the embodiments of the present invention are not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the embodiments of the present invention, and the scope of the embodiments of the present invention is determined by the scope of the appended claims.
Claims
1. An image transmission method, characterized in that: Applicable to a transmitting end, the transmitting end and the receiving end are connected via a video transmission interface, and the method comprises: Splitting the target image to obtain at least two sub-images and image splitting information; Fill each of the sub-images into a corresponding image frame; Generate image information corresponding to each of the image frames according to the image segmentation information and the position information of the sub-images in each of the image frames; The image information is filled into the image frame where the corresponding sub-image is located to generate a sending frame, and the sending frame is sent to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each of the sending frames to generate the target image.
2. The image transmission method according to claim 1, characterized in that: The image frame includes image data information; Filling each of the sub-images into a corresponding image frame includes: Each of the sub-images is filled into the image data information of the corresponding image frame.
3. The image transmission method according to claim 1, characterized in that: The step of generating image information corresponding to each image frame according to the image segmentation information and the position information of the sub-images in each image frame comprises: Determine, according to the image segmentation information, the resolution of each of the sub-images and the first coordinates of the sub-images in the target image; Determine a second coordinate of a sub-image in each of the image frames in the image frame; Image information corresponding to each of the image frames is generated according to the resolution of the sub-image in each of the image frames, the first coordinates of the sub-image, and the second coordinates of the sub-image.
4. The image transmission method according to claim 1, characterized in that: The image frame includes frame header information and frame tail information; Filling the image information into the image frame where the corresponding sub-image is located to generate a sending frame, including: Filling the image information into the frame header information and frame footer information of the corresponding image frame; The frame header information and frame tail information of the image frame are encoded to generate a sending frame.
5. The image transmission method according to claim 4, characterized in that: The image frame adopts YUV encoding format; The encoding of the frame header information and the frame tail information of the image frame includes: The frame header information and the frame tail information are encoded using the Y component in the YUV component.
6. The image transmission method according to claim 1, characterized in that: When the image information is filled into the image frame where the corresponding sub-image is located, it also includes: The binary data to be transmitted is filled into the image frame.
7. An image transmission method, characterized in that: Applicable to a receiving end, the receiving end and the transmitting end are connected via a video transmission interface, and the method comprises: Receiving, through the video transmission interface, a transmission frame sent by the transmitting end, wherein the transmission frame includes a sub-image and image information, wherein the sub-image is obtained by the transmitting end by splitting a target image, and the image information includes position information of the sub-image in the transmission frame and image splitting information of the target image, wherein the image splitting information is generated in the process of splitting the target image; Parsing each of the sent frames to obtain sub-images and image information in the sent frames; After receiving all the sent frames, determining a combination method of sub-images in all the sent frames according to image information of each of the sent frames; All the sub-images are combined according to the combination method to generate the target image.
8. The image transmission method according to claim 7, characterized in that: The transmission frame includes frame header information, frame tail information and image data information, the frame header information and frame tail information are filled with the encoded image information, and the image data information is filled with the sub-image; The step of parsing each of the sent frames to obtain the sub-images and image information in the sent frames includes: Parsing each of the sent frames to determine frame header information, frame footer information, and image data information in each of the sent frames; Decoding the frame header information and frame tail information of each of the transmitted frames to obtain the image information; The image data information of each of the sent frames is parsed to obtain the sub-image.
9. The image transmission method according to claim 8, characterized in that: Also includes: Compare the frame header information and the frame tail information of each of the sent frames to obtain a comparison result; The integrity of each of the sent frames is determined according to the comparison result.
10. An image transmission device, characterized in that: Applicable to a transmitting end, the transmitting end and the receiving end are connected via a video transmission interface, and the device comprises: An image splitting module is used to split the target image to obtain at least two sub-images and image splitting information; An image filling module, used for filling each of the sub-images into a corresponding image frame; An image information generating module, configured to generate image information corresponding to each of the image frames according to the image segmentation information and the position information of the sub-images in each of the image frames; A frame sending module is used to fill the image information into the image frame where the corresponding sub-image is located to generate a sending frame, and send the sending frame to the receiving end through the video transmission interface, so that after receiving all the sending frames, the receiving end combines the sub-images in all the sending frames according to the image information in each of the sending frames to generate the target image.
11. An image transmission device, characterized in that: Applicable to a receiving end, the receiving end and the transmitting end are connected via a video transmission interface, and the device comprises: a frame receiving module, configured to receive a transmission frame sent by the transmitting end through the video transmission interface, wherein the transmission frame includes a sub-image and image information, wherein the sub-image is obtained by the transmitting end by splitting a target image, and the image information includes position information of the sub-image in the transmission frame and image splitting information of the target image, wherein the image splitting information is generated in the process of splitting the target image; A frame parsing module, used to parse each of the sent frames to obtain sub-images and image information in the sent frames; A combination mode determination module is used to determine the combination mode of the sub-images in all the sent frames according to the image information of each of the sent frames after receiving all the sent frames; The image restoration module is used to combine all the sub-images according to the combination method to generate the target image.
12. An image transmission device, characterized in that: The image transmission device includes a processor and a memory; The memory is used to store a computer program and transmit the computer program to the processor; The processor is used to execute an image transmission method according to any one of claims 1 to 9 according to instructions in the computer program.
13. A storage medium storing computer executable instructions, characterized in that: When the computer executable instructions are executed by a computer processor, they are used to execute an image transmission method according to any one of claims 1 to 9.