A virtual reality scene modeling method and system based on big data

By matching and dynamically configuring the component library of virtual reality models, the problem of time-consuming and labor-intensive construction of three-dimensional models and difficulty in real time adjustment of lighting textures in the existing technology is solved, and an efficient and customized virtual reality experience is achieved.

CN119672238BActive Publication Date: 2025-04-29SHENZHEN JIANGZHU TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510189351.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-20
Publication Date
2025-04-29
Estimated Expiration
2045-02-20

AI Technical Summary

Technical Problem

The prior art requires a lot of manual operation when building a three-dimensional virtual reality model, which is time-consuming and labor-intensive, and it is difficult to adjust lighting and texture parameters instantly, affecting the customization and immersion of the user experience.

Method used

By matching the model component library, texture component library and lighting component library, and quickly building a three-dimensional model based on scene demand information, and real-time rendering is performed with dynamic configuration parameters to achieve real-time adjustment of lighting and texture.

Benefits of technology

It reduces the complexity of modeling operations, improves the efficiency and performance of model rendering, and enhances the user's visual experience and rapid feedback on design effects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119672238B_ABST
    Figure CN119672238B_ABST
Patent Text Reader

Abstract

The present invention discloses a virtual reality scene modeling method and system based on big data, which relates to the field of virtual reality technology, and includes the steps of: matching a model component library, a texture component library and a lighting component library according to scene requirement information; building a three-dimensional model according to the model component library and the scene requirement information; receiving dynamic configuration parameters of the lighting component library and the texture component library, and performing real-time scene rendering on the three-dimensional model. The present invention reduces the complexity of modeling operations by matching the model component library, the texture component library and the lighting component library, and quickly building a three-dimensional model according to the model component library and the scene requirement information; by parsing the dynamic configuration parameters of the lighting and texture component libraries, the rendering effect of the three-dimensional model is updated in real time to simulate the visual effects under different lighting conditions in a virtual environment, so that the realism of materials and surfaces is improved, and rapid feedback and instant adjustment of design effects are ensured, providing a highly customized and immersive user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of virtual reality technology, and in particular to a virtual reality scene modeling method and system based on big data. Background Art

[0002] Virtual reality scenes are highly immersive simulated environments generated using advanced computer technology and graphics processing capabilities. In this environment, users can interact naturally with the virtual space through specific devices. This technology has brought far-reaching impacts to all walks of life, especially in the field of interior design.

[0003] Specifically, designers can use virtual reality to create and display highly realistic 3D interior models, allowing customers to experience the design effects in person. This immersive experience allows customers to intuitively feel the layout, lighting effects and decorative style of the space, far exceeding the information provided by traditional floor plans and static renderings. Based on the 3D interior model displayed by virtual reality, users can imagine the final effect more clearly, reducing uncertainty in understanding the design.

[0004] However, building a three-dimensional model usually requires a lot of manual work, including drawing the model from scratch, setting lighting and applying textures, which makes the modeling process time-consuming and labor-intensive. In addition, in order to achieve high-quality real-time rendering, existing technologies often require pre-loading a large amount of lighting and texture data. Therefore, when rendering effects are required, it is difficult for users to make highly customized settings according to their needs because they cannot adjust lighting and texture parameters in real time, which affects the personalization and immersion of the user experience. Summary of the invention

[0005] The present invention provides a virtual reality scene modeling method and system based on big data to solve at least one problem mentioned in the above background technology.

[0006] The specific technical solutions provided by this application are as follows:

[0007] A virtual reality scene modeling method based on big data, comprising the steps of:

[0008] Match the model component library, texture component library and lighting component library according to the scene requirement information;

[0009] Constructing a three-dimensional model according to the model component library and scene requirement information;

[0010] Receive dynamic configuration parameters of the lighting component library and the texture component library, and perform real-time scene rendering on the 3D model;

[0011] The real-time rendering of the scene of the three-dimensional model comprises the steps of:

[0012] Parse the dynamic configuration parameters of the lighting component library and texture component library;

[0013] Acquire texture image data according to the texture image path, and determine rendering data and its corresponding texture space coordinates according to the texture image data and the screen plane coordinates;

[0014] Based on the dynamic configuration parameters of the lighting component library, the 3D model is rendered in real time through the shader program;

[0015] The step of obtaining texture image data according to the texture image path comprises the following steps:

[0016] Obtain the original texture image according to the texture image path;

[0017] Acquire texture images at several resolution levels according to the original texture image;

[0018] The viewing distance ranges corresponding to the texture images of the plurality of resolution levels are set to obtain texture image data.

[0019] As a preferred solution, the matching of the model component library, the texture component library and the lighting component library according to the scene requirement information comprises the steps of:

[0020] Obtain modeling data sets and annotate and preprocess the data;

[0021] The floor plan is parsed through feature extraction algorithms to generate a scene feature matrix based on style preferences.

[0022] The scene feature matrix is ​​matched with the data in the modeling data set, and a model component library, a texture component library and a lighting component library are generated according to the similarity.

[0023] As a preferred solution, the method of determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates comprises the steps of:

[0024] Constructing a first coordinate mapping relationship between the two-dimensional plane of the screen and the three-dimensional model space, and constructing a second coordinate mapping relationship between the three-dimensional model space and the texture space;

[0025] Generate rendering data according to the texture image and the lighting model, and determine the screen plane coordinates corresponding to each rendering data;

[0026] The texture space coordinates corresponding to the rendering data are determined based on the screen plane coordinates, the first coordinate mapping relationship, and the second coordinate mapping relationship.

[0027] As a preferred solution, the real-time rendering of the scene of the three-dimensional model by the shader program based on the dynamic configuration parameters of the lighting component library includes the steps of:

[0028] Get the current distance of the viewpoint relative to the texture space coordinates of the rendered data;

[0029] Identify the corresponding level of the viewing range to which the current distance belongs;

[0030] Obtain the first texture image and the second texture image corresponding to the corresponding level and the next level respectively;

[0031] A texture map is determined according to the first texture image and the second texture image, and real-time scene rendering is performed on the three-dimensional model according to the dynamic configuration parameters of the texture map and the lighting component library.

[0032] As a preferred solution, the method of determining a texture map according to the first texture image and the second texture image comprises the steps of:

[0033] Generate a texture map sequence between the first texture image and the second texture image, and store the texture map sequence in a cache area;

[0034] Calculate the sequence weight according to the viewpoint distance and the view range of the first texture image;

[0035] The texture map selected from the texture map sequence is determined based on the sequence weight.

[0036] As a preferred solution, the texture image data is expressed as:

[0037] ,

[0038] Where i represents the level of the texture image; n is the total number of levels; is the texture image of level i; is the viewing distance range of the i-th level, and ;

[0039] The texture map sequence is expressed as:

[0040] ,

[0041] Where i is the level of the first texture image, represents the texture map sequence between the first texture image and the second texture image; j represents The sequence number of the texture map in express The jth texture map in The number of texture maps in .

[0042] As a preferred option,

[0043] The sequence weight is expressed as:

[0044] ,

[0045] Where d is the viewpoint distance, which represents the Euclidean distance between the viewpoint and the texture space coordinates. ;

[0046] Before determining the texture map selected from the texture map sequence according to the sequence weight, the method includes the following steps:

[0047] Based on the number m of texture maps in the texture map sequence, the value range of the sequence weight is divided into m weight intervals; and a mapping relationship between the weight intervals and the sequence numbers of the texture maps is constructed.

[0048] As a preferred solution, the generation of the texture map sequence between the first texture image and the second texture image is specifically to generate the texture map sequence between the first texture image and the second texture image by edge folding and point splitting; the texture map sequence stores the change information generated by each edge folding and point splitting operation.

[0049] As a preferred solution, the real-time rendering of the three-dimensional model scene according to the dynamic configuration parameters of the texture map and lighting component library is specifically: based on the dynamic configuration parameters of the lighting component library, the vertex data is projected and transformed and the lighting is calculated through the shader program, and the color of each pixel is determined in combination with the texture map.

[0050] The present invention also provides a virtual reality scene modeling system based on big data, which is used to implement the aforementioned virtual reality scene modeling method based on big data, comprising:

[0051] A component matching module is used to match the model component library, texture component library and lighting component library according to scene requirement information;

[0052] A model building module, used to build a three-dimensional model according to the model component library and scene requirement information;

[0053] Parameter parsing module, used to parse the dynamic configuration parameters of the lighting component library and texture component library;

[0054] A coordinate conversion module, used for determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates;

[0055] The scene rendering module is used to perform real-time scene rendering of the 3D model through the shader program based on the dynamic configuration parameters of the lighting component library.

[0056] Compared with the prior art, the present invention has the following beneficial effects:

[0057] The present invention reduces the complexity of modeling operations by matching the model component library, the texture component library and the lighting component library, and quickly building a three-dimensional model according to the model component library and scene requirement information; by parsing the dynamic configuration parameters of the lighting and texture component libraries, the rendering effect of the three-dimensional model is updated in real time to simulate the visual effects under different lighting conditions in a virtual environment, thereby improving the realism of materials and surfaces, ensuring rapid feedback and instant adjustment of design effects, and providing a highly customized and immersive user experience.

[0058] In the drawing process provided by the embodiment of the present invention, lighting and texture are calculated in real time through a shader program, and the results are cached in a frame buffer, thereby realizing real-time dynamic rendering, effectively utilizing the cache function of the frame buffer, ensuring that delays are reduced during the generation process, improving the efficiency and performance of the overall model rendering, and enhancing the user's visual experience.

[0059] The embodiment of the present invention obtains the first texture image and the second texture image according to the viewing distance range and performs a smooth transition between the two, thereby reducing the abruptness when switching between different resolutions, significantly reducing the generation of visual artifacts, improving the continuity and visual quality of scene rendering, and providing a more natural and smooth user experience; dynamically selecting and loading the required texture level data according to the viewpoint distance rather than loading all levels of textures at one time, thereby reducing memory usage, optimizing resource management, and improving the operating efficiency of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0061] 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.

[0062] Figure 1 A schematic diagram of a flow chart of a method for virtual reality scene modeling based on big data provided by an embodiment of the present invention;

[0063] Figure 2 A schematic diagram of a process for performing real-time scene rendering on a three-dimensional model provided by an embodiment of the present invention;

[0064] Figure 3 A schematic diagram of a process for determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates provided by an embodiment of the present invention;

[0065] Figure 4A schematic diagram of a process of determining a texture map according to a first texture image and a second texture image provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0066] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0067] It should be noted that all directional indications (such as up, down, left, right, front, back, etc.) in the embodiments of the present invention are only used to explain the relative position relationship, movement status, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly.

[0068] In addition, the descriptions of "first", "second", etc. in the present invention are only used for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the ability of ordinary technicians in the field to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.

[0069] Virtual reality scenes are highly immersive simulated environments generated using advanced computer technology and graphics processing capabilities. In this environment, users can interact naturally with the virtual space through specific devices. This technology has brought far-reaching impacts to all walks of life, especially in the field of interior design.

[0070] Specifically, designers can use virtual reality to create and display highly realistic 3D interior models, allowing customers to experience the design effects in person. This immersive experience allows customers to intuitively feel the layout, lighting effects and decorative style of the space, far exceeding the information provided by traditional floor plans and static renderings. Based on the 3D interior model displayed by virtual reality, users can imagine the final effect more clearly, reducing uncertainty in understanding the design.

[0071] However, building a three-dimensional model usually requires a lot of manual work, including drawing the model from scratch, setting lighting and applying textures, which makes the modeling process time-consuming and labor-intensive. In addition, in order to achieve high-quality real-time rendering, existing technologies often require pre-loading a large amount of lighting and texture data. Therefore, when rendering effects are required, it is difficult for users to make highly customized settings according to their needs because they cannot adjust lighting and texture parameters in real time, which affects the personalization and immersion of the user experience.

[0072] See also Figure 1 The present invention provides a virtual reality scene modeling method based on big data, comprising the steps of:

[0073] S1. Match the model component library, texture component library and lighting component library according to the scene requirement information;

[0074] Among them, the scene demand information includes floor plans and style preferences. Match suitable virtual reality scene elements according to the floor plans and style preferences provided by the user. These scene elements include model component libraries at all levels (such as furniture and building components), texture component libraries (such as wall and floor materials, colors), and lighting component libraries (such as light types, positions, and intensities). By parsing the floor plans submitted by users, you can understand the layout structure of the house, such as the location and size of the rooms, the location of doors and windows, etc. This information will help select and arrange appropriate model component libraries. For example, a room needs to be placed with sofas, cabinets and other furniture; by analyzing the user's aesthetic preferences and design style preferences, find the decorative elements and materials that best meet these preferences from our database. For example, a modern style may require simple furniture and metal-textured surfaces, while a pastoral style may require more wood textures and natural color decorations.

[0075] Furthermore, matching the model component library, the texture component library and the lighting component library according to the scene requirement information comprises the steps of:

[0076] S11, obtaining a modeling data set and annotating and preprocessing the data;

[0077] The modeling data set includes several design model samples, including floor plans, texture component libraries, and lighting component libraries. Floor plans can include floor plans in engineering drawings (CAD) or digital formats. Design model samples are classified by preset styles. Texture component libraries include materials and patterns of component libraries such as walls, floors, and furniture. Lighting component libraries include light sources of different types and configurations, including directional light, point light, soft light, etc.

[0078] The data is annotated, specifically: annotate the collected design model samples, obtain their floor plans, annotate the room functions (such as bedrooms, living rooms), sizes, door and window locations, etc.; add labels to the design model samples, annotate the style type and specific component library features corresponding to each sample (such as the color and material preferences of the texture component library and lighting component library).

[0079] Preprocessing includes: formatting the data uniformly, such as converting all floor plans into vector graphics or standardized image formats; adjusting the resolution of the images; cleaning the data, removing duplicate, blurred or incomplete samples, and ensuring the quality of the data set; standardizing the description of the texture and lighting component library so that they can be efficiently retrieved in the database.

[0080] In this embodiment, the modeling dataset may be an open source project dataset, a commercial dataset, a self-built dataset (obtained through field measurement, photographing or scanning of existing buildings and interior designs), an internal dataset (preserved through long-term project experience and design storage), etc.

[0081] S12, parsing the floor plan of the scene demand information through a feature extraction algorithm, and generating a scene feature matrix in combination with style preferences;

[0082] The feature extraction algorithm is used to automatically identify the boundaries and room structures of each part of the floor plan, and the key features of the floor plan are identified. The feature extraction algorithm includes existing mature algorithms such as edge detection, shape recognition, and region segmentation. The key features include the area, shape, layout, wall, and door and window positions of each room.

[0083] Style preferences include information such as color preferences, material selection, layout style, etc. These style preference information will be converted into specific style feature values, such as modern style may include minimalist colors and smooth surface features, and industrial style may emphasize metal texture and rough surface.

[0084] The parsed floor plan features and style features are combined to form a feature matrix, which fully describes the user's specific needs. The feature matrix represents the size, shape, location of each room, and the overall design style expectations.

[0085] S13, matching the scene feature matrix with the data in the modeling data set, and generating a model component library, a texture component library and a lighting component library according to the similarity.

[0086] The model component library, texture component library and lighting component library in the modeling dataset are matched using the field feature matrix. The matching algorithm can use distance measurement, similarity calculation (such as cosine similarity, Euclidean distance) and other methods.

[0087] Compare the feature vector of each component library with the scene feature matrix to find the matching result with the highest similarity.

[0088] Based on the similarity score, select several most matching model component libraries (such as furniture, walls), texture component libraries (such as wood grain, floor tiles), and lighting component libraries (such as lighting type, location). Give priority to component libraries with high similarity scores, and build model component libraries, texture component libraries, and lighting component libraries to ensure that the results best meet the user's needs and design style preferences.

[0089] S2. constructing a three-dimensional model according to the model component library and scene requirement information;

[0090] To build a 3D model, first import the floor plan with the analyzed scene requirement information into the modeling software, and then generate the basic 3D geometric structure of the room, including walls, floors and ceilings, based on the information such as the positions of walls, doors and windows in the floor plan.

[0091] According to the model component library obtained in step S1, model components are selected from high to low according to the similarity of the matching results and placed in the three-dimensional model, and the positions of the components are adjusted to meet the actual design requirements and style preferences.

[0092] S3, receiving dynamic configuration parameters of the lighting component library and the texture component library, and performing real-time scene rendering on the three-dimensional model.

[0093] In principle, model components (such as furniture and decorations) have a certain geometric shape and size, which are fixed in this embodiment when the three-dimensional model is initially constructed in step S2. However, the lighting components (including light source type, position, brightness, etc.) and texture components (including color, material, pattern, etc.) are highly dependent on the final visual effect and need to be adjusted and tested repeatedly to achieve the best effect. Different lighting and texture combinations can significantly change the atmosphere and detail display effect of the entire scene. These adjustments are usually made based on visual feedback, so they are dynamically configured in this application.

[0094] In virtual reality scenes, real-time rendering technology allows users to instantly see the effects of changes in lighting and materials.

[0095] According to the user's personalized adjustment needs, such as changing the wall color or adjusting the position of the light source, dynamic configuration enables the system to respond quickly to needs without having to rebuild the entire 3D model, reducing the subsequent calculation burden, and dynamic configuration of lighting and texture can be performed within a unified basic framework, avoiding repeated processing and resource waste, and improving system efficiency.

[0096] For further information, see Figure 2 The real-time rendering of the scene of the three-dimensional model comprises the steps of:

[0097] S31, parsing the dynamic configuration parameters of the lighting component library and the texture component library. The dynamic configuration parameters of the lighting component library and the texture component library are received from the user interface or the automatic configuration system, and the received parameters are parsed and converted into a format suitable for processing by the rendering engine. The dynamic configuration parameters of the lighting component library include the light source position, lighting color and lighting intensity, and the dynamic configuration parameters of the texture component library include the texture image path and the screen plane coordinates.

[0098] S32. Acquire texture image data according to the texture image path, and determine rendering data and its corresponding texture space coordinates according to the texture image data and the screen plane coordinates.

[0099] S33, based on the dynamic configuration parameters of the lighting component library, the three-dimensional model is rendered in real time through the shader program. Specifically, the scene is rendered in real time by binding the configured light source information and texture to the rendering pipeline, and then drawing the models in the scene one by one; in each drawing process, the shader program performs real-time calculations based on the texture image and the lighting component library, and then caches the calculation results in the frame buffer and presents them on the screen.

[0100] In the drawing process provided by this embodiment, lighting and texture are calculated in real time through the shader program, and the results are cached in the frame buffer, thereby realizing real-time dynamic rendering, effectively utilizing the caching function of the frame buffer, ensuring that delays are reduced during the generation process, improving the efficiency and performance of the overall model rendering, and enhancing the user's visual experience.

[0101] As a preferred embodiment, step S32, the step of acquiring texture image data according to the texture image path, comprises the steps of:

[0102] S3211, obtaining an original texture image according to a texture image path;

[0103] S3212, acquiring texture images of several resolution levels according to the original texture image;

[0104] Among the texture images of several resolution levels, the original texture image is the texture image with the highest resolution; based on the original texture image, an image scaling algorithm (such as bilinear interpolation or bicubic interpolation) is used to generate low-resolution texture images step by step. In one embodiment, the original image is reduced to set as the first layer, i.e., the bottom layer, and then the bottom layer is reduced to generate the second layer, and so on, until the image size is 1×1 pixel, so the texture image of each subsequent level is usually half the size of the previous level (i.e., the width and height are halved).

[0105] S3213, setting the viewing distance ranges corresponding to the texture images of the several resolution levels, and obtaining texture image data. It can be understood that the texture image data includes several texture images of different resolutions and their corresponding viewing distance ranges. The texture image data is represented as:

[0106]

[0107] Where i represents the level of the texture image; n is the total number of levels; is the texture image of level i; is the viewing distance range of the i-th level, and Based on the viewing distance range corresponding to the texture image of each level, when the three-dimensional model is rendered in real time, the texture image is selected for rendering according to the current viewing distance obtained in real time.

[0108] For further information, see Figure 3 , step S32, determining the rendering data and its corresponding texture space coordinates according to the texture image data and the screen plane coordinates, comprises the steps of:

[0109] S3221, constructing a first coordinate mapping relationship between the two-dimensional plane of the screen and the three-dimensional model space, and constructing a second coordinate mapping relationship between the three-dimensional model space and the texture space;

[0110] S3222, generating rendering data according to the texture image and the illumination model, and determining the screen plane coordinates corresponding to each rendering data;

[0111] S3223. Determine the texture space coordinates corresponding to the rendering data based on the screen plane coordinates, the first coordinate mapping relationship, and the second coordinate mapping relationship.

[0112] This embodiment is based on the first coordinate mapping between the two-dimensional plane of the screen and the three-dimensional model space, which ensures that the two-dimensional coordinates displayed on the screen can be accurately converted into the spatial coordinates of the three-dimensional model, ensuring the accurate mapping of the texture; the second coordinate mapping based on the three-dimensional model space and the texture space ensures that each point in the three-dimensional model can find the corresponding texture position, so that every detail of the texture map can be accurately reflected in the virtual scene. By constructing the dual mapping relationship between the two-dimensional plane of the screen and the three-dimensional model space, and the three-dimensional model space and the texture space, and generating and optimizing rendering data based on these mapping relationships, this solution can efficiently and accurately realize texture rendering, significantly improving the visual quality and user experience in the virtual reality scene.

[0113] The static LOD algorithm is a technology used in computer graphics to improve rendering performance and efficiency. It selects the detail level of an object based on the distance between the camera viewpoint and the object, thereby reducing computational complexity. However, the static LOD algorithm may produce abrupt visual artifacts due to the switching of texture images of different resolution levels as texture maps at a specific distance; and the static LOD algorithm needs to store multiple versions of the model, which may increase memory usage. To solve this problem, based on the aforementioned embodiment, further, step S33, the dynamic configuration parameters based on the lighting component library, the real-time rendering of the scene of the three-dimensional model through the shader program, includes the steps of:

[0114] S331, obtaining the current distances of the viewpoints relative to the texture space coordinates of the rendering data;

[0115] S332, identifying the corresponding level of the viewing range to which the current distance belongs;

[0116] S333, obtaining a first texture image and a second texture image corresponding to the corresponding level and the next level respectively;

[0117] S334, determining a texture map according to the first texture image and the second texture image, and performing real-time scene rendering on the three-dimensional model according to the texture map and dynamic configuration parameters of the lighting component library.

[0118] This embodiment obtains the first texture image and the second texture image according to the viewing distance range and performs a smooth transition between the two, thereby reducing the abruptness when switching between different resolutions, significantly reducing the generation of visual artifacts, improving the continuity and visual quality of scene rendering, and providing a more natural and smooth user experience. It dynamically selects and loads the required texture level data according to the viewpoint distance instead of loading all levels of textures at once, thereby reducing memory usage, optimizing resource management, and improving the operating efficiency of the system.

[0119] For further information, see Figure 4 The step of determining the texture map according to the first texture image and the second texture image comprises the following steps:

[0120] S3341, generating a texture map sequence between the first texture image and the second texture image, and storing the texture map sequence in a cache area;

[0121] The texture map sequence is expressed as:

[0122]

[0123] Where i is the level of the first texture image, represents the texture map sequence between the first texture image and the second texture image; j represents The sequence number of the texture map in express The jth texture map in The number of texture maps in .

[0124] Furthermore, the generating of the texture mapping sequence between the first texture image and the second texture image is specifically generating the texture mapping sequence between the first texture image and the second texture image by edge folding and point splitting. Specifically, edge folding comprises the steps of:

[0125] Edge selection: In the mesh of the first texture image, select an edge with the smallest error; the selected edge can reduce the number of polygons in the mesh by folding;

[0126] Vertex fusion: merge two vertices of an edge into a new vertex; the position of the new vertex is the midpoint of the original two vertices or calculated according to the weight;

[0127] Update Mesh: Adjusts texture mapping and updates the mesh so that the new vertex positions and texture coordinates are continuous.

[0128] The edge selection, fixed-point fusion and network update steps are iterated to gradually reduce vertices and faces and store them as folding information until a mesh consistent with the second texture image is reached.

[0129] Point splitting includes the steps:

[0130] Vertex recovery: In the mesh of the second texture image, the collapsed vertex is split into two vertices according to the collapsed information;

[0131] The vertex restoration step is iterated to gradually increase the number of vertices and faces until a mesh consistent with the first texture image is restored.

[0132] Based on the texture map sequence generated by the aforementioned edge folding and point splitting, the change information generated by each edge folding and point splitting operation (including vertex position changes and corresponding texture coordinate changes) is stored instead of the complete mesh and texture data. The texture map sequence is generated by performing edge folding and point splitting operations in advance and stored in the cache. When actually used, the pre-generated texture maps are directly read from the cache according to demand, avoiding the overhead of real-time calculation.

[0133] S3342, calculating the sequence weight according to the viewpoint distance and the viewing range of the first texture image; the viewing range is expressed as , the sequence weight is expressed as:

[0134]

[0135] Where d is the viewpoint distance, which represents the Euclidean distance between the viewpoint and the texture space coordinates. , .

[0136] S3343. Determine the texture map to be selected from the texture map sequence according to the sequence weight.

[0137] Furthermore, before determining the texture map selected from the texture map sequence according to the sequence weight, the steps include:

[0138] Based on the number m of texture maps in the texture map sequence, the value range of the sequence weight is divided into m weight intervals; a mapping relationship between the weight interval and the sequence number of the texture map is constructed; for example, if the number of texture maps in the texture map sequence is 10, the value range of the sequence weight is Divide it into 10 weight intervals, and build a mapping relationship between each weight interval and the sequence number of the texture map, for example The value of [0,0.1] corresponds to The first texture map in Based on the mapping relationship between the aforementioned weight interval and the sequence number of the texture map, the texture map selected in the texture map sequence can be determined according to the sequence weight. When the texture map has been determined, it is passed as a parameter to the shader program, and real-time rendering is performed in combination with the dynamic configuration parameters of the lighting component library to ensure a smooth transition of the visual effect while maintaining efficient rendering performance, and avoid abrupt artifacts caused by large errors between the first texture image and the second texture image.

[0139] Furthermore, in step S334, the real-time rendering of the scene of the three-dimensional model according to the dynamic configuration parameters of the texture map and the lighting component library is specifically as follows:

[0140] S3344. Based on the dynamic configuration parameters of the lighting component library, the vertex data is projected and transformed and the lighting is calculated through the shader program, and the color of each pixel is determined in combination with the texture map.

[0141] Among them, the projection transformation and lighting calculation of vertex data are realized through the vertex shader. The vertex shader receives the attribute data of each vertex, including position, normal, texture coordinates, etc.; converts the vertex coordinates from model space to world space, then to observation space, and finally to clipping space for frustum clipping. Then, the preliminary lighting effect is calculated by combining the light source data and the vertex normal to obtain the lighting intensity and lighting color of each vertex.

[0142] The color of each pixel is determined by combining the texture map through the fragment shader. The fragment shader receives the fragment (pixel) data after interpolation by the vertex shader, including position, normal, texture coordinates, light intensity and light color; based on the light intensity, the color of the texture map is mixed with the light color, and the final color of each pixel is calculated and output.

[0143] The present invention also provides a virtual reality scene modeling system based on big data, comprising:

[0144] A component matching module is used to match the model component library, texture component library and lighting component library according to scene requirement information;

[0145] A model building module, used to build a three-dimensional model according to the model component library and scene requirement information;

[0146] Parameter parsing module, used to parse the dynamic configuration parameters of the lighting component library and texture component library;

[0147] A coordinate conversion module, used for determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates;

[0148] The scene rendering module is used to perform real-time scene rendering of the 3D model through the shader program based on the dynamic configuration parameters of the lighting component library.

[0149] The present invention reduces the complexity of modeling operations by matching the model component library, the texture component library and the lighting component library, and quickly building a three-dimensional model according to the model component library and scene requirement information; by parsing the dynamic configuration parameters of the lighting and texture component libraries, the rendering effect of the three-dimensional model is updated in real time to simulate the visual effects under different lighting conditions in a virtual environment, thereby improving the realism of materials and surfaces, ensuring rapid feedback and instant adjustment of design effects, and providing a highly customized and immersive user experience.

[0150] In the embodiments provided in the present application, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely schematic. For example, the division of the modules is only a logical function division. There may be other division methods in actual implementation, such as multiple modules or component libraries can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the modules can be electrical, mechanical or other forms.

[0151] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple grid modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.

[0152] In addition, each functional module in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or software functional modules.

[0153] If the integrated module is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or grid device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, dynamic hard disk, read-only memory (ROM, read-only memory), random access memory (RAM, random access memory), disk or optical disk, etc. Various media that can store program codes.

[0154] The foregoing is merely a specific embodiment of the present invention, which enables those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features claimed herein.

Claims

1. A virtual reality scene modeling method based on big data, characterized by: Includes steps: Match the model component library, texture component library and lighting component library according to the scene requirement information; Constructing a three-dimensional model according to the model component library and scene requirement information; Receive dynamic configuration parameters of the lighting component library and the texture component library, and perform real-time scene rendering on the 3D model; The real-time rendering of the scene of the three-dimensional model comprises the steps of: Parse the dynamic configuration parameters of the lighting component library and texture component library; Acquire texture image data according to the texture image path, and determine rendering data and its corresponding texture space coordinates according to the texture image data and the screen plane coordinates; Based on the dynamic configuration parameters of the lighting component library, the 3D model is rendered in real time through the shader program; The step of obtaining texture image data according to the texture image path comprises the following steps: Obtain the original texture image according to the texture image path; Acquire texture images at several resolution levels according to the original texture image; Setting the viewing distance ranges corresponding to the texture images of the plurality of resolution levels respectively to obtain texture image data; The method of performing real-time scene rendering of a three-dimensional model through a shader program based on the dynamic configuration parameters of the lighting component library comprises the following steps: Get the current distance of the viewpoint relative to the texture space coordinates of the rendered data; Identify the corresponding level of the viewing range to which the current distance belongs; Obtain the first texture image and the second texture image corresponding to the corresponding level and the next level respectively; Determine a texture map according to the first texture image and the second texture image, and perform real-time scene rendering on the three-dimensional model according to dynamic configuration parameters of the texture map and the lighting component library; The method of determining a texture map according to the first texture image and the second texture image comprises the steps of: Generate a texture map sequence between the first texture image and the second texture image, and store the texture map sequence in a cache area; Calculate the sequence weight according to the viewpoint distance and the view range of the first texture image; Determine the texture map selected from the texture map sequence according to the sequence weight; The real-time rendering of the scene of the three-dimensional model according to the dynamic configuration parameters of the texture map and the lighting component library is specifically: based on the dynamic configuration parameters of the lighting component library, the vertex data is projected and transformed and the lighting is calculated through the shader program, and the color of each pixel is determined in combination with the texture map.

2. The method for virtual reality scene modeling based on big data according to claim 1, characterized in that: The matching of the model component library, the texture component library and the lighting component library according to the scene requirement information comprises the steps of: Obtain modeling data sets and annotate and preprocess the data; The floor plan is parsed through feature extraction algorithms to generate a scene feature matrix based on style preferences. The scene feature matrix is ​​matched with the data in the modeling data set, and a model component library, a texture component library and a lighting component library are generated according to the similarity.

3. The method for virtual reality scene modeling based on big data according to claim 1, characterized in that: The method of determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates comprises the steps of: Constructing a first coordinate mapping relationship between the two-dimensional plane of the screen and the three-dimensional model space, and constructing a second coordinate mapping relationship between the three-dimensional model space and the texture space; Generate rendering data according to the texture image and the lighting model, and determine the screen plane coordinates corresponding to each rendering data; The texture space coordinates corresponding to the rendering data are determined based on the screen plane coordinates, the first coordinate mapping relationship, and the second coordinate mapping relationship.

4. The method for virtual reality scene modeling based on big data according to claim 1, characterized in that: The texture image data is expressed as: , Where i represents the level of the texture image; n is the total number of levels; is the texture image of the i-th level; is the viewing distance range of the i-th level, and ; The texture map sequence is expressed as: , Where i is the level of the first texture image, represents the texture map sequence between the first texture image and the second texture image; j represents The sequence number of the texture map in express The jth texture map in The number of texture maps in .

5. The method for virtual reality scene modeling based on big data according to claim 4, characterized in that: The sequence weight is expressed as: , Where d is the viewpoint distance, which represents the Euclidean distance between the viewpoint and the texture space coordinates. ; Before determining the texture map selected from the texture map sequence according to the sequence weight, the method includes the following steps: Based on the number m of texture maps in the texture map sequence, the value range of the sequence weight is divided into m weight intervals; and a mapping relationship between the weight intervals and the sequence numbers of the texture maps is constructed.

6. The method for virtual reality scene modeling based on big data according to claim 1, characterized in that: The generating of the texture mapping sequence between the first texture image and the second texture image is specifically generating the texture mapping sequence between the first texture image and the second texture image by edge folding and point splitting; the texture mapping sequence stores the change information generated by each edge folding and point splitting operation.

7. A virtual reality scene modeling system based on big data, characterized by: A method for implementing a virtual reality scene modeling method based on big data as claimed in any one of claims 1 to 6, comprising: A component matching module is used to match the model component library, texture component library and lighting component library according to scene requirement information; A model building module, used to build a three-dimensional model according to the model component library and scene requirement information; Parameter parsing module, used to parse the dynamic configuration parameters of the lighting component library and texture component library; A coordinate conversion module, used for determining rendering data and its corresponding texture space coordinates according to texture image data and screen plane coordinates; The scene rendering module is used to perform real-time scene rendering of the 3D model through the shader program based on the dynamic configuration parameters of the lighting component library.

Citation Information

Patent Citations

  • Preprocessing dynamic modeling system and method based on virtual reality simulation

    CN116305368A

  • Computer graphic rendering method and system based on ray tracing

    CN117523070A