Commodity information display method and electronic device

By using layered panoramic offline rendering technology, high-quality panoramic layers are generated and overlaid in real time, solving the problems of high rendering costs and poor interactivity in home decoration, furniture and home appliance product information service scenarios, and realizing efficient product matching display and interactive experience.

CN119784460BActive Publication Date: 2025-11-25ZHEJIANG TMALL TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411685475.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-22
Publication Date
2025-11-25
Estimated Expiration
2044-11-22

AI Technical Summary

Technical Problem

Existing technologies in home decoration, furniture and appliance product information service scenarios suffer from high rendering costs and poor interactivity, making it difficult to effectively display product matching effects.

Method used

Employing ray tracing-based offline panoramic rendering technology, layered background and foreground panoramic layers are generated. High-quality panoramic layers are produced through offline rendering, and the layers are overlaid during the real-time rendering stage to provide an interactive experience.

Benefits of technology

It achieves high-quality product pairing display, shortens loading time, improves rendering quality and interactive experience, and reduces rendering costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119784460B_ABST
    Figure CN119784460B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a commodity information display method and an electronic device. The method comprises: determining a 3D space model and 3D commodity models of a plurality of commodities; performing offline rendering of a panorama based on ray tracing on the 3D space model to obtain a background panorama layer; placing a single 3D commodity model into a target position corresponding to a category in the 3D space model respectively, setting material parameters of the 3D space model to be transparent and retaining light and shadow information, and then performing offline rendering of a panorama based on ray tracing to obtain foreground panorama layers corresponding to the plurality of 3D commodity models respectively; determining an overlay order between layers corresponding to a plurality of target positions; and overlaying the background panorama layer and the foreground panorama layers corresponding to the plurality of commodities respectively according to the overlay order to generate a panorama stereogram for displaying commodity information. Through the embodiments of the present application, the rendering quality can be improved, the loading time can be shortened, and an interactive experience can be provided for users.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of information processing, and particularly relates to a commodity information display method and an electronic device. BACKGROUND

[0002] In the commodity information service scene of home furnishing and home appliances, users exist a pain point that they have clear home space style demands, but do not know which commodities and commodity collocation effects to buy in the later stage of hard decoration and the early stage of soft decoration. For users, they hope to view single product details and collocation effects through tools; for merchants, they hope to promote single product purchase and cross-product category purchase so that consumers buy more commodities. In view of the above-mentioned pain point, commodity display applications based on indoor 3D scene data have emerged as the times require. The so-called indoor 3D scene data refers to a data set representing a three-dimensional scene and objects in the scene generated by a professional three-dimensional scene design software, which contains the geometric shape, position, texture, lighting and other attributes of three-dimensional objects in the three-dimensional scene, and this data can be used to describe the object and spatial relationship of the indoor design scheme in the virtual environment or actual environment, so that users can more intuitively view the collocation effect of specific commodities in specific space stations and obtain a "what you see is what you get" shopping experience.

[0003] However, when displaying collocation effects, multiple different category commodity models usually need to be placed in the space model for display collocation effect display. The number of commodities in the system or store is large, and there may be multiple different commodities under the same category. In principle, these multiple different commodities can be replaced with each other, which may result in a very large number of combinations. Therefore, how to display these collocation effects to users is a problem that needs to be considered.

[0004] In the prior art, there are mainly two implementation schemes. One is to render photo-level pictures of all possible collocation cases in advance offline, for display to users on the front end. This scheme has high rendering quality (offline rendering is not limited by time length and computing power) and almost no performance problems (only pictures are actually displayed to users on the front end, without complex processes such as real-time rendering of 3D models), but at least has two problems. First, as the number of replaceable items in a scene increases, the rendering cost increases exponentially. For example, assuming that there are 5 replaceable positions in a 3D space scene model, and each position has 10 replaceable items, 10^5, that is, 10,000 pictures need to be rendered. The extremely high rendering cost makes it almost impossible to use this scheme to do a large number of free collocations. Second, only pure text information is actually displayed on the front end. This kind of information has no interactivity. Although a user can perform a replacement operation on an item at a certain position, the entire picture is actually updated, and interactive operations such as dragging, moving, and changing the viewing angle cannot be supported. According to data verification, the browsing-purchasing conversion rate of this text display is lower than that of the "3D showroom" form of display which has more interactivity.

[0005] Another existing implementation scheme is to directly perform real-time rendering of 3D models on the terminal side. This way can realize interactivity, and is more suitable for scenarios in which users interact with a scene (games, graphics editors, etc.). However, because various interactions need to be performed on the terminal side, it is often required to render more than 30 frames per second. In actual applications, due to the limitations of computing power and memory on the terminal side, it is difficult to provide too high rendering quality in a very short time. For example, the relationship between a 3D model and light and shadow cannot be completely correctly calculated, so that the rendering effect looks very "fake". In addition, the performance of terminal-side rendering of 3D models has high requirements for computing power and memory, and can cause the problem of long scene loading time. SUMMARY

[0006] The present application provides a commodity information display method and an electronic device, which can improve rendering quality, shorten loading time, and provide interactive experience for users.

[0007] The present application provides the following solutions:

[0008] A commodity information display method comprises the following steps:

[0009] determining a 3D space model and 3D commodity models of a plurality of commodities, the 3D space model being pre-provided with a plurality of target positions, the target positions being associated with category information of commodities that can be placed;

[0010] offline rendering a panoramic picture of the 3D space model based on ray tracing to obtain a background panoramic picture layer;

[0011] The foreground panorama layers corresponding to the plurality of 3D commodity models are obtained by placing the single 3D commodity model into the target position of the corresponding category in the 3D space model respectively, setting the material parameters of the 3D space model as transparent and retaining the light and shadow information, and performing offline rendering of the panorama based on ray tracing, and the light and shadow information generated under the action of light after the 3D commodity model is placed into the 3D space model is reflected in the foreground panorama layer.

[0012] The superposition order between the layers corresponding to the plurality of target positions is determined.

[0013] After receiving the browsing request of the user, the target commodity combination to be displayed is determined, the background panorama layer and the foreground panorama layers corresponding to the plurality of commodities in the target commodity combination are superimposed in the superposition order, and a panorama stereogram is generated for displaying the commodity information.

[0014] Further comprising:

[0015] The background panorama layer is saved as picture data containing only three primary color channels by deleting the data on the transparent channel in the background panorama layer.

[0016] Further comprising:

[0017] The image data of the shadow part with a transparency higher than a threshold value in the foreground panorama layer is deleted.

[0018] The foreground panorama layer includes 2D pictures corresponding to the planes in the plurality of directions of the panorama stereogram.

[0019] The method further comprises:

[0020] The circumscribed rectangle of the valid image in the 2D picture is determined as a local clipping area, the blank pixels outside the local clipping area are deleted, and the position information of the local clipping area in the 2D picture is recorded, so that the generation and superposition of the plane picture in the corresponding direction are completed according to the position information when the layer superposition is performed.

[0021] The foreground panorama layer includes 2D pictures corresponding to the planes in the plurality of directions of the panorama stereogram.

[0022] The method further comprises:

[0023] If there is no valid information in the plane in one or part of the directions in the same foreground panorama layer, the image data of the 2D picture corresponding to the plane is deleted in its entirety, and the direction information corresponding to the plane is recorded, so that the layer superposition operation in the corresponding direction is skipped when the layer superposition is performed.

[0024] Further comprising:

[0025] The information of the transparent channel in the foreground panorama layer is compressed.

[0026] In the obtaining of the background panorama layer and the foreground panorama layer, 2D pictures corresponding to planes in multiple directions of the panorama stereogram are obtained respectively;

[0027] In the generating of the panorama stereogram, the 2D pictures corresponding to the background panorama layer and the foreground panorama layer are sequentially superimposed in the same direction according to the superimposition order, and the superimposition results in multiple directions are surrounded in the form of a stereogram to generate the panorama stereogram.

[0028] The foreground panorama layer includes 2D pictures corresponding to planes in multiple directions of the panorama stereogram respectively;

[0029] The method further includes:

[0030] In the generating of the foreground panorama layer, the circumscribed rectangle of the effective image in the 2D picture is determined as a local cropping region, the blank pixels outside the local cropping region are deleted, and sub-regions are divided within the local cropping region;

[0031] The generating of the panorama stereogram includes:

[0032] At the initial moment of rendering the panorama stereogram, each layer is replaced by a placeholder picture;

[0033] The pictures of the background panorama layer and the foreground panorama layers corresponding to multiple commodities are loaded in the process of displaying by the placeholder picture, wherein in the loading process of the pictures, only the image data in the sub-regions within the current field of view range of the virtual camera in the pictures is loaded, and the inside and outside of the field of view range is judged in units of the divided sub-regions in the process of moving the camera view angle.

[0034] The sub-region division within the local cropping region includes:

[0035] A canvas is created according to the size of the 2D picture before cropping, and the canvas is uniformly meshed;

[0036] According to the position and size of the local cropping region in the canvas, it is determined whether each mesh and the local cropping region have an overlapping part, and if there is, the mesh is reduced to the size of the overlapping part, so as to determine the reduced mesh as the sub-region divided within the local cropping region.

[0037] If the grid and the local clipping region have no overlapping part, the grid is reduced to zero width and height, so that the grid division result of the canvas can be reused when sub-regions are divided for different local clipping regions of different commodities.

[0038] The generated background panorama layer and each foreground panorama layer respectively include a high-resolution version and a low-resolution version.

[0039] In the process of rendering the panorama stereogram, the low-resolution version is rendered first, and then the high-resolution version is rendered; and in the process of rendering the low-resolution version, the background part is rendered first, and then the foreground part is rendered from far to near, and in the process of rendering the high-resolution version, the foreground part is rendered from near to far, and then the background part is rendered.

[0040] The method further comprises:

[0041] After the panorama stereogram is generated, a virtual camera is placed at the central position of the panorama stereogram, so as to simulate an interactive response process in a 3D scene through the panorama stereogram.

[0042] The interactive response process comprises:

[0043] An operation option for switching and displaying a plurality of commodities corresponding to the same target position is provided.

[0044] After receiving a request for switching to a target commodity for display through the operation option, a layer corresponding to the target position is replaced by a foreground panorama layer corresponding to the target commodity for display.

[0045] The interactive response process comprises:

[0046] An interactive response process of changing the visual angle of the virtual camera by sliding the screen to view from multiple angles is provided.

[0047] A computer readable storage medium having a computer program stored thereon, the program being executed by a processor to implement the steps of the method of any of the preceding embodiments.

[0048] An electronic device comprising:

[0049] One or more processors; and

[0050] A memory associated with the one or more processors, the memory being configured to store program instructions, the program instructions being configured to be executed by the one or more processors to perform the steps of the method of any of the preceding embodiments.

[0051] A computer program product comprising computer program / computer executable instructions to implement the steps of any of the preceding methods when executed by a processor in an electronic device.

[0052] According to the specific embodiments provided in the present application, the present application discloses the following technical effects:

[0053] According to the embodiments of the present application, a layered panoramic map mode can be provided to realize the display of home furnishing, home furnishing and other category commodities. In this scheme, since the rendering of the 3D model is completed offline in the preprocessing stage, the rendering process of the 3D model is not limited by the time length, computing power and the like, and the panoramic map rendering based on ray tracing can be performed to obtain a photo-level rendering result, and images in multiple directions can be obtained, not limited to the camera main viewing angle direction, thereby providing rich 3D space information. In addition, the rendering of the foreground map can be performed by placing a single 3D commodity model into a 3D space model for rendering, and the 3D space model can be set to be transparent, and then the panoramic map offline rendering based on ray tracing is performed, so that the light and shadow information of the 3D commodity model after being placed in the 3D space model under the action of light can be reflected in the foreground panoramic layer, so that the effect and quality of the rendering are guaranteed. In the real-time rendering stage, the client loads the 2D picture corresponding to the panoramic layer from the server, and the client can superimpose the 2D picture according to the layer order and enclose the panoramic stereogram, and then the multi-view browsing, commodity replacement and other interactive effects in the 3D scene can be simulated. Therefore, the client does not involve loading and rendering of the 3D model, so that the response speed is guaranteed, and through the panoramic stereogram, the interactive effects in the 3D scene can be simulated.

[0054] In addition, a series of optimization processes in the preprocessing stage and the real-time rendering stage can further improve the rendering quality, performance and the like. For example, in the preprocessing stage, the data on the transparent channel in the background panoramic layer can be deleted, the shadow part image data with a transparency higher than a threshold in the foreground panoramic layer can be deleted, the bounding rectangle of the effective image in the foreground panoramic layer can be taken as a local clipping area, and the faces without effective images can be removed, and the like; in the real-time rendering stage, heuristic and progressive rendering can be performed, which can improve the first screen loading speed and user experience.

[0055] Of course, implementing any product of the present application does not necessarily need to achieve all the advantages described above. BRIEF DESCRIPTION OF DRAWINGS

[0056] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the accompanying drawings needed in the embodiments will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the present application, and both persons of ordinary skill in the art can obtain other drawings according to these drawings without any creative effort.

[0057] Figure 1 is a schematic diagram of a system architecture provided by an embodiment of the present application;

[0058] Figure 2 is a flowchart of a method provided by an embodiment of the present application;

[0059] Figure 3 is a schematic diagram of a background layer provided by an embodiment of the present application;

[0060] Figure 4 is a schematic diagram of a foreground layer provided by an embodiment of the present application;

[0061] Figure 5 is a schematic diagram related to shadow weakening provided by an embodiment of the present application;

[0062] Figure 6 is another schematic diagram related to shadow weakening provided by an embodiment of the present application;

[0063] Figure 7 is a schematic diagram related to local clipping provided by an embodiment of the present application;

[0064] Figure 8 is a schematic diagram related to layer superposition and panoramic stereogram generation provided by an embodiment of the present application;

[0065] Figure 9 is a schematic diagram related to shadow weakening provided by an embodiment of the present application;

[0066] Figure 10 is a schematic diagram related to shadow weakening provided by an embodiment of the present application;

[0067] Figure 11 is a schematic diagram related to shadow weakening provided by an embodiment of the present application;

[0068] Figure 12 is a schematic diagram related to shadow weakening provided by an embodiment of the present application. DETAILED DESCRIPTION

[0069] With reference to the drawings and the embodiments of the present application, the technical solutions in the embodiments of the present application will be described clearly and completely. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art belong to the scope of protection of the present application.

[0070] In the embodiments of the present application, a "layered panoramic picture" is adopted to realize the display of home furnishing furniture commodities. In the preferred mode, a series of rendering quality optimization and performance optimization can be performed.

[0071] In the "layered panoramic picture", the "layering" refers to that the picture can be divided into a background layer and a plurality of foreground layers. The background layer can correspond to a 3D space scene model, and the foreground layer can correspond to each specific commodity. That is, assuming that there are 5 pits in a certain 3D space scene model, and each pit has 10 replaceable commodities, then 5x10=50 foreground layers need to be generated in the embodiments of the present application. When different combinations of different pits are used to display the collocation effect between different commodities, the foreground layers can be replaced to achieve the display. For example, assuming that a commodity combination is (A1, B1, C1, D1, E1), at this time, when the front end is displayed, the background layer and the foreground layers corresponding to the five commodities A1, B1, C1, D1, and E1 can be superimposed. If commodity A1 in the above combination needs to be replaced by A2, that is, the collocation effect of (A2, B1, C1, D1, E1) in the current 3D space model needs to be displayed, then the foreground layer corresponding to A1 can be replaced by the foreground layer corresponding to A2.

[0072] In the "layered panoramic picture", the "panoramic" refers to that the background layer and the foreground layer generated in the embodiments of the present application are all panoramic layers, that is, the front, back, left, right, up, and down directions of the rendering camera are included, rather than only the main viewing angle direction of the camera.

[0073] The background panorama layer and the foreground panorama layer can be generated offline, so that the rendering process of the 3D model is not limited by time length, computing power, and the like, and the generation quality of the layer is ensured. After obtaining the background panorama layer and the foreground panorama layer corresponding to each commodity respectively, online real-time rendering can be performed. At this time, the specific background panorama layer and the foreground panorama layer corresponding to the commodities in the combination to be displayed can be loaded, and the multiple layers can be superimposed and displayed. Each panorama layer can correspond to 2D images corresponding to multiple directions of a plane in a panorama solid figure, for example, 2D images on six planes of an upper plane, a lower plane, a left plane, a right plane, a front plane, and a back plane in a panorama hexahedron, and the like. During online real-time rendering, the planes in each direction can be enclosed to form a panorama solid figure, and a virtual camera can be placed at a central position of the solid figure, so as to simulate a view rotation and other interactive effects in a 3D exhibition hall scene. During specific implementation, multiple optimizations can be performed during offline preprocessing and online real-time loading, so as to further improve picture quality and / or performance.

[0074] From the perspective of system architecture, referring to Figure 1 The embodiment of the present application can provide a layered panorama rendering scheme of photo-level indoor scene real-time rendering capability and furniture matching effect real-time preview capability in a commodity information service system. Specifically, a server and a client can be provided. The server is mainly used to complete offline panorama layer generation and storage. The client can be a client for consumer users. An access portal of a related function can be provided in a related page of the client. For example, the access portal can be provided in a store page of a merchant, or the access portal can be provided in a channel page of a home furnishing channel of the system, and the like. The store page or the channel page can be a web page, that is, a 2D web page. After a user initiates an access request through the access portal, a corresponding background layer and a foreground layer can be loaded from the server to assemble a panorama solid figure, so as to simulate display and interactive effects in a 3D scene.

[0075] The specific implementation scheme provided by the embodiment of the present application is described in detail below.

[0076] First, the embodiment of the present application provides an information display method, referring to Figure 2 The method can include the following steps.

[0077] S201: Determine a 3D space model and a plurality of 3D commodity models of commodities. A plurality of target positions are preset in the 3D space model, and the target positions are associated with category information of commodities that can be placed.

[0078] In a specific implementation, first, a 3D space model and a plurality of 3D commodity models can be determined. The 3D space model can be a pre-defined "template room" model, or can correspond to some actual house type, or can be a 3D space model generated according to a house type uploaded by a consumer user, etc. In the generation of the 3D space model, a plurality of "pit positions" can be pre-set, i.e., positions for placing specific commodities. Each pit position can specify specific commodity category information, for example, a pit position is used to place a sofa type commodity, another pit position is used to place a tea table type commodity, etc. Regarding the plurality of 3D commodity models, i.e., the 3D models corresponding to the plurality of commodities that can be placed in the above 3D space model, the plurality of commodities can have multiple selection methods. For example, assuming that a merchant needs to provide a related function module to users in his own store page, the merchant can select specific commodities, which are usually commodities in the same store; or if the platform side needs to provide a related function module in a home decoration and furniture channel page, the operation staff of the platform can complete the selection operation, at which time, cross-store commodity collocation can be performed.

[0079] S202: Perform offline rendering of a panoramic view of the 3D space model based on ray tracing to obtain a background panoramic view layer.

[0080] After the 3D space model and the plurality of 3D commodity models are determined, the offline layer generation process can be first completed, i.e., in the present application, the specific "layered panoramic view" can be generated offline, and when the user is specifically displayed, online superposition display between a plurality of different layers is performed. Since the layers are generated offline, they are not limited by time and computing power, and better layer generation effects can be obtained. In an online state, only layer superposition and other processing need to be performed, so the response speed can be ensured and the loading time can be shortened while ensuring good picture effects. In addition, since the generated layers are panoramic view layers, the 3D effect in the "3D showroom" situation can be simulated in the form of a panoramic view, and commodity replacement, perspective rotation and other interactions can be supported.

[0081] In particular, when generating the background panorama layer offline, first, the background panorama layer can be generated. Specifically, the 3D space scene can be rendered. In the rendering process, the 3D space scene can be in an "empty" state, or some 3D commodity models can be placed in the 3D space model, but these 3D commodity models will not cause light blocking in the 3D space model (for example, some cabinets placed close to the wall). In the above state, the panorama picture can be rendered offline based on ray tracing. If the 3D space model is in an empty state, only the 3D space model can be rendered. If some 3D commodity models that do not cause light blocking are placed in the 3D space model, the 3D space model and these 3D commodity models can be rendered together based on ray tracing.

[0082] Ray tracing is a specific rendering technique that can accurately simulate light transmission during 3D model rendering, track the trajectory of light to simulate realistic lighting and shadows, and generate or enhance effects such as highly realistic reflection, refraction, and shadows. In the scene of the embodiments of the present application, since the effects of the collocation of multiple different home furnishing and home furnishing products in space need to be displayed, the simulation of light and shadow is very important, which can enable users to observe whether a piece of furniture will cause light blocking in the room, etc. Therefore, in the embodiments of the present application, a rendering method based on ray tracing can be used to render the 3D model, so that the effects such as reflection, refraction, and shadow of light can be simulated in the rendering result.

[0083] When rendering the 3D space model using the ray tracing-based technology, the panorama picture can be rendered. In the 3D rendering engine, there is a concept of virtual camera. In the general rendering process, only the image in the forward view range of the camera is usually rendered, but in the embodiments of the present application, the front, back, left, right, up, and down directions of the camera are rendered respectively to obtain the background panorama layer. It should be noted that the background panorama picture obtained in the initial state can be a whole picture, and then the views on the planes in the six directions of front, back, left, right, up, and down can be cut out. For example, in one example, the pictures on the six planes corresponding to the background panorama layer can be as shown in FIG. 8. Figure 3

[0084] ​It should be noted that each pixel of the picture is usually composed of RGBA (red, green, blue, and transparency) four channels. However, since the background layer does not need to consider the shadow transparency, the transparency channel does not need to be considered when saving the data of the background layer, that is, in the optional manner, the background panorama layer can be converted into picture data containing only RGB three primary color channels by deleting the data on the transparency channel of the background panorama layer. For example, the specific picture can be in the format of JPG (Joint Photographic Experts Group, an image format), and by deleting the data on the transparency channel, 25% of the storage space can be saved, effectively improving the scene loading speed on the terminal side.

[0085] S203: After placing the single 3D commodity model into the target position of the corresponding category in the 3D space model respectively and setting the material parameters of the 3D space model to be transparent and retaining the light and shadow information, performing offline rendering of the panorama based on ray tracing, obtaining the foreground panorama layers corresponding to the plurality of 3D commodity models respectively, and making the light and shadow information generated by the 3D commodity model under the action of light after being placed into the 3D space model reflected in the foreground panorama layers.

[0086] After the generation of the background panorama layer is completed, the generation of the foreground panorama layer can be performed. In the embodiments of the present application, a foreground panorama layer corresponding to each commodity to be placed into the 3D space model can be generated respectively, that is, the panorama layer of each commodity in the 3D space model is obtained. Specifically, the 3D commodity model can be placed into the empty 3D space model one by one (that is, only one 3D commodity model is placed into the 3D space scene each time, and the specific placement position can be determined according to the commodity category information corresponding to the pit position set in the 3D space scene, for example, the commodity of the sofa category is placed into the pit position of the sofa category, etc.), and the material parameters of the empty 3D space model are set to be transparent and retain the light and shadow information, and then the panorama rendering based on ray tracing is performed. In this way, the background image is not displayed in the image of the rendering result, but the reflection, refraction, shadow, and other light and shadow information generated by the specific 3D commodity model after being placed into the 3D space model under the action of light can still be reflected. Further, the foreground panorama layer corresponding to each commodity rendered has not only the photo-level texture characteristics, but also can contain the light and shadow information of the commodity in the "room", which can more correctly reflect the light action between the commodity and the room. Moreover, since the background part has been transparently processed, each foreground panorama only contains the commodity and its shadow, and other areas are transparent.

[0087] It should be noted that in the 3D renderer, the specific 3D model has material parameters, and in the specific implementation, the material type of the 3D space model can be set to a material such as Vray with shadow catcher capability, and the "transparent and retain shadow" parameter of the material is turned on. Among them, the "material" of the 3D space model is also briefly introduced as follows: In the embodiment of the present application, the process of rendering the 3D model offline is essentially a physical simulation, simulating light tracing, that is, the process of light reflection, refraction, etc. on different object surfaces. The light starts from the light source, passes through many object surfaces, enters the human eye, and the human being sees the color; if the light is blocked during propagation, the light reaching the human eye will be reduced, resulting in a shadow effect. Therefore, in the process of rendering the 3D model, a calculation is involved: for a point on the surface of an object, the incident light around it is integrated, and then reflected to the out-set direction. This calculation process is also called the "material" of the 3D model. Different materials will have different calculation parameters, and by setting these parameters, the "transparent" effect of the final rendering result in the visual effect will be achieved. However, since the light and shadow information is retained, the light and shadow effect of the 3D commodity model in the space station is retained, that is, after rendering, although the background is transparent, the 3D commodity model has shadows, and the direction, size, shape, etc. of the shadow are related to the shape of the 3D commodity model itself and the position in the 3D space model.

[0088] Each foreground panoramic layer corresponding to each commodity can also be divided into 2D images on multiple directional planes, for example, images in six directions of front, back, left, right, up and down, etc.

[0089] Since the light and shadow information is retained in the process of generating the foreground panoramic layer, there may be shadows in the foreground image, for example, the shadow-containing foreground layer can be as shown in Figure 4 Figure 4 ​As can be seen, since the 3D space model is transparently processed before rendering, there is no complex background in the foreground layer, and no matting or other processing is needed. Although such light and shadow information can improve the realism of the rendering, the presence of shadows will inevitably increase the data volume, and in general, too many shadows may not be needed to be preserved. Therefore, in an optional implementation, the image data of the shadow part in the foreground panorama layer with an opacity lower than a threshold value can also be deleted to preserve the obvious shadows as much as possible and weaken the relatively light shadows, thereby reducing the range of object shadows in the picture. In specific implementation, a non-linear light and shadow evaluator can be introduced to weaken the relatively light shadows by recalculating the opacity (for example, square attenuation, etc.), which can be processed by formula (1); then, a threshold denoising image operation can be performed to directly set the pixels with an opacity less than a specified threshold value to be transparent, which can be processed by formula (2).

[0090] α′=α F ,α∈[0,1],F∈(0+∞) (1)

[0091] α″=α′ifα′>t else 0,t∈[0,1] (2)

[0092] In the above two formulas, alpha represents the opacity (i.e., the alpha channel), and the value range is [0, 1], in which 0 represents complete transparency and 1 represents complete opacity. After alpha is processed by formula (1), alpha' is obtained, and then alpha" is obtained after formula (2) is processed.

[0093] Formula (1) is the formula of the light and shadow evaluator, which is used for recalculating the opacity, and the purpose is to make the color deep shadow darker and the light shadow lighter. F is a parameter for controlling the attenuation curve, and the value range is (0, +∞). When alpha and t are constant, the greater F is, the more pixels with the final opacity tending to 0, and the smaller the final shadow range is.

[0094] Formula (2) is used to set the opacity of the pixel with too low opacity to 0, in which t is the opacity threshold value, and the value range is [0, 1]. When the opacity of a pixel is less than t, the transparency of the pixel is set to 0.

[0095] In which, the different values of F and t will affect the final processing result, for example, Figure 5 (A) shows the function change curve when F is different, Figure 5 (B) shows the rendering effect diagram when F = 1, Figure 5(C) shows the rendering effect diagram when F=2. In actual application, F takes 2, t takes 10 / 255, and a relatively ideal processing result can be obtained. Of course, the values of the above parameters can also be adjusted according to different actual needs.

[0096] In order to more clearly show the influence of t on the weakening of the shadow, the image is binarized: if a pixel is completely transparent, it is set to black, otherwise it is set to white. For example, for the original image shown in (A), when t takes values of 0, 5 / 255 and 10 / 255, the pictures obtained after binarization processing respectively can be shown in (B), (C) and (D). Figure 6 Figure 6 (B), (C), (D).

[0097] The essence of the shadow weakening step is to expect to loss-compress information under the premise of ensuring visual effects, and this step will produce many unnecessary blank pixels. Therefore, in the preferred mode, further cropping or rejection operations can also be used to truly delete these invalid information from the image. For example, assuming that the specific foreground panoramic layer includes 6 faces of the panoramic graph, two types of cropping rejection can be involved here: if a face is completely blank, that is, it does not include any valid information, then this face can be directly rejected; for the remaining faces, a minimum rectangle (which can be called an enclosing rectangle) containing all valid information can be used to crop the image. For example, assuming that the original image on a certain face is shown in (A), after cropping, it can be shown in (B). Figure 7 Figure 7 (B). In this way, the size of the picture can be further reduced, saving storage space. Of course, in specific implementation, for the case of cropping, the position of the above-mentioned enclosing rectangle in the picture can be recorded (which can be recorded according to the coordinates of the upper left corner of the rectangle and the width and height of the rectangle) so that the placement position of the cropped picture can be determined according to the position information in subsequent online real-time rendering. For the case of rejecting the entire face, information such as the direction of the rejected face can be recorded so that the correct superposition between layers can be performed in subsequent online real-time rendering.

[0098] ​​In addition to performing shadow weakening, cropping and the like, the foreground panoramic picture can be compressed by a related image compression algorithm. Since the foreground layer includes data on the transparency channel, the WebP (a picture file format that provides both lossy and lossless (reversible) compression) format or the KTX2 (a texture compression algorithm mainly used to reduce the storage space occupied by texture images in computer graphics processing while maintaining or approaching the quality of the original image) algorithm more suitable for GPU (Graphics Processing Unit) rendering can be used for compression to improve loading speed, reduce memory usage and reduce resource pre-push size.

[0099] S204: Determine the superimposition order between the layers corresponding to the plurality of target positions.

[0100] In addition to obtaining the specific picture data of the background panoramic layer and the plurality of foreground panoramic layers, the superimposition order between the plurality of different layers can also be determined. The background layer needs to be placed at the bottom layer, but the relative order of the foreground layers needs to be explicitly specified. The order of the foreground layers described herein is not related to specific items, but can be determined by the angle of the target position (i.e., "pit position") set in the 3D space model. For a simple scene, the distance of the pit position from the camera in the 3D space model can be directly used for calculation, for example, assuming that there are four pit positions A, B, C and D, where the A pit position is closest to the camera, followed by C, then D and B, and the order of these pit positions from top to bottom can be A, C, D and B. For a complex scene (the pit position is a point, and the model is a body, and sometimes the relative position of the point cannot represent the relative position of the body, at which time the layer sorting problem becomes complex), a more complex Mask (mask or mask) based method can be used to calculate the order between the layers. The specific Mask method is not the focus of the present application, and will not be described in detail here.

[0101] S205: After receiving the user's browsing request, determine the target product combination to be displayed, superimpose the background panoramic layer and the foreground panoramic layers corresponding to the plurality of products in the target product combination according to the superimposition order, and generate a panoramic stereogram for displaying product information.

[0102] The foregoing S201 to S204 all belong to offline executed preprocessing steps, after the foregoing preprocessing is completed, a front-end access portal can be provided for a user, so that the user can initiate access. In the embodiments of the present application, the user can initiate a specific access request on the Web side, and the server side can return a plurality of 2D pictures corresponding to a plurality of layers and the ordering information between the layers to the client side, and the client side can superimpose the plurality of layers in sequence and render a panoramic stereogram. The panoramic stereogram can be a panoramic polyhedron, for example, a panoramic hexahedron, etc. In addition, a virtual camera can be placed at a position such as the center of the panoramic stereogram, thereby simulating the interactive effect of the 3D scene. For example, the user can change the camera angle by sliding the screen, etc., to view the specific matching effect from other angles, or can select to replace other goods at a certain position for display, etc.

[0103] Among them, since there can be multiple replaceable goods at each pit of the same 3D space model, but only one good is usually displayed at the same pit at the same time, therefore, in specific implementation, a default good combination can be provided, which includes a plurality of goods corresponding to a plurality of pits, and each pit can correspond to only one good. In this way, after the user initiates access, the foreground panoramic layer of which good needs to be displayed for each layer can be determined according to the default good combination. Of course, after displaying this default good combination, an operation option for replacing the goods in the specific pit can be provided in the interface, and the user can replace the goods on the specific pit to view the corresponding matching effect.

[0104] As described above, when the background panoramic layer and the foreground panoramic layer are obtained, 2D pictures corresponding to the planes in multiple directions of the panoramic stereogram can be obtained respectively, so that when the panoramic stereogram is generated, the 2D pictures corresponding to the background panoramic layer and the foreground panoramic layer can be superimposed in sequence in the same direction according to the superimposition order, and the superimposition results in multiple directions are surrounded in the form of a stereogram to generate the panoramic stereogram. That is, only one face of the panoramic graph is viewed first, and this step superimposes a background layer and a plurality of foreground layers corresponding to goods in the order determined in advance to form the superimposition effect of the traditional 2D sub-layer rendering scheme. When the layers of multiple faces are all superimposed, the multiple faces are surrounded in the form of a polyhedral box, and then the camera can be placed at a position such as the center of the box, thereby realizing the superposition of the panoramic graph. For example, the specific superposition and the process of surrounding the hexahedral box can be as shown in Figure 8 Each face can be composed of a background picture and a plurality of foreground pictures, and then the six faces form a panoramic hexahedral box.

[0105] It should be noted that, for the foreground layer which has been cropped, if the picture on a certain face is cropped in the minimum rectangular range containing valid information, then during the superimposition, the specific superimposition processing can be completed according to the position information of the rectangular range recorded during the cropping. For example, during the process of superimposing multiple layers on a certain face, the background layer of the face is located at the bottom layer, and the size of the background picture is also the size of the face. Before cropping, the size of each foreground layer on the face is also the same as the size of the background picture. Therefore, after cropping a certain rectangular range from the foreground layer on the face, assuming that the certain rectangular range is located at (x, y) of the picture, then during the superimposition, the rectangular range can be superimposed at (x, y) relative to the background layer. In addition, if a certain face of a certain foreground layer is entirely removed, then during the superimposition, the foreground layer can skip the superimposition operation on the face, and only the superimposition operation on other foreground layers can be performed.

[0106] During the implementation, since each layer corresponds to a plurality of 2D pictures of planes in multiple directions, if the plurality of 2D pictures corresponding to each layer are directly loaded, a relatively large amount of resources and a relatively long time can be required. Considering that usually only the image within the current field of view of the camera can be displayed at the same time, and the image within the field of view of another view angle can be displayed only after the user performs an operation of changing the view angle, in the preferred implementation, the panoramic stereogram can be generated by using the placeholder first, that is, the pictures are not actually loaded in the initial stage, and the actual loading logic of the pictures is gradually performed after the panoramic stereogram is constructed.

[0107] During the loading of the pictures, the tile segmentation logic can be used to divide a picture into a plurality of sub-regions, and the sub-regions are loaded as a unit. For example, if some sub-regions are located within the field of view, only the sub-regions within the field of view can be loaded, and the other sub-regions do not need to be loaded. In the traditional way, a complete picture is directly divided into tiles, but in the embodiment of the present application, since some foreground layers are cropped and only the image within the circumscribed rectangular range of the valid information is retained, the sub-regions can be divided within the circumscribed rectangular range, that is, the regional tile segmentation can be implemented. In the process of actually rendering, at the initial time of rendering the panoramic stereogram, the layers can first be replaced by the placeholder, and then the pictures of the background panoramic layer and the foreground panoramic layer corresponding to each commodity can be loaded during the display by using the placeholder. During the loading of the pictures, only the image data within the sub-regions located within the current field of view of the virtual camera can be loaded, and the sub-regions are updated as a unit during the movement of the camera view angle.

[0108] That is, unlike the tile segmentation logic of a general panoramic picture, the embodiment of the present application can also consider the local clipping problem while segmenting the tiles. In the embodiment of the present application, n*n tiles can be created by uniform grid division, and then each tile can be reduced according to the local clipping region, that is, the size of the tile in the local clipping region can be determined according to the overlapping part between the tile divided by the uniform grid and the local clipping region; if a tile has no overlapping part with the local clipping region, it will be reduced to a tile with a width and height of 0. The reason why the tile with a width and height of 0 is still retained is that the position and size of the local clipping region corresponding to different objects may change, and in the case of retaining the above-mentioned tile, the tile entity / texture does not need to be re-created when the local clipping region changes, which can bring performance improvement.

[0109] For example, as shown in Figure 9 , it is assumed that the relationship between the initial canvas and the local clipping region is as shown in Figure 9 (A), where 91 represents the local clipping region. The result obtained after 3*3 uniform tile division of the canvas is as shown in Figure 9 (B); after reducing the tiles, the result obtained can be as shown in Figure 9 (C). That is, only the four tiles in the upper left corner have overlapping parts with the local clipping region, so these four tiles are reduced to the size of the overlapping part, and the other five tiles are directly reduced to tiles with a width and height of 0 because they have no overlapping with the local clipping region.

[0110] It should be noted that first, since the grid division method of the canvas can be fixed, and the size and position of the local clipping region corresponding to different objects may be different, the tiles in the local clipping region may be unevenly divided. For example, as shown in Figure 9 (D), it is assumed that the local clipping region of an object is at the position shown by 92, so the tiles divided by the local clipping region are uneven, but this does not affect the subsequent "visibility culling" processing. Second, the tile division in the end-side rendering can be considered in the data preprocessing stage of each layer, and the tile-level data can be prepared in advance. Third, the granularity of tile division can not be too fine, otherwise it may put pressure on GPU resources and the speed of browser concurrent resource pulling.

[0111] In the case of local tile segmentation, during online real-time rendering, a visibility culling process can be performed. Visibility culling is a common optimization method in game engines, and its core idea is to "load only the resources that can be seen in the camera view range". In combination with the tile segmentation in the previous step, this step can accelerate the first screen rendering speed. Specifically, initially, the algorithm will only load the faces within the camera range; when the camera moves, it will load the faces that newly appear in the field of view; when the replacement operation is performed, the tiles within the field of view will be immediately updated, and the tiles outside the field of view will be delayed until the camera moves to that position. For example, as shown in FIG. 8, the red object outside the view frustum can be culled, which can improve the layer loading speed. Figure 10

[0112] In addition, considering the large number of layers, in the preferred implementation, the loading of layer data can also be gradually improved in resolution. Specifically, for each layer, two sets of high-resolution and low-resolution data can be prepared during the preprocessing phase. Specifically, during online real-time rendering, low-resolution images can be loaded first to give users a general idea of the appearance of the object, and then high-resolution images can be loaded. Second, for multiple layers of the same face, heuristic experience rules can be set between the loading order of the layers. Specifically, when loading low-resolution layers, the background can be loaded first to fill the canvas and give users the feeling that the scene has been loaded, and then the foreground objects can be loaded from near to far; when loading high-resolution layers, based on the non-transparent object rendering logic, the foreground objects can be loaded from near to far, and then the background can be updated. This heuristic and gradual loading can provide users with faster first screen loading speed and better first screen loading experience.

[0113] After online real-time rendering, rich interactive capabilities are also supported. The two most basic capabilities are replacement and view rotation. Users can freely view specified positions in the room and replace them by clicking the goods in the switching panel. In addition, the scheme also supports additional interactive capabilities such as undo and redo, and display of model bounding box range. For replacement, specifically, multiple goods corresponding to the same target position can be provided for switching and displaying options. After receiving a request to switch to a target good for display, the layer corresponding to the target position can be replaced with the foreground panoramic layer corresponding to the target good for display. That is, only the layer corresponding to the position needs to be replaced, and other layers can remain unchanged.

[0114] ​It should be noted that, regarding the rotation of the perspective, the user can specifically operate by sliding the screen. In the embodiments of the present application, the camera position can be placed at the center of the cube box or the like, and during the rotation of the perspective, the camera position remains unchanged, only the perspective changes, that is, during the rotation of the perspective, the items in the space do not rotate. In addition, in actual application, the user can also be provided with a function of 360-degree rotation to view the items, at this time, the case of obtaining pictures of the same item at multiple different angles is involved, and in the specific implementation, the pictures of the same item at multiple perspectives can be generated by AI or the like to support the above function.

[0115] The specific implementation schemes provided by the embodiments of the present application are described in detail above, and in general, the embodiments of the present application can be divided into two stages of offline preprocessing and online real-time rendering, and in each stage, in addition to some basic processing, a series of optimization processing can also be performed. In order to better understand the scheme provided by the embodiments of the present application, a preferred scheme is described in detail below in combination with the flowchart provided by the embodiments of the present application. Figure 11

[0116] As shown in Figure 11 In the preprocessing stage, first, 3D scene data can be produced on the production side, including a 3D space scene model and a plurality of 3D commodity models, and then entering the preprocessing stage, in which background panorama layer rendering and a plurality of foreground panorama layer rendering can be performed, and layer sorting can also be performed. For the background panorama layer, data on the transparent channel can be deleted, and 6 optimized background pictures on the faces are output; for the foreground panorama layer, partial shadow weakening, local clipping, face culling, texture compression and the like can be performed, and n-n*6 optimized foreground pictures are output, wherein n is the number of commodities. In the real-time rendering stage, the client can obtain 6 background panorama pictures, n-n*6 optimized foreground pictures and layer sorting information, and then perform panorama layering and superposition, and in the superposition process, local tile division, visibility culling and heuristic progressive loading and the like can also be performed. In the display process, interactive operations can also be supported, including moving the camera perspective of the user or replacing the commodity at a certain position, and the like.

[0117] ​In summary, by the embodiments of the present application, a layered panoramic map manner can be provided to realize the display of home furnishing furniture and the like category commodities. In the scheme, since the rendering of the 3D model is completed offline in the preprocessing stage, the rendering process of the 3D model is not limited by the time length, computing power and the like, and the panoramic map rendering based on ray tracing can be performed to obtain a photo-level rendering result, and images in multiple directions can be obtained instead of being limited to the camera main viewing angle direction. In addition, the rendering of the foreground map can be performed by placing a single 3D commodity model into a 3D space model respectively and rendering, and the material parameters of the 3D space model can be set as transparent and retaining light and shadow information, and then the panoramic map offline rendering based on ray tracing is performed, so that the light and shadow information generated by the 3D commodity model under the action of light after being placed into the 3D space model can be reflected in the foreground panoramic layer, and the effect and quality of the rendering are guaranteed. In the real-time rendering stage, the client loads the 2D picture corresponding to the panoramic layer from the server, the client can superimpose the 2D pictures according to the layer order, and enclose the panoramic solid figure, and then the multi-view browsing, commodity replacement and the like interactive effects in the 3D scene can be simulated. Therefore, the client does not involve loading and rendering of the 3D model, the response speed is guaranteed, and through the panoramic solid figure, the interactive effects in the 3D scene can be simulated.

[0118] In addition, a series of optimization processes in the preprocessing stage and the real-time rendering stage can further improve the rendering quality, performance and the like. For example, in the preprocessing stage, the data on the transparent channel in the background panoramic layer can be deleted, the shadow part image data with a transparency higher than a threshold in the foreground panoramic layer can be deleted, the bounding rectangle of the effective image in the foreground panoramic layer can be taken as a local clipping area, and the faces without effective images can be removed, and the like; in the real-time rendering stage, heuristic and progressive rendering can be performed, and the first screen loading speed and user experience can be improved.

[0119] It should be noted that the embodiments of the present application can involve the use of user data. In actual application, user-specific personal data can be used in the schemes described herein within the scope allowed by applicable laws and regulations, for example, the user explicitly agrees, the user is actually notified, and the like.

[0120] Corresponding to the foregoing method embodiments, the embodiments of the present application also provide a commodity information display device. The device can include:

[0121] A 3D model determination unit is configured to determine a 3D space model and 3D commodity models of a plurality of commodities. The 3D space model has a plurality of target positions pre-set therein, and the target positions are associated with category information of commodities that can be placed.

[0122] a first offline rendering unit configured to perform offline rendering of a panoramic picture based on ray tracing on the 3D space model to obtain a background panoramic picture layer;

[0123] a second offline rendering unit configured to perform offline rendering of a panoramic picture based on ray tracing by respectively placing a single 3D commodity model into a target position of a corresponding category in the 3D space model and setting a material parameter of the 3D space model as transparent and retaining light and shadow information, to obtain a foreground panoramic picture layer corresponding to the plurality of 3D commodity models respectively, and to make the foreground panoramic picture layer reflect light and shadow information generated by the 3D commodity model under the action of light after being placed into the 3D space model;

[0124] a superimposition order determination unit configured to determine a superimposition order between the layers corresponding to the plurality of target positions;

[0125] an online rendering unit configured to determine a target commodity combination to be displayed after receiving a browsing request of a user, superimpose the background panoramic picture layer and the foreground panoramic picture layers corresponding to the plurality of commodities in the target commodity combination according to the superimposition order, and generate a panoramic stereogram for displaying commodity information.

[0126] In a specific implementation, the apparatus can further include:

[0127] a transparent channel data deletion unit configured to save the background panoramic picture layer as picture data containing only three primary color channels by deleting data on the transparent channel in the background panoramic picture layer.

[0128] a shadow weakening unit configured to delete image data of a shadow part in the foreground panoramic picture layer with a transparency higher than a threshold value.

[0129] The foreground panoramic picture layer includes 2D pictures corresponding to planes in a plurality of directions of a panoramic stereogram. The apparatus can further include:

[0130] a local cropping unit configured to determine an enclosing rectangle of a valid image in the 2D picture as a local cropping area, delete blank pixels outside the local cropping area, and record position information of the local cropping area in the 2D picture, so as to generate and superimpose a plane picture in a corresponding direction according to the position information when performing layer superimposition.

[0131] In addition, the apparatus can further include:

[0132] A face removing unit is configured to remove all image data of a 2D picture corresponding to a plane in a certain or partial direction in a same foreground panorama layer if there is no valid information in the plane, and record direction information corresponding to the plane, so as to skip a layer superimposition operation in a corresponding direction when performing layer superimposition.

[0133] A compression unit is configured to perform compression processing on information of a transparent channel in the foreground panorama layer.

[0134] In addition, since the 2D pictures corresponding to the planes in multiple directions of the panorama are obtained respectively when the background panorama layer and the foreground panorama layer are obtained, when the panorama is generated, specifically, the 2D pictures corresponding to the background panorama layer and the foreground panorama layer are sequentially superimposed in the same direction according to the superimposition order, and the superimposition results in multiple directions are enclosed in the form of a panorama to generate the panorama.

[0135] Further, the device further comprises:

[0136] A local tile division unit is configured to, when the foreground panorama layer is generated, determine a circumscribed rectangle of valid image in the 2D picture as a local clipping region, remove blank pixels outside the local clipping region, and divide the local clipping region into sub-regions.

[0137] The online rendering unit can be specifically configured to:

[0138] At an initial moment of rendering the panorama, each layer is replaced by a placeholder picture; the background panorama layer and the pictures of the foreground panorama layers corresponding to multiple commodities are loaded in a process of displaying the placeholder picture, wherein, in the process of loading the pictures, only image data in a partial sub-region of the pictures located in a current field of view of the virtual camera is loaded, and a judgment of inside and outside of the field of view is performed in units of the divided sub-regions in a process of moving the camera view angle.

[0139] Specifically, when the sub-regions are divided in the local clipping region, a canvas can be created according to the size of the 2D picture before clipping, and the canvas is uniformly meshed; then, according to the position and size of the local clipping region in the canvas, it is determined whether each mesh and the local clipping region have an overlapping part, if there is, the mesh is reduced to the size of the overlapping part, so as to determine the reduced mesh as a sub-region divided in the local clipping region.

[0140] If the grid and the local clipping region do not overlap, the grid is reduced to zero width and height, so that the grid division result of the canvas can be reused when the local clipping regions corresponding to different commodities are divided into sub-regions.

[0141] In addition, the generated background panorama layer and each foreground panorama layer respectively include a high-resolution version and a low-resolution version; during rendering of the panorama stereogram, the low-resolution version can be rendered first, and then the high-resolution version; and during rendering of the low-resolution version, the background part is rendered first, and then the foreground part is rendered from far to near, and during rendering of the high-resolution version, the foreground part is rendered from near to far, and then the background part is rendered.

[0142] In addition, the device can further include:

[0143] The interactive response unit is configured to, after the panorama stereogram is generated, place a virtual camera at a central position of the panorama stereogram, so as to simulate an interactive response process in a 3D scene through the panorama stereogram.

[0144] Specifically, the interactive response unit can be configured to:

[0145] An operation option for switching display of a plurality of commodities corresponding to the same target position is provided; after a request for switching to a target commodity for display is received through the operation option, a layer corresponding to the target position is replaced by a foreground panorama layer corresponding to the target commodity for display.

[0146] Alternatively, an interactive response process of changing a virtual camera view angle by sliding a screen to view from multiple angles is provided.

[0147] In addition, the embodiments of the present application further provide a computer readable storage medium, which stores a computer program, and the program is executed by a processor to implement the steps of the method in any one of the preceding method embodiments.

[0148] An electronic device includes:

[0149] One or more processors; and

[0150] A memory associated with the one or more processors, the memory being configured to store program instructions, the program instructions being configured to, when executed by the one or more processors, perform the steps of the method in any one of the preceding method embodiments.

[0151] A computer program product includes computer program / computer executable instructions, the computer program / computer executable instructions being executed by a processor in an electronic device to implement the steps of the method in the preceding method embodiments.

[0152] In the method,Figure 12 An exemplary architecture of the electronic device is shown, which can specifically include a processor 1210, a video display adapter 1211, a disk drive 1212, an input / output interface 1213, a network interface 1214, and a memory 1220. The processor 1210, the video display adapter 1211, the disk drive 1212, the input / output interface 1213, the network interface 1214, and the memory 1220 can be communicatively connected through a communication bus 1230.

[0153] The processor 1210 can be implemented in a general-purpose CPU (Central Processing Unit), a microprocessor, an ASIC (Application Specific Integrated Circuit), or one or more integrated circuits, etc., and is configured to execute related programs to implement the technical solutions provided in the present application.

[0154] The memory 1220 can be implemented in the form of a ROM (Read Only Memory), a RAM (Random Access Memory), a static storage device, a dynamic storage device, etc. The memory 1220 can store an operating system 1221 for controlling the operation of the electronic device 1200, a BIOS (Basic Input Output System) for controlling the low-level operation of the electronic device 1200. In addition, a web browser 1223, a data storage management system 1224, and a product information display processing system 1225, etc. can also be stored. The product information display processing system 1225 can be an application program for implementing the above-mentioned steps in the embodiments of the present application. In summary, when the technical solutions provided in the present application are implemented by software or firmware, the related program codes are stored in the memory 1220 and executed by the processor 1210.

[0155] The input / output interface 1213 is configured to connect an input / output module to realize information input and output. The input / output module can be configured as a component in the device (not shown in the figure) or externally connected to the device to provide corresponding functions. The input device can include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device can include a display, a speaker, a vibrator, an indicator light, etc.

[0156] The network interface 1214 is configured to connect a communication module (not shown in the figure) to realize the communication interaction between the device and other devices. The communication module can realize communication through a wired manner (such as USB, network cable, etc.) or a wireless manner (such as mobile network, WIFI, Bluetooth, etc.).

[0157] Bus 1230 includes a path for transferring information between the various components (e.g., processor 1210, video display adapter 1211, disk drive 1212, input / output interface 1213, network interface 1214, and memory 1220).

[0158] It should be noted that although the above device only shows the processor 1210, video display adapter 1211, disk drive 1212, input / output interface 1213, network interface 1214, memory 1220, bus 1230, etc., but in the process of implementation, the device can also include other components necessary for normal operation. In addition, those skilled in the art can understand that the above device can also only contain the components necessary to implement the scheme of the present application, and does not have to contain all the components shown in the figure.

[0159] From the above description of the embodiments, those skilled in the art can clearly understand that the present application can be realized by means of software and the necessary general hardware platform. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which can be stored in a storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes a number of instructions for making a computer device (which can be a personal computer, server, or network device, etc.) execute the methods described in various embodiments or some parts of the embodiments.

[0160] Each of the embodiments in the specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the different parts from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, it is described more simply, and the relevant parts can be referred to the part of the method embodiment. The above described system and system embodiment is only illustrative, and the units described as separate components can be or can not be physically separated, and the components displayed as units can be or can not be physical units, that is, they can be located in one place, or can be distributed on multiple network units. According to the actual needs, part or all of the modules can be selected to achieve the purpose of the embodiment scheme. Those skilled in the art can understand and implement without creative labor.

[0161] The above provides a detailed description of the product information display method and the electronic device provided by the application. The principles and implementation modes of the application are described by applying specific examples. The above description of the embodiments is only used to help understand the method of the application and its core idea. Meanwhile, for those skilled in the art, according to the idea of the application, the specific implementation modes and application ranges will be changed. In conclusion, the content of the specification should not be understood as a limitation of the application.

Claims

1. A commodity information display method characterized by comprising: Comprise: Determine a 3D space model and a plurality of 3D commodity models, a plurality of target positions are preset in the 3D space model, and the target positions are associated with category information of commodities that can be placed; Perform offline rendering of panoramic pictures based on ray tracing on the 3D space model to obtain a background panoramic picture layer; By respectively placing a single 3D commodity model into the target position of the corresponding category in the 3D space model, setting the material parameters of the 3D space model to be transparent and retaining light and shadow information, performing offline rendering of panoramic pictures based on ray tracing, obtaining a foreground panoramic picture layer corresponding to each of the plurality of 3D commodity models, and making the foreground panoramic picture layer reflect the light and shadow information generated by the 3D commodity model under the action of light after being placed in the 3D space model; Determine the superposition order between the layers corresponding to the plurality of target positions; After receiving a user's browsing request, determine the target commodity combination to be displayed, superimpose the background panoramic picture layer and the foreground panoramic picture layer corresponding to the plurality of commodities in the target commodity combination according to the superposition order, and generate a panoramic stereogram for displaying commodity information; wherein, when obtaining the background panoramic picture layer and the foreground panoramic picture layer, 2D pictures corresponding to planes in multiple directions of the panoramic stereogram are obtained respectively, when generating the panoramic stereogram, the 2D pictures corresponding to the background panoramic picture layer and the foreground panoramic picture layer are sequentially superimposed in the same direction according to the superposition order, and the superposition results in multiple directions are surrounded in the form of a stereogram to generate the panoramic stereogram.

2. The method of claim 1, wherein, Further comprise: Save the background panoramic picture layer as picture data containing only three primary color channels by deleting data on the transparent channel in the background panoramic picture layer.

3. The method of claim 1, wherein, Further comprise: Delete shadow part image data in the foreground panoramic picture layer with a transparency higher than a threshold value.

4. The method of claim 1, wherein: The foreground panoramic picture layer comprises 2D pictures corresponding to planes in multiple directions of a panoramic stereogram respectively; The method further comprises: Determine the circumscribed rectangle of the valid image in the 2D picture as a local cropping area, delete the blank pixels outside the local cropping area, and record the position information of the local cropping area in the 2D picture, so as to generate and superimpose the plane picture in the corresponding direction according to the position information when performing layer superposition.

5. The method of claim 1, wherein: The foreground panoramic picture layer comprises 2D pictures corresponding to planes in multiple directions of a panoramic stereogram respectively; The method further comprises: If there is no valid information in the plane in one or part of the same foreground panoramic picture layer, delete all image data of the 2D picture corresponding to the plane, and record the direction information corresponding to the plane, so as to skip the layer superposition operation in the corresponding direction when performing layer superposition.

6. The method of claim 1, wherein, Further comprise: Compress the information of the transparent channel in the foreground panoramic picture layer.

7. The method of claim 1, wherein: The method further comprises: In generating the foreground panoramic layer, the bounding rectangle of the valid image in the 2D picture is determined as a local cropping region, blank pixels outside the local cropping region are deleted, and sub-regions are divided within the local cropping region; The generating the panoramic stereogram comprises: At an initial time of rendering the panoramic stereogram, each layer is replaced by a placeholder picture; In the process of displaying by the placeholder picture, the picture of the background panoramic layer and the foreground panoramic layers corresponding to the plurality of commodities is loaded, wherein in the process of loading the picture, only image data in a part of the sub-regions located within the current field of view of the virtual camera is loaded, and in the process of moving the camera view angle, whether the sub-regions are within the field of view is determined in units of the divided sub-regions.

8. The method of claim 7, wherein, The dividing the sub-regions within the local cropping region comprises: a canvas is created according to the size of the 2D picture before cropping, and the canvas is uniformly meshed; whether each mesh and the local cropping region have an overlapping part is determined according to the position and size of the local cropping region in the canvas, and if there is an overlapping part, the mesh is reduced to the size of the overlapping part, so as to determine the reduced mesh as the sub-region divided within the local cropping region.

9. The method of claim 8, wherein, if the mesh and the local cropping region do not have an overlapping part, the mesh is reduced to zero width and height, so as to reuse the meshing result of the canvas when dividing the sub-regions of the local cropping regions corresponding to different commodities.

10. The method of claim 1, wherein, the generated background panoramic layer and each foreground panoramic layer respectively comprise a high-resolution version and a low-resolution version; in the process of rendering the panoramic stereogram, the low-resolution version is rendered first, and then the high-resolution version is rendered; and in the process of rendering the low-resolution version, the background part is rendered first, and then the foreground part is rendered from far to near, and in the process of rendering the high-resolution version, the foreground part is rendered from near to far first, and then the background part is rendered.

11. The method according to any one of claims 1 to 10, characterized in that, Further comprising: after the panoramic stereogram is generated, the virtual camera is placed at the central position of the panoramic stereogram, so as to simulate the interactive response process in the 3D scene through the panoramic stereogram.

12. A computer readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the steps of the method of any one of claims 1 to 11.

13. An electronic device, comprising: Comprise: one or more processors; and a memory associated with the one or more processors, the memory being used to store program instructions, the program instructions being read and executed by the one or more processors to perform the steps of the method of any one of claims 1 to 11.

14. A computer program product comprising computer program / computer executable instructions, characterized in that, The computer program / computer executable instructions are executed by the processor in the electronic device to implement the steps of the method of any one of claims 1 to 11. The computer program / computer executable instructions are executed by the processor in the electronic device to implement the steps of the method of any one of claims 1 to 11.

Citation Information

Patent Citations

  • Real 3D real-time mixed rendering method

    CN107256574A

  • Page information and advertisement information display method and device, equipment and storage medium

    CN115562782A