Image display method, image processing method, device, equipment and medium
By generating and sending two-dimensional image sets from multiple perspectives of the three-dimensional object model on the server side, the problem of poor real-time display of three-dimensional object model in the prior art is solved, and more efficient image display and better user experience are achieved.
Patent Information
- Application Number
- CN202210999321.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-19
- Publication Date
- 2025-03-18
- Estimated Expiration
- 2042-08-19
AI Technical Summary
When the prior art displays two-dimensional images corresponding to multiple perspectives of the three-dimensional object model, it is necessary to directly download and process the three-dimensional object model, resulting in poor real-time performance and reducing the user's viewing experience.
By generating a set of two-dimensional images of the three-dimensional object model at multiple perspectives on the server side and sending it to the client, the client parses and displays the corresponding two-dimensional target image from the two-dimensional image collection based on the target perspective.
It reduces the client's direct processing needs for the three-dimensional object model, improves the real-time and user experience of image display, and avoids lag in the image display process.
Smart Images

Figure CN117640967B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of three-dimensional object display and processing, and in particular to an image display method, an image processing method, a device, a equipment and a medium. Background Art
[0002] With the continuous development of computer technology, more and more clients can display three-dimensional object models. In order to improve the display effect of the three-dimensional object model and enhance the user's interactive experience, the client needs to display the two-dimensional image of the three-dimensional object model under multiple viewing angles.
[0003] In order to display the two-dimensional images corresponding to multiple viewing angles of a three-dimensional object model on a client, the prior art generally directly downloads and processes the three-dimensional object model, and then displays the two-dimensional images of the three-dimensional object model at each viewing angle. However, the spatial information of the three-dimensional object model is relatively complex and occupies a large amount of memory. Directly processing the three-dimensional object model takes a long time, resulting in poor real-time performance of the display process of the three-dimensional object model, which ultimately reduces the user's viewing experience. Summary of the invention
[0004] In order to solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides an image display method, an image processing method, an apparatus, a device and a medium.
[0005] In a first aspect, the present disclosure provides an image display method, applied to a client, the method comprising:
[0006] Receiving a two-dimensional image set sent by a server, where the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles;
[0007] In response to a display instruction for the three-dimensional object model at a target viewing angle, parsing a two-dimensional target image corresponding to the target viewing angle from a set of two-dimensional images;
[0008] The two-dimensional target image is displayed.
[0009] In a second aspect, the present disclosure provides an image processing method, applied to a server, the method comprising:
[0010] Acquire a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles;
[0011] The two-dimensional image set is sent to a client, so that the client parses and displays a two-dimensional target image corresponding to a target viewing angle.
[0012] In a third aspect, the present disclosure provides an image display device, which is configured on a client, and includes:
[0013] A receiving module, used to receive a two-dimensional image set sent by a server, wherein the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles;
[0014] A parsing module, configured to, in response to a display instruction for the three-dimensional object model at a target viewing angle, parse a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set;
[0015] An image display module is used to display the two-dimensional target image.
[0016] In a fourth aspect, the present disclosure provides an image processing device, which is configured on a server and includes:
[0017] An acquisition module, used to acquire a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles;
[0018] The sending module is used to send the two-dimensional image set to the client, so that the client can parse and display the two-dimensional target image corresponding to the target viewing angle.
[0019] In a fifth aspect, the present disclosure provides a computer-readable storage medium, in which instructions are stored. When the instructions are executed on a terminal device, the terminal device implements the above method.
[0020] In a sixth aspect, the present disclosure provides a device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the above method is implemented when the processor executes the computer program.
[0021] In a seventh aspect, the present disclosure provides a computer program product, which includes a computer program / instructions, and the computer program / instructions implement the above method when executed by a processor.
[0022] Compared with the prior art, the technical solution provided by the embodiments of the present disclosure has at least the following advantages:
[0023] The disclosed embodiments provide an image display method, an image processing method, an apparatus, a device and a medium, which receive a two-dimensional image set sent by a server, and the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles; in response to a display instruction for the three-dimensional object model at a target viewing angle, parse a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set; and display the two-dimensional target image. Through the above process, the client can directly determine the two-dimensional target image of the target viewing angle from the two-dimensional image set for display, and the complexity and memory usage of the two-dimensional target image are small, so the process of displaying the image by the client will not occupy too much network resources and memory, thereby avoiding freezes in the image display process, and ultimately improving the user's viewing experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0025] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0026] Figure 1 A flowchart of an image display method provided by an embodiment of the present disclosure;
[0027] Figure 2 A logic diagram of an image display method provided by an embodiment of the present disclosure;
[0028] Figure 3 A flowchart of an image processing method provided by an embodiment of the present disclosure;
[0029] Figure 4 A schematic diagram of obtaining a two-dimensional image provided by an embodiment of the present disclosure;
[0030] Figure 5 A logical schematic diagram of an image processing and display method provided by an embodiment of the present disclosure;
[0031] Figure 6 A schematic diagram of the structure of an image display device provided by an embodiment of the present disclosure;
[0032] Figure 7 A schematic diagram of the structure of an image processing device provided by an embodiment of the present disclosure;
[0033] Figure 8 A schematic diagram of the structure of a client or server provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0034] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.
[0035] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.
[0036] At present, the clarity and texture complexity of many three-dimensional object models are very high. When displaying images according to the existing solutions, the downloading and processing of the three-dimensional object models have high requirements on network speed and memory, which makes it difficult to meet the needs of real-time image display.
[0037] In order to solve the above problems, the embodiments of the present disclosure provide an image display method, apparatus, device and medium. The image display method can be applied to a client. The client can include but is not limited to a mobile phone, a tablet, a laptop computer, a desktop computer, a smart home, a wearable device and a vehicle-mounted device.
[0038] Figure 1 FIG. 1 is a flow chart of an image display method provided by an embodiment of the present disclosure. Figure 1 As shown, the image display method includes the following steps.
[0039] S110: Receive a two-dimensional image set sent by a server, where the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles.
[0040] In actual application, when image display is needed, the client downloads and stores a two-dimensional image set from the server. Since the two-dimensional image set records two-dimensional images of the three-dimensional object model at multiple different perspectives, the two-dimensional image set can provide two-dimensional images at any perspective.
[0041] In the embodiment of the present disclosure, the three-dimensional object model may be a three-dimensional model of an object to be displayed.
[0042] Optionally, the three-dimensional object model may have a color feature, may have a transparency feature, or may have both a color feature and a transparency feature.
[0043] In the disclosed embodiment, the viewing angle can be understood as the screen viewing angle. Specifically, the viewing angle can be in the form of longitude and latitude. The latitude range can be [-90, 90], and the longitude range can be [0, 360].
[0044] In the embodiment of the present disclosure, a two-dimensional image refers to an image of a three-dimensional object model at any viewing angle.
[0045] S120 , in response to a display instruction for the three-dimensional object model at a target viewing angle, parsing a two-dimensional target image corresponding to the target viewing angle from a set of two-dimensional images.
[0046] In actual application, the client obtains the display instruction of the target perspective from the external input, and then determines the two-dimensional target image corresponding to the target perspective based on the two-dimensional image set. Specifically, if the two-dimensional image set includes two-dimensional images corresponding to multiple different perspectives, the two-dimensional target image corresponding to the target perspective can be directly searched from the two-dimensional image set; if the two-dimensional image set includes coded data of two-dimensional images corresponding to multiple different perspectives, the coded data corresponding to the target perspective is decoded to obtain the two-dimensional target image corresponding to the target perspective.
[0047] In the embodiment of the present disclosure, the display instruction is a request for triggering the client to display an image. Optionally, the display instruction can be generated by a user trigger, or can be automatically generated by the client when an application jump occurs.
[0048] It should be noted that the geometric features of the three-dimensional object model are highly refined and will undergo various reflections and refractions, and the material of the three-dimensional object model is rich and extremely complex. The server generates two-dimensional images of the three-dimensional object model from multiple perspectives in advance, and generates a two-dimensional image set of two-dimensional images recorded at multiple different perspectives. The process of downloading the two-dimensional image set to the client does not need to rely on the client to directly download and process the three-dimensional object model, so the two-dimensional target image corresponding to the target perspective can be quickly obtained.
[0049] S130: Display a two-dimensional target image.
[0050] In actual application, after the client determines the two-dimensional target image corresponding to the target viewing angle, the two-dimensional target image can be directly displayed.
[0051] For example, if a user wants to continuously switch the two-dimensional image of a three-dimensional object model on the playback interface of a short video, the client obtains the target perspective corresponding to each switching operation and displays the two-dimensional target image of the target perspective corresponding to each switching operation on the playback interface of the short video.
[0052] The disclosed embodiment provides an image display method, which includes receiving a two-dimensional image set sent by a server, the two-dimensional image set being used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles; in response to a display instruction for the three-dimensional object model at a target viewing angle, parsing a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set; and displaying the two-dimensional target image. Through the above process, the client can directly determine the two-dimensional target image of the target viewing angle from the two-dimensional image set for display, and the complexity and memory usage of the two-dimensional target image are small, so the process of displaying the image by the client will not occupy too much network resources and memory, thereby avoiding freezes in the image display process, and ultimately improving the user's viewing experience.
[0053] In another embodiment of the present disclosure, the client may obtain the encoding data corresponding to the two-dimensional target image under the target perspective from the two-dimensional image set, and parse the encoding data to determine the two-dimensional target image.
[0054] In the embodiment of the present disclosure, optionally, S120 may specifically include the following steps:
[0055] S1201, obtaining coded data corresponding to a two-dimensional target image at a target viewing angle from a two-dimensional image set;
[0056] S1202: Parse the encoded data to obtain a two-dimensional target image corresponding to the target viewing angle.
[0057] Specifically, since the two-dimensional image set includes encoded data corresponding to the two-dimensional images of the three-dimensional object model at multiple different perspectives, the client first obtains the encoded data corresponding to the two-dimensional target image at the target perspective from the two-dimensional image set according to the target perspective, and then uses a decoder such as h265 to parse the encoded data to obtain the two-dimensional target image corresponding to the target perspective.
[0058] The coded data may be a compressed coded product in a binary format corresponding to each viewing angle. Specifically, the coded data corresponding to the two-dimensional images at different viewing angles are obtained by compressing and coding the two-dimensional images at different viewing angles in advance by the server.
[0059] Therefore, the client only needs to obtain the coded data corresponding to the two-dimensional target image under the target perspective from the two-dimensional image set received by the server and parse the coded data, and then the two-dimensional target image corresponding to the target perspective can be obtained and displayed. Therefore, the image display process only uses the decoding capability of the client, has good compatibility, and has low requirements on the client. In addition, the decoding process is simple, easy to implement, and can be mass-produced, so the obtained product is smaller, which enables the client to download the coded data faster.
[0060] In yet another embodiment of the present disclosure, the encoded data includes different attribute information, and the different attribute information is used to mark different information, so that the client displays the corresponding two-dimensional target image based on the different attribute information.
[0061] In order to ensure the parsing accuracy of the coded data and the image display accuracy. In some embodiments, the coded data includes first attribute information of the two-dimensional image, wherein the size information in the first attribute information is used to mark the display size of the two-dimensional image, and the target viewing angle is determined according to the viewing angle information in the first attribute information.
[0062] Specifically, when the client parses the size information from the first attribute information, it can determine the display size of the two-dimensional image according to the size information. The display size refers to the display size of the two-dimensional image. Optionally, the display size may include length, width, height, etc.
[0063] The viewing angle information can be used to mark the viewing angle corresponding to the two-dimensional image. Specifically, when the client parses the viewing angle information from the first attribute information, the target viewing angle can be determined according to the viewing angle information.
[0064] Therefore, in the embodiment of the present disclosure, the client accurately determines the two-dimensional target image by parsing the viewing angle information in the first attribute information included in the encoded data, and displays the two-dimensional target image of the corresponding size based on the size information in the first attribute information, thereby ensuring the parsing accuracy of the encoded data and the image display accuracy.
[0065] In order to improve the visualization effect of image display, color data and transparent data can be fused to generate a two-dimensional target image to meet the user's needs for viewing color and transparency. In some embodiments, the encoded data includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark the position information of different channels of the two-dimensional image in the encoded data.
[0066] Accordingly, S1202 may specifically include the following steps:
[0067] S12021. Acquire, from the second attribute information, position information of a color channel of the two-dimensional target image in the encoded data and position information of a transparency channel of the two-dimensional target image in the encoded data;
[0068] S12022, based on the position information of the color channel of the two-dimensional target image in the coded data, obtaining the color channel code corresponding to the target viewing angle from the coded data;
[0069] S12023, based on the position information of the transparency channel of the two-dimensional target image in the coded data, obtaining the transparency channel code corresponding to the target viewing angle from the coded data;
[0070] S12024. Fuse the color channel encoding and the transparency channel encoding to generate a two-dimensional target image corresponding to the target viewing angle.
[0071] The position information may be the byte offset and byte length of different channels of the two-dimensional image in the encoded data. That is, each two-dimensional image corresponding to each viewing angle has a corresponding byte offset and byte length, and the encoded data of the two-dimensional image corresponding to each viewing angle includes the encoded data of different channels. It can be seen that based on the position information of different channels of the two-dimensional target image in the encoded data, the encoding of different channels corresponding to the target viewing angle can be obtained from the encoded data.
[0072] The color channel may be a YUV channel, and the data corresponding to the color channel is data in a YUV format. The color channel encoding refers to the encoded data corresponding to the color channel of the two-dimensional image.
[0073] Specifically, in the process of compressing and encoding the two-dimensional images corresponding to multiple viewing angles on the server, the server can first obtain multiple images in RGB format as the two-dimensional images corresponding to multiple viewing angles, and then extract image data from the YUV channel of the RGB format image to obtain the image data of the two-dimensional images corresponding to multiple viewing angles in the YUV channel, and then compress and encode the image data of the two-dimensional images corresponding to multiple viewing angles in the YUV channel to obtain the encoded data of the YUV channel of the two-dimensional images corresponding to multiple viewing angles, and each YUV channel of the two-dimensional image corresponds to position information in the encoded data. In this way, after the client receives the encoded data corresponding to multiple viewing angles, the color channel encoding corresponding to the target viewing angle can be directly obtained from the encoded data according to the position information of the color channel of the two-dimensional target image in the encoded data.
[0074] The transparency channel may be an Alpha channel, and the data corresponding to the transparency channel is grayscale data. Transparency channel coding refers to the coded data corresponding to the transparency channel of the two-dimensional image.
[0075] Specifically, in the process of compressing and encoding the two-dimensional images corresponding to multiple perspectives by the server, the server can first obtain multiple images in RGB format as the two-dimensional images corresponding to multiple perspectives, then extract image data from the Alpha channel of the RGB format image to obtain the image data of the two-dimensional images corresponding to multiple perspectives in the Alpha channel, and then compress and encode the image data of the two-dimensional images corresponding to multiple perspectives in the Alpha channel to obtain the encoded data of the Alpha channel of the two-dimensional images corresponding to multiple perspectives, and the Alpha channel of each two-dimensional image has corresponding position information in the encoded data. In this way, after the client receives the encoded data corresponding to multiple perspectives, the transparency channel encoding corresponding to the target perspective can be directly obtained from the encoded data according to the position information of the transparency channel of the two-dimensional target image in the encoded data.
[0076] Furthermore, after obtaining the color channel code and the transparency channel code, the client can fuse the color channel code and the transparency channel code based on the position of the pixel point to generate and display a two-dimensional target image. Thus, the client can display a two-dimensional target image fused with color data and transparency data to meet the user's needs for viewing color and transparency.
[0077] In other embodiments, the client may also generate and display a two-dimensional target image based only on color channel encoding, or may also generate and display a two-dimensional target image based only on transparency channel encoding. Thus, the client may display a two-dimensional target image of a single channel to the user.
[0078] It should be noted that the image frame types corresponding to two-dimensional images of different viewing angles are different, so that the coded data includes different data frame types, and the acquisition methods of the coded data corresponding to different frame types are different. Therefore, in order to ensure that the coded data of all data frame types are found, in some embodiments, the coded data also includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark the data frame types of different channels of the two-dimensional image in the coded data;
[0079] Accordingly, S12022 may specifically include the following steps:
[0080] S10, acquiring a data frame type of a color channel corresponding to a target viewing angle from the encoded data according to the third attribute information;
[0081] S11. If the data frame type of the color channel corresponding to the target viewing angle is a non-key frame type, obtaining the key frame code and the non-key frame code of the color channel corresponding to the target viewing angle from the encoded data according to the position information of the color channel corresponding to the target viewing angle, and generating the color channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the color channel corresponding to the target viewing angle;
[0082] S12. If the data frame type of the color channel corresponding to the target viewing angle is a key frame type, the key frame code of the color channel corresponding to the target viewing angle is obtained from the encoded data according to the position information of the color channel corresponding to the target viewing angle, and the key frame code of the color channel corresponding to the target viewing angle is used as the color channel code corresponding to the target viewing angle.
[0083] Accordingly, S12023 may specifically include the following steps:
[0084] S20, acquiring a data frame type of a transparency channel corresponding to a target viewing angle from the encoded data according to the third attribute information;
[0085] S21. If the data frame type of the transparency channel corresponding to the target viewing angle is a non-key frame type, obtaining the key frame code and the non-key frame code of the transparency channel corresponding to the target viewing angle from the encoded data according to the position information of the transparency channel corresponding to the target viewing angle, and generating the transparency channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the transparency channel corresponding to the target viewing angle;
[0086] S22. If the data frame type of the transparency corresponding to the target viewing angle is a key frame type, the key frame code of the transparency channel corresponding to the target viewing angle is obtained from the encoded data according to the position information of the transparency corresponding to the target viewing angle, and the key frame code of the transparency channel corresponding to the target viewing angle is used as the transparency channel code corresponding to the target viewing angle.
[0087] The data frame type is the frame type of the two-dimensional image, and the two-dimensional images corresponding to different viewing angles correspond to unique frame types. The two-dimensional image may include a key frame type image and a non-key frame image, and the encoded data may include key frame encoding and non-key frame encoding.
[0088] In order to improve the encoding efficiency of the server for two-dimensional images, the acquired two-dimensional images of multiple perspectives can be grouped, and compression encoding can be performed for the two-dimensional images in each group. Specifically, the two-dimensional images corresponding to 9 consecutively spaced perspectives can be manually divided into a group, wherein a two-dimensional image located at the center position in each group of two-dimensional images is marked as a two-dimensional image of the key frame type, and 8 two-dimensional images located at non-center positions in each group of two-dimensional images are marked as two-dimensional images of the non-key frame type. When the server compresses and encodes each group of two-dimensional images, it can be determined that the encoding data corresponding to the one two-dimensional image located at the center position in each group of two-dimensional images is key frame encoding, and it can be determined that the encoding data corresponding to the 8 two-dimensional images located at non-center positions in each group of two-dimensional images is non-key frame encoding.
[0089] It should be noted that, in the process of using the server to compress and encode each group of two-dimensional images, all the compression codes corresponding to the two-dimensional images of the key frame type are used as key frame codes, and part of the compression codes corresponding to the two-dimensional images of the non-key frame type are used as key frame codes, and the other part is used as non-key frame codes. Therefore, for the color channel, when the client obtains the encoded data under different channels corresponding to the target perspective, if the data frame type of the color channel corresponding to the target perspective is a non-key frame type, it is necessary to obtain the key frame code and non-key frame code of the color channel corresponding to the target perspective, and generate the color channel code corresponding to the target perspective based on the partial code and non-key frame code in the key frame code; if the data frame type of the color channel corresponding to the target perspective is a key frame type, the key frame code of the color channel corresponding to the target perspective is directly used as the color channel code corresponding to the target perspective.
[0090] Among them, the key frame encoding corresponding to the target view refers to the encoding data of the key frame in the group where the target view is located. The non-key frame encoding corresponding to the target view refers to the encoding data actually corresponding to the view. It should be noted that the principle of determining the transparency channel encoding is the same as the principle of determining the color channel encoding, which will not be repeated here.
[0091] For ease of understanding, the color channel encoding and transparency channel encoding corresponding to each set of two-dimensional images can be expressed as follows:
[0092] Color channel encoding IPPPPPPPP Transparency channel coding IPPPPPPPP
[0093] Among them, the color channel encoding corresponding to each group of two-dimensional images in the above table includes one key frame (I) encoding and 8 non-key frame (P) encodings, and the transparency channel encoding corresponding to each group of two-dimensional images includes one key frame (I) encoding and 8 non-key frame (P) encodings.
[0094] Therefore, for different data frame types, the encoded data of different data frame types can be obtained based on different logics. For the color channel and the transparency channel, the comprehensiveness and accuracy of the encoded data acquisition of the two channels are guaranteed.
[0095] In order to quickly and conveniently obtain the encoded data corresponding to different perspectives, in some embodiments, the encoded data includes a protocol header, wherein the protocol header includes one or more combinations of first attribute information, second attribute information, and third attribute information.
[0096] In order to further improve the efficiency of the client in parsing the encoded data, the client can store the protocol header in the encoding locally, and then obtain and quickly parse the encoded data locally.
[0097] In the embodiment of the present disclosure, optionally, before S1202, the method further includes the following steps:
[0098] Based on the protocol header format corresponding to each perspective, the protocol header corresponding to each perspective is stored in a preset storage structure;
[0099] Accordingly, S1202 may specifically include the following steps:
[0100] A target protocol header corresponding to the target viewing angle is obtained from a preset storage structure, and coded data corresponding to the target protocol header is parsed to obtain a two-dimensional target image corresponding to the target viewing angle.
[0101] The preset storage structure may be a memory storage structure corresponding to the client, specifically a Map structure. Map is a collection that maps key objects and value objects, and each element of Map includes a pair of key objects and value objects.
[0102] Optionally, the code of the protocol header in the preset storage structure may be in the following structure:
[0103] {
[0104] "Longitude,Latitude":[
[0105] {
[0106] "Frame Type":"I / P",
[0107] "Offset":"Current Offset",
[0108] "Length":"Current Frame Length",
[0109] "Alpha_Offset":"Current Frame Alpha Offset",
[0110] "Alpha_Length":"Current Frame Alpha length",
[0111] "I_Offset":"Reference I Frame Offset",
[0112] "I_Length":"Reference I Frame Length",
[0113] "Alpha_I_Offset":"Reference I Frame Alpha Offset",
[0114] "Alpha_I_Length":"Reference I Frame Alpha Length",
[0115] }
[0116] }
[0117] }
[0118] Therefore, in the decoding stage, by parsing the protocol header from the preset storage structure corresponding to the client, the encoded data corresponding to the target perspective can be quickly parsed, thereby improving the parsing efficiency of the two-dimensional target image corresponding to the target perspective and further optimizing the image display efficiency.
[0119] In order to facilitate understanding of the acquisition logic of the encoded data of different channels corresponding to the target perspective, as well as the acquired encoded data of the non-keyframe type and the encoded data of the keyword type. Figure 2 A logical schematic diagram of an image display method provided by an embodiment of the present disclosure is shown.
[0120] like Figure 2 As shown, the image display method includes the following process:
[0121] S210: Receive a two-dimensional image set sent by a server, where the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles.
[0122] S220 , in response to a display instruction for the three-dimensional object model at a target viewing angle, parsing a two-dimensional target image corresponding to the target viewing angle from a set of two-dimensional images.
[0123] Specifically, before S220, the client may store the protocol header corresponding to each perspective in a preset storage structure, such as a map, based on the protocol header format corresponding to each perspective.
[0124] S230: Obtain a target protocol header corresponding to the target perspective from a preset storage structure.
[0125] S240. Parse the first attribute information in the target protocol header corresponding to the target perspective.
[0126] The size information in the first attribute information is used to mark the display size of the two-dimensional image, and the target viewing angle is determined according to the viewing angle information in the first attribute information.
[0127] S250. Obtain position information of the color channel of the two-dimensional target image in the encoded data from the second attribute information in the target protocol header.
[0128] The second attribute information is used to mark the position information of different channels of the two-dimensional image in the encoded data.
[0129] S260. According to the third attribute information in the target protocol header, obtain the data frame type of the color channel corresponding to the target viewing angle from the encoded data.
[0130] The third attribute information is used to mark the data frame types of different channels of the two-dimensional image in the encoded data.
[0131] S270: Determine whether the data frame type of the color channel is a key frame type.
[0132] Specifically, if the data frame type of the color channel is a key frame type, execute S280, otherwise, execute S290.
[0133] S280. According to the position information of the color channel corresponding to the target viewing angle, obtain the key frame code of the color channel corresponding to the target viewing angle from the encoded data, and use the key frame code of the color channel corresponding to the target viewing angle as the color channel code corresponding to the target viewing angle.
[0134] S290. According to the position information of the color channel corresponding to the target viewing angle, the key frame code and non-key frame code of the color channel corresponding to the target viewing angle are obtained from the encoded data, and according to the key frame code and non-key frame code of the color channel corresponding to the target viewing angle, the color channel code corresponding to the target viewing angle is generated.
[0135] S291. Obtain position information of a transparency channel of a two-dimensional target image in the encoded data from the second attribute information in the target protocol header.
[0136] S292. According to the third attribute information in the target protocol header, obtain the data frame type of the transparency channel corresponding to the target viewing angle from the encoded data.
[0137] S293: Determine whether the data frame type of the transparency channel is a key frame type.
[0138] Specifically, if the data frame type of the transparency channel is a key frame type, execute S294, otherwise, execute S295.
[0139] S294. According to the position information of the transparency channel corresponding to the target viewing angle, the key frame code of the transparency channel corresponding to the target viewing angle is obtained from the encoded data, and the key frame code of the transparency channel corresponding to the target viewing angle is used as the transparency channel code corresponding to the target viewing angle.
[0140] S295. According to the position information of the transparency channel corresponding to the target viewing angle, the key frame code and non-key frame code of the transparency channel corresponding to the target viewing angle are obtained from the encoded data, and according to the key frame code and non-key frame code of the transparency channel corresponding to the target viewing angle, the transparency channel code corresponding to the target viewing angle is generated.
[0141] S296, fusing the color channel coding and the transparency channel coding to generate a two-dimensional target image corresponding to the target viewing angle and display it.
[0142] In another embodiment of the present disclosure, an image processing method for reducing network transmission resources and memory usage is provided, wherein the image processing method can be applied to a server, wherein the server can be a cloud server or a server cluster.
[0143] Figure 3 FIG. 1 is a flow chart of an image processing method provided by an embodiment of the present disclosure. Figure 3 As shown, the image processing method includes the following steps.
[0144] S310: Acquire a set of two-dimensional images generated from a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record two-dimensional images of the three-dimensional object model at multiple different viewing angles.
[0145] It is understandable that the specific form of the viewing angle can be longitude and latitude. Specifically, the latitude range can be set to [-90, 90] and the longitude range can be set to [0, 360]. For a three-dimensional object model, an image is collected every 6 degrees, and 360 / 6*(180 / 6+1)=1860 two-dimensional images can be collected. If the two-dimensional images are divided into a group every 18 degrees, (180 / 18+1)*(360 / 18)=220 groups of two-dimensional images can be obtained. Specifically, except for the north and south poles, the above-mentioned number of two-dimensional images can be divided into a group of 3*3, that is, 9 images are combined into a group, totaling (180 / 6-1)*(360 / 6)=1740 two-dimensional images, and the two-dimensional image located at the center position in each group of images is set as a key frame type image, and the two-dimensional image located at a non-center position in each group of images is set as a non-key frame type image; for the north and south poles (*, -90) and (*, 90), the two-dimensional images are combined into a group of 6 images in 3*2, the poles are key frame type images, and the peripheral 5 are non-key frame type images, totaling 2*(360 / 6)=120 images.
[0146] To facilitate understanding of the acquisition process of two-dimensional images, Figure 4 A schematic diagram of acquiring a two-dimensional image is shown.
[0147] like Figure 4As shown, for a three-dimensional object model, a two-dimensional image can be collected every 6 degrees. For example, a two-dimensional image is collected at viewing angles such as (-6,6), (0,0), and (-6,0). Then, 9 two-dimensional images can be obtained and the 9 two-dimensional images are taken as a group, wherein the two-dimensional image at the center position in each group of two-dimensional images is set as a key frame type image, and the two-dimensional image at a non-center position is set as a non-key frame type image. The key frame type image in each group of two-dimensional images can be used as a reference for the non-key frame type image, and each group of two-dimensional images includes 1 key frame type image and 8 non-key frame type images.
[0148] S320: Send the two-dimensional image set to the client, so that the client parses and displays the two-dimensional target image corresponding to the target viewing angle.
[0149] In some embodiments, the server may directly send a two-dimensional image set including two-dimensional images corresponding to multiple perspectives to the client, so that the client searches for and displays a two-dimensional target image corresponding to a target perspective from the two-dimensional images.
[0150] In other embodiments, the server may compress and encode the two-dimensional images corresponding to multiple perspectives to obtain encoded data, obtain a two-dimensional image set that records the two-dimensional images at multiple different perspectives, and send the two-dimensional image set to the client so that the client can parse and display the two-dimensional target image corresponding to the target perspective.
[0151] The disclosed embodiment provides an image processing method, wherein a server obtains a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the two-dimensional image set is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles; and the two-dimensional image set is sent to a client, so that the client parses and displays the two-dimensional target image corresponding to the target viewing angle. Through the above process, the processing process of the three-dimensional object model is executed in the server, so that the client can directly obtain and display the two-dimensional target image corresponding to the target viewing angle. Therefore, the process of displaying the image by the client will not occupy too much network resources and memory, thereby avoiding freezes in the image display process, and ultimately improving the user's interactive experience of viewing the image display process.
[0152] In another embodiment of the present disclosure, after the server compresses and encodes the two-dimensional images corresponding to the multiple viewing angles, it sends the encoded data corresponding to the multiple viewing angles to the client.
[0153] In the embodiment of the present disclosure, optionally, S310 may specifically include the following steps:
[0154] The two-dimensional images at multiple different viewing angles are compressed and encoded to generate encoding data at multiple different viewing angles, and the encoding data at multiple different viewing angles are used as a two-dimensional image set.
[0155] Specifically, in the process of the server generating encoded data, the server can use an encoder such as h265 to compress and encode two-dimensional images at multiple different perspectives, generate encoded data corresponding to the two-dimensional images at multiple different perspectives, that is, generate a binary file, and use the encoded data at multiple different perspectives as a two-dimensional image set.
[0156] Optionally, the coded data may include parameter coding and coded body, wherein the parameter coding refers to the parameters after the two-dimensional image is coded, and the coded body refers to the body of the coded data.
[0157] Optionally, parameter coding may include parameters such as video parameter set (VPS_NUT), sequence parameter set (SPS_NUT) and (PPS_NUT).
[0158] In order to further reduce the resources occupied by the coded data, only one copy of the above parameter coding may be retained for the coded data corresponding to the two-dimensional images in each group. In some cases, if nine two-dimensional images are taken as a group, the coded data corresponding to each group of two-dimensional images may be represented as follows:
[0159]
[0160]
[0161] Therefore, in the disclosed embodiment, the server can compress and encode two-dimensional images from multiple different perspectives to generate a smaller binary file, and send the binary file to the client, so that the client can download the encoded data in a very short time.
[0162] In order to facilitate the client to accurately parse the encoded data, the encoded data includes a variety of attribute information.
[0163] In some embodiments, the encoded data includes first attribute information of the two-dimensional image, wherein the size information in the first attribute information is used to mark the display size of the two-dimensional image, and the viewing angle information in the first attribute information is used to mark the viewing angle of the two-dimensional image.
[0164] In other embodiments, the encoded data also includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark position information of different channels of the two-dimensional image in the encoded data, so that the client can obtain data of different channels of the two-dimensional image corresponding to the target perspective from the encoded data according to the position information.
[0165] In some further embodiments, the encoded data also includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark data frame types of different channels of the two-dimensional image in the encoded data, so that the client can decode and process data of different channels of the two-dimensional image corresponding to the target perspective according to the data frame type.
[0166] Furthermore, in order to quickly and conveniently obtain the coded data corresponding to different viewing angles, in some embodiments, the server may also add a protocol header to the coded data of the two-dimensional image corresponding to each viewing angle.
[0167] Specifically, the server may add a protocol header to the coded data of the two-dimensional image corresponding to each viewing angle based on a preset protocol header protocol, thereby obtaining coded data carrying the protocol header.
[0168] Optionally, the preset header file protocol may be an autoregressive (AR) protocol.
[0169] The protocol header may be one or more combinations of the first attribute information, the second attribute information and the third attribute information.
[0170] Optionally, the protocol header can be in the following format:
[0171]
[0172]
[0173] Therefore, in the encoding stage, the protocol header can mark various information of the corresponding encoded data. For the subsequent decoding stage, it can facilitate the client to quickly obtain the encoded data corresponding to different perspectives, and ultimately optimize the image display efficiency.
[0174] In another embodiment of the present disclosure, in order to facilitate understanding of the image processing process and the image display process, Figure 5 A logical schematic diagram of an image processing and display method is shown.
[0175] like Figure 5 As shown, the image processing and display process includes the following steps:
[0176] S510: Acquire two-dimensional images generated from a three-dimensional object model at multiple viewing angles.
[0177] S520 , obtaining image data in color channels of two-dimensional images corresponding to multiple viewing angles.
[0178] S530 , obtaining image data in a transparency channel of two-dimensional images corresponding to multiple viewing angles.
[0179] S540 , compress and encode the image data in the color channels of the two-dimensional images corresponding to the multiple viewing angles to obtain the color channel codes corresponding to the multiple viewing angles.
[0180] S550 , compress and encode the image data in the transparency channel of the two-dimensional images corresponding to the multiple viewing angles to obtain the transparency channel codes corresponding to the multiple viewing angles.
[0181] S560: Combine the color channel codes corresponding to the multiple viewing angles and the transparency channel codes corresponding to the multiple viewing angles to obtain the coded data of the two-dimensional images corresponding to the multiple viewing angles.
[0182] S570. Add a protocol header to the coded data of the two-dimensional images corresponding to the multiple perspectives to generate a set of two-dimensional images of the three-dimensional object model generated at the multiple perspectives, wherein the two-dimensional image set is used to record the two-dimensional images of the three-dimensional object model at multiple different perspectives.
[0183] It should be noted that S510 to S570 are all executed by the server.
[0184] S580: Receive a two-dimensional image set sent by the server.
[0185] S590: In response to a display instruction for the three-dimensional object model at a target viewing angle, parse a protocol header included in the coded data corresponding to the target viewing angle.
[0186] S591. Based on the attribute information in the protocol header, obtain the color channel encoding corresponding to the target viewing angle from the encoded data.
[0187] S592. Based on the attribute information in the protocol header, obtain the transparency channel code corresponding to the target viewing angle from the encoded data.
[0188] S593: The color channel code corresponding to the target viewing angle and the transparency channel code corresponding to the target viewing angle are correspondingly fused to obtain a two-dimensional target image corresponding to the target viewing angle and display it.
[0189] Among them, S580~S593 are all executed by the server.
[0190] Based on the same inventive concept as the above method embodiment, the present disclosure also provides an image display device, which is configured on a client. Figure 6 , a schematic diagram of the structure of an image display device provided in an embodiment of the present disclosure, the image display device 600 includes:
[0191] A receiving module 601 is used to receive a two-dimensional image set sent by a server, where the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles;
[0192] A parsing module 602 is configured to, in response to a display instruction for the three-dimensional object model at a target viewing angle, parse a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set;
[0193] The image display module 603 is used to display the two-dimensional target image.
[0194] The disclosed embodiment provides an image display device, which receives a two-dimensional image set sent by a server, and the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles; in response to a display instruction for the three-dimensional object model at a target viewing angle, parses a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set; and displays the two-dimensional target image. Through the above process, the client can directly determine the two-dimensional target image of the target viewing angle from the two-dimensional image set for display, and the complexity and memory usage of the two-dimensional target image are small, so the process of displaying the image by the client does not occupy too much network resources and memory, thereby avoiding freezes in the image display process, and ultimately improving the user's viewing experience.
[0195] In an optional implementation, the parsing module 602 includes:
[0196] An acquisition unit, configured to acquire, from the two-dimensional image set, coded data corresponding to the two-dimensional target image at the target viewing angle;
[0197] A parsing unit is used to parse the coded data to obtain a two-dimensional target image corresponding to the target viewing angle.
[0198] In an optional implementation, the encoded data includes first attribute information of the two-dimensional image, wherein the size information in the first attribute information is used to mark the display size of the two-dimensional image, and the target viewing angle is determined based on the viewing angle information in the first attribute information.
[0199] In an optional implementation manner, the coded data includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark position information of different channels of the two-dimensional image in the coded data;
[0200] Correspondingly, the parsing unit is specifically used to obtain, from the second attribute information, position information of the color channel of the two-dimensional target image in the encoded data and position information of the transparency channel of the two-dimensional target image in the encoded data;
[0201] Based on position information of a color channel of the two-dimensional target image in the coded data, acquiring a color channel code corresponding to the target viewing angle from the coded data;
[0202] Based on the position information of the transparency channel of the two-dimensional target image in the coded data, obtaining the transparency channel code corresponding to the target viewing angle from the coded data;
[0203] The color channel encoding and the transparency channel encoding are fused to generate a two-dimensional target image corresponding to the target viewing angle.
[0204] In an optional implementation manner, the coded data further includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark data frame types of different channels of the two-dimensional image in the coded data;
[0205] Correspondingly, the parsing unit is further used to obtain, according to the third attribute information, a data frame type of a color channel corresponding to the target viewing angle from the encoded data;
[0206] If the data frame type of the color channel corresponding to the target viewing angle is a non-key frame type, obtaining a key frame code and a non-key frame code of the color channel corresponding to the target viewing angle from the encoded data according to position information of the color channel corresponding to the target viewing angle, and generating a color channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the color channel corresponding to the target viewing angle;
[0207] If the data frame type of the color channel corresponding to the target viewing angle is a key frame type, the key frame code of the color channel corresponding to the target viewing angle is obtained from the encoded data according to the position information of the color channel corresponding to the target viewing angle, and the key frame code of the color channel corresponding to the target viewing angle is used as the color channel code corresponding to the target viewing angle.
[0208] In an optional implementation manner, the data parsing unit is further configured to obtain, according to the third attribute information, a data frame type of a transparency channel corresponding to the target viewing angle from the encoded data;
[0209] If the data frame type of the transparency channel corresponding to the target viewing angle is a non-key frame type, obtaining a key frame code and a non-key frame code of the transparency channel corresponding to the target viewing angle from the encoded data according to the position information of the transparency channel corresponding to the target viewing angle, and generating a transparency channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the transparency channel corresponding to the target viewing angle;
[0210] If the data frame type of the transparency corresponding to the target viewing angle is a key frame type, the key frame code of the transparency channel corresponding to the target viewing angle is obtained from the encoded data based on the position information of the transparency corresponding to the target viewing angle, and the key frame code of the transparency channel corresponding to the target viewing angle is used as the transparency channel code corresponding to the target viewing angle.
[0211] In an optional implementation, the encoded data includes a protocol header, wherein the protocol header includes one or more combinations of first attribute information, second attribute information, and third attribute information.
[0212] Based on the same inventive concept as the above method embodiment, the present disclosure also provides an image processing device, which is configured on a server. Figure 7 , a schematic diagram of the structure of an image processing device provided in an embodiment of the present disclosure, the image processing device 700 includes:
[0213] An acquisition module 701 is used to acquire a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles;
[0214] The sending module 702 is used to send the two-dimensional image set to the client, so that the client can parse and display the two-dimensional target image corresponding to the target viewing angle.
[0215] The disclosed embodiment provides an image processing device, wherein a server obtains a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the two-dimensional image set is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles; and the two-dimensional image set is sent to a client, so that the client parses and displays the two-dimensional target image corresponding to the target viewing angle. Through the above process, the processing process of the three-dimensional object model is executed in the server, so that the client can directly obtain and display the two-dimensional target image corresponding to the target viewing angle. Therefore, the process of displaying the image by the client will not occupy too much network resources and memory, thereby avoiding freezes in the image display process, and ultimately improving the user's interactive experience of watching the image display process.
[0216] In an optional implementation manner, the sending module 702 includes:
[0217] The compression coding unit is used to compress and code the two-dimensional images at the multiple different viewing angles, generate the coded data at the multiple different viewing angles, and use the coded data at the multiple different viewing angles as the two-dimensional image set.
[0218] In an optional implementation, the encoded data includes first attribute information of the two-dimensional image, wherein the size information in the first attribute information is used to mark the display size of the two-dimensional image, and the viewing angle information in the first attribute information is used to mark the viewing angle of the two-dimensional image.
[0219] In an optional embodiment, the encoded data also includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark position information of different channels of the two-dimensional image in the encoded data, so that the client obtains data of different channels of the two-dimensional image corresponding to the target perspective from the encoded data according to the position information.
[0220] In an optional embodiment, the encoded data also includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark the data frame types of different channels of the two-dimensional image in the encoded data, so that the client decodes and processes the data of different channels of the two-dimensional image corresponding to the target perspective according to the data frame type.
[0221] In addition to the above-mentioned methods and apparatus, the embodiments of the present disclosure further provide a computer-readable storage medium, in which instructions are stored. When the instructions are executed on a terminal device, the terminal device implements the image display method or image processing method of the embodiments of the present disclosure.
[0222] The embodiments of the present disclosure further provide a computer program product, which includes a computer program / instructions. When the computer program / instructions are executed by a processor, the image display method or image processing method of the embodiments of the present disclosure is implemented.
[0223] Figure 8 A schematic diagram of the structure of a client or server provided by an embodiment of the present disclosure is shown.
[0224] like Figure 8 As shown, the client or server may include a controller 801 and a memory 802 storing computer program instructions.
[0225] Specifically, the controller 801 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.
[0226] The memory 802 may include a large capacity memory for information or instructions. By way of example and not limitation, the memory 802 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a tape, or a universal serial bus (USB) drive or a combination of two or more of these. Where appropriate, the memory 802 may include a removable or non-removable (or fixed) medium. Where appropriate, the memory 802 may be inside or outside the integrated gateway device. In a particular embodiment, the memory 802 is a non-volatile solid-state memory. In a particular embodiment, the memory 802 includes a read-only memory (ROM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (Electrically Erasable Programmable ROM, EEPROM), an electrically rewritable ROM (EAROM) or a flash memory, or a combination of two or more of these.
[0227] The controller 801 reads and executes the computer program instructions stored in the memory 802 to execute the steps of the image display method provided by the embodiment of the present disclosure, or executes the steps of the image processing method provided by the embodiment of the present disclosure.
[0228] In one example, the client or server may further include a transceiver 803 and a bus 804. Figure 8 As shown, the controller 801, the memory 802 and the transceiver 803 are connected via a bus 804 and communicate with each other.
[0229] The bus 804 includes hardware, software, or both. For example, but not limitation, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Extended Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), a Hyper Transport (HT) interconnect, an Industrial Standard Architecture (ISA) bus, an InfiniBand interconnect, a Low Pin Count (LPC) bus, a Memory bus, a MicroChannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local Bus (VLB) bus, or other suitable buses or a combination of two or more of these. Where appropriate, the bus 804 may include one or more buses. Although embodiments of the present application describe and illustrate a particular bus, the present application contemplates any suitable bus or interconnect.
[0230] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0231] The above are only specific embodiments of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to these embodiments herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. An image display method, characterized in that: Applied to a client, the method comprises: Receiving a two-dimensional image set sent by a server, where the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles; In response to a display instruction for the three-dimensional object model at a target viewing angle, parsing a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set; Displaying the two-dimensional target image; The step of parsing the two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set includes: Acquire, from the two-dimensional image set, coded data corresponding to the two-dimensional target image at the target viewing angle, the coded data including second attribute information of the two-dimensional image, wherein the second attribute information is used to mark position information of different channels of the two-dimensional image in the coded data, and the different channels of the two-dimensional image include a color channel and a transparency channel; The encoded data is parsed to obtain a two-dimensional target image corresponding to the target viewing angle.
2. The method according to claim 1, characterized in that The encoded data includes first attribute information of the two-dimensional image, wherein size information in the first attribute information is used to mark the display size of the two-dimensional image, and the target viewing angle is determined according to the viewing angle information in the first attribute information.
3. The method according to claim 1, characterized in that: The parsing of the coded data to obtain a two-dimensional target image corresponding to the target viewing angle includes: Acquire, from the second attribute information, position information of the color channel of the two-dimensional target image in the encoded data and position information of the transparency channel of the two-dimensional target image in the encoded data; Based on position information of a color channel of the two-dimensional target image in the coded data, acquiring a color channel code corresponding to the target viewing angle from the coded data; Based on the position information of the transparency channel of the two-dimensional target image in the coded data, obtaining the transparency channel code corresponding to the target viewing angle from the coded data; The color channel encoding and the transparency channel encoding are fused to generate a two-dimensional target image corresponding to the target viewing angle.
4. The method according to claim 3, characterized in that The coded data further includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark data frame types of different channels of the two-dimensional image in the coded data; Correspondingly, the acquiring, based on the position information of the color channel, the color channel code corresponding to the target viewing angle from the coded data includes: According to the third attribute information, acquiring a data frame type of a color channel corresponding to the target viewing angle from the encoded data; If the data frame type of the color channel corresponding to the target viewing angle is a non-key frame type, obtaining a key frame code and a non-key frame code of the color channel corresponding to the target viewing angle from the encoded data according to position information of the color channel corresponding to the target viewing angle, and generating a color channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the color channel corresponding to the target viewing angle; If the data frame type of the color channel corresponding to the target viewing angle is a key frame type, the key frame code of the color channel corresponding to the target viewing angle is obtained from the encoded data according to the position information of the color channel corresponding to the target viewing angle, and the key frame code of the color channel corresponding to the target viewing angle is used as the color channel code corresponding to the target viewing angle.
5. The method according to claim 4, characterized in that The obtaining, from the coded data, a transparency channel code corresponding to the target viewing angle based on the position information of the transparency channel, comprises: According to the third attribute information, acquiring a data frame type of a transparency channel corresponding to the target viewing angle from the encoded data; If the data frame type of the transparency channel corresponding to the target viewing angle is a non-key frame type, obtaining a key frame code and a non-key frame code of the transparency channel corresponding to the target viewing angle from the encoded data according to the position information of the transparency channel corresponding to the target viewing angle, and generating a transparency channel code corresponding to the target viewing angle according to the key frame code and the non-key frame code of the transparency channel corresponding to the target viewing angle; If the data frame type of the transparency corresponding to the target viewing angle is a key frame type, the key frame code of the transparency channel corresponding to the target viewing angle is obtained from the encoded data based on the position information of the transparency corresponding to the target viewing angle, and the key frame code of the transparency channel corresponding to the target viewing angle is used as the transparency channel code corresponding to the target viewing angle.
6. The method according to any one of claims 1 to 5, characterized in that: The encoded data includes a protocol header, wherein the protocol header also includes one or more combinations of first attribute information and third attribute information.
7. An image processing method, characterized in that: Applied to a server, the method comprises: Acquire a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles; Sending the two-dimensional image set to a client, so that the client parses and displays the two-dimensional target image corresponding to the target viewing angle; The step of obtaining a set of two-dimensional images generated from a three-dimensional object model at multiple viewing angles includes: The two-dimensional images at the multiple different viewing angles are compressed and encoded to generate the encoded data at the multiple different viewing angles, and the encoded data at the multiple different viewing angles are used as the two-dimensional image set, wherein the encoded data includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark the position information of different channels of the two-dimensional image in the encoded data, and the different channels of the two-dimensional image include a color channel and a transparency channel.
8. The method according to claim 7, characterized in that The encoded data includes first attribute information of the two-dimensional image, wherein the size information in the first attribute information is used to mark the display size of the two-dimensional image, and the viewing angle information in the first attribute information is used to mark the viewing angle of the two-dimensional image.
9. The method according to claim 7, characterized in that: The client obtains data of different channels of the two-dimensional image corresponding to the target viewing angle from the encoded data according to the position information.
10. The method according to claim 9, characterized in that The encoded data also includes third attribute information of the two-dimensional image, wherein the third attribute information is used to mark data frame types of different channels of the two-dimensional image in the encoded data, so that the client decodes and processes data of different channels of the two-dimensional image corresponding to the target viewing angle according to the data frame type.
11. An image display device, characterized in that: The device is configured on a client, and includes: A receiving module, used to receive a two-dimensional image set sent by a server, wherein the two-dimensional image set is used to record two-dimensional images of a three-dimensional object model at multiple different viewing angles; A parsing module, configured to respond to a display instruction for the three-dimensional object model at a target viewing angle and parse a two-dimensional target image corresponding to the target viewing angle from the two-dimensional image set; An image display module, used for displaying the two-dimensional target image; The parsing module comprises: an acquisition unit, configured to acquire, from the two-dimensional image set, coded data corresponding to the two-dimensional target image at the target viewing angle, the coded data comprising second attribute information of the two-dimensional image, wherein the second attribute information is used to mark position information of different channels of the two-dimensional image in the coded data, and the different channels of the two-dimensional image comprise a color channel and a transparency channel; A parsing unit is used to parse the coded data to obtain a two-dimensional target image corresponding to the target viewing angle.
12. An image processing device, characterized in that: The device is configured on a server, and includes: An acquisition module, used to acquire a set of two-dimensional images generated by a three-dimensional object model at multiple viewing angles, wherein the set of two-dimensional images is used to record the two-dimensional images of the three-dimensional object model at multiple different viewing angles; A sending module, used for sending the two-dimensional image set to a client, so that the client can parse and display the two-dimensional target image corresponding to the target viewing angle; The acquisition module is used to compress and encode the two-dimensional images at the multiple different viewing angles, generate the encoded data at the multiple different viewing angles, and use the encoded data at the multiple different viewing angles as the two-dimensional image set, wherein the encoded data includes second attribute information of the two-dimensional image, wherein the second attribute information is used to mark the position information of different channels of the two-dimensional image in the encoded data, and the different channels of the two-dimensional image include a color channel and a transparency channel.
13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, and when the instructions are executed on a terminal device, the terminal device implements the method according to any one of claims 1 to 6 or any one of claims 7 to 10.
14. A device, characterized in that include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the method according to any one of claims 1 to 6 or any one of claims 7 to 10 is implemented.
15. A computer program product, characterized in that The computer program product comprises a computer program / instruction, and when the computer program / instruction is executed by a processor, the method according to any one of claims 1 to 6 or the method according to any one of claims 7 to 10 is implemented.
Citation Information
Patent Citations
Three-dimensional model display method and device, storage medium and electronic equipment
CN113559498A