CN115861502A - Weather rendering method and device in virtual environment, storage medium and electronic equipment - Google Patents

Weather rendering method and device in virtual environment, storage medium and electronic equipment Download PDF

Info

Publication number
CN115861502A
CN115861502A CN202111116584.5A CN202111116584A CN115861502A CN 115861502 A CN115861502 A CN 115861502A CN 202111116584 A CN202111116584 A CN 202111116584A CN 115861502 A CN115861502 A CN 115861502A
Authority
CN
China
Prior art keywords
data
weather
virtual
scene
rendering
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111116584.5A
Other languages
Chinese (zh)
Inventor
王毅
黄柏云
赵冰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Boguan Information Technology Co Ltd
Original Assignee
Guangzhou Boguan Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Boguan Information Technology Co Ltd filed Critical Guangzhou Boguan Information Technology Co Ltd
Priority to CN202111116584.5A priority Critical patent/CN115861502A/en
Publication of CN115861502A publication Critical patent/CN115861502A/en
Pending legal-status Critical Current

Links

Images

Abstract

The disclosure belongs to the technical field of data processing, and relates to a weather rendering method and device in a virtual environment, a storage medium and electronic equipment. The method comprises the following steps: acquiring current time data in a virtual scene, and performing format conversion processing on the current time data to obtain conversion time data; and obtaining scene weather data for rendering the virtual scene, and performing attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene. The virtual weather scene is rendered according to the conversion time data, the weather effect of the virtual scene can be changed in real time, the problem of virtual scene deadlock caused by single setting of weather and light color in the existing virtual scene is solved, the intelligentization and automation degree of weather rendering are improved, various virtual weather effects can be created by using various scene weather data, diversified visual feelings are provided, the user experience is enriched, and the user experience is optimized.

Description

Weather rendering method and device in virtual environment, storage medium and electronic equipment
Technical Field
The present disclosure relates to the field of data processing technologies, and in particular, to a weather rendering method in a virtual environment, a weather rendering apparatus in a virtual environment, a computer-readable storage medium, and an electronic device.
Background
In the fields of live game, live virtual broadcast, MV (Music Video) production, virtual reality performance and the like, which require to merge virtual scenes, the related application of "virtualization" is continuously getting a breakthrough. For example, in the virtual studio technology in the film and television industry, numerous technologies such as color key matting, three-dimensional graphics, video synthesis, virtual lighting effect production and the like are combined, so that characters and props are positioned in a virtual scene generated by a computer, and vivid and three-dimensional visual effects are simulated.
However, in the current virtual technology, the weather and the light color in the virtual scene are preset in advance and cannot be changed, so that the effect of the virtual scene is single, and the impressions of the player and the audience are influenced.
In view of the above, there is a need in the art to develop a new method and apparatus for weather rendering in a virtual environment.
It is to be noted that the information disclosed in the above background section is only for enhancement of understanding of the background of the present disclosure, and thus may include information that does not constitute prior art known to those of ordinary skill in the art.
Disclosure of Invention
An object of the present disclosure is to provide a weather rendering method in a virtual environment, a weather rendering apparatus in a virtual environment, a computer-readable storage medium, and an electronic device, thereby overcoming, at least to some extent, the technical problems of poor real-time performance and single virtual scene due to the limitations of the related art.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows, or in part will be obvious from the description, or may be learned by practice of the disclosure.
According to a first aspect of embodiments of the present invention, there is provided a method of weather rendering in a virtual environment, the method comprising:
acquiring current time data in a virtual scene, and performing format conversion processing on the current time data to obtain conversion time data;
and obtaining scene weather data for rendering the virtual scene, and performing attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
In an exemplary embodiment of the invention, the method further comprises:
acquiring target color value data in the scene weather data, and performing protocol data conversion on the target color value data to obtain target protocol data;
and adjusting the entity light source data corresponding to the virtual scene by using the target protocol data.
In an exemplary embodiment of the invention, the target protocol data includes: DMX512 protocol data.
In an exemplary embodiment of the present invention, the scene weather data includes: virtual weather data and virtual light color data.
In an exemplary embodiment of the present invention, the performing attribute rendering processing on the scene weather data according to the conversion time data to obtain a virtual weather scene includes:
acquiring a weather corresponding relation between the conversion time data and the virtual weather data, and acquiring a light color corresponding relation between the conversion time data and the virtual light color data;
and performing attribute rendering processing according to the conversion time data, the weather corresponding relation and the light color corresponding relation to obtain a virtual weather scene.
In an exemplary embodiment of the present invention, the virtual weather data includes: atmospheric fog data and volumetric cloud data.
In an exemplary embodiment of the invention, the virtual photochromic data includes: background maps, sky light source data, and sunlight data.
According to a second aspect of the embodiments of the present invention, there is provided a weather rendering apparatus in a virtual environment, including:
the time conversion module is configured to acquire current time data in a virtual scene and perform format conversion processing on the current time data to obtain conversion time data;
and the weather rendering module is configured to acquire scene weather data for rendering the virtual scene, and perform attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
According to a third aspect of embodiments of the present invention, there is provided an electronic apparatus including: a processor and a memory; wherein the memory has stored thereon computer readable instructions which, when executed by the processor, implement a method of weather rendering in a virtual environment in any of the exemplary embodiments described above.
According to a fourth aspect of embodiments of the present invention, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements a method of weather rendering in a virtual environment in any of the above-described exemplary embodiments.
As can be seen from the foregoing technical solutions, the weather rendering method in a virtual environment, the weather rendering apparatus in a virtual environment, the computer storage medium, and the electronic device in the exemplary embodiments of the present disclosure have at least the following advantages and positive effects:
in the method and the device provided by the exemplary embodiment of the disclosure, the attribute rendering processing is performed on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene, so that the weather effect of the virtual scene can be changed in real time, the problem of virtual scene rigid caused by single setting of weather and light color in the existing virtual scene is solved, the flexibility of weather rendering is improved, the intelligentization and automation degree of the weather rendering are improved, various virtual weather effects can be created by using various scene weather data, diversified visual feelings are provided, the user impression is richer, and the user experience is optimized.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure. It is to be understood that the drawings in the following description are merely exemplary of the disclosure, and that other drawings may be derived from those drawings by one of ordinary skill in the art without the exercise of inventive faculty.
Fig. 1 schematically illustrates a flow diagram of a method of weather rendering in a virtual environment in an exemplary embodiment of the disclosure;
FIG. 2 schematically illustrates a flow diagram of a method of attribute rendering processing in an exemplary embodiment of the disclosure;
fig. 3 schematically illustrates a flow chart of a method of adjusting physical light source data in an exemplary embodiment of the present disclosure;
FIG. 4 is a system framework diagram schematically illustrating a method for weather rendering in a virtual environment in an application scenario in an exemplary embodiment of the present disclosure;
FIG. 5 is a schematic diagram illustrating a structure of a weather rendering apparatus in a virtual environment according to an exemplary embodiment of the disclosure;
FIG. 6 schematically illustrates an electronic device for implementing a method of weather rendering in a virtual environment in an exemplary embodiment of the present disclosure;
fig. 7 schematically illustrates a computer-readable storage medium for implementing a weather rendering method in a virtual environment in an exemplary embodiment of the present disclosure.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of the disclosure. One skilled in the relevant art will recognize, however, that the embodiments of the present disclosure can be practiced without one or more of the specific details, or with other methods, components, devices, steps, etc. In other instances, well-known technical solutions have not been shown or described in detail to avoid obscuring aspects of the present disclosure.
The terms "a," "an," "the," and "said" are used in this specification to denote the presence of one or more elements/components/parts/etc.; the terms "comprising" and "having" are intended to be inclusive and mean that there may be additional elements/components/etc. other than the listed elements/components/etc.; the terms "first" and "second", etc. are used merely as labels, and are not limiting on the number of their objects.
Furthermore, the drawings are merely schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus their repetitive description will be omitted. Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities.
In view of the problems in the related art, the present disclosure provides a method for weather rendering in a virtual environment. Fig. 1 shows a flow chart of a method for rendering weather in a virtual environment, as shown in fig. 1, the method for rendering weather in a virtual environment at least comprises the following steps:
and S110, acquiring current time data in the virtual scene, and performing format conversion processing on the current time data to obtain conversion time data.
And S120, obtaining scene weather data for rendering the virtual scene, and performing attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
In the exemplary embodiment of the disclosure, the attribute rendering processing is performed on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene, the weather effect of the virtual scene can be changed in real time, the problem of virtual scene deadlock caused by singly setting weather and light color in the existing virtual scene is solved, the flexibility of weather rendering is improved, the intelligentization and automation degree of the weather rendering is also improved, various virtual weather effects can be created by using various scene weather data, diversified visual feelings are provided, the user experience is enriched, and the user experience is optimized.
The following describes in detail the steps of the method for rendering weather in a virtual environment.
In step S110, current time data in the virtual scene is acquired, and format conversion processing is performed on the current time data to obtain conversion time data.
In an exemplary embodiment of the present disclosure, the virtual scene may be any virtual scene such as a live game, a virtual live broadcast, MV production, and a virtual reality show, and this exemplary embodiment is not particularly limited to this.
The current time data may be time data of a system time block. And, the current time data may be time data in time, minute, second format.
Further, the current time data may be subjected to a format conversion process.
Specifically, the format conversion process may be converting the current time data in the time, minute, and second format into conversion time data in units of hours. In addition, the time data may also be converted into time data in other formats according to actual requirements, which is not particularly limited in this exemplary embodiment.
In step S120, scene weather data for rendering the virtual scene is obtained, and attribute rendering processing is performed on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
In exemplary embodiments of the present disclosure, scene weather data for rendering a virtual scene may also be obtained.
In an alternative embodiment, the scene weather data includes: virtual weather data and virtual light color data.
Further, the virtual weather data and the virtual light color data may also include other data, respectively.
In an alternative embodiment, the virtual weather data comprises: atmospheric fog data and volumetric cloud data.
Specifically, the atmospheric fog data may include the concentration, range, and color of the atmospheric fog, and may also include other data, which is not limited in this exemplary embodiment.
The volume cloud data may include data such as density, color, and movement speed of the volume cloud, and may also include other data, which is not particularly limited in this exemplary embodiment.
It should be noted that the virtual weather data may include rain data corresponding to raining and other weather-related data in any real scene, besides the atmospheric fog data and the volume cloud data, and this exemplary embodiment is not particularly limited in this respect.
In another alternative embodiment, the virtual light color data comprises: background maps, sky light source data, and sunlight data.
The background map may include color and brightness of an HDRI (High-Dynamic Range image) background map, the sky-light source data may include data of illuminance, color temperature, shadow softness, and the like of skyilight, and the sunlight data may include data of illuminance, color temperature, color value, shadow softness, position, and the like of sunlight. The skylight data may be associated with virtual light color data or virtual weather data, which is not limited in this exemplary embodiment.
The virtual light color data may also include other data that affects light color, which is the same as that of the real scene, and the background map, the sky light source data, and the sunlight data may also include other data, which is not limited in this exemplary embodiment.
After the scene weather data is obtained, attribute rendering processing can be further performed on the scene weather data according to the conversion time data.
In an alternative embodiment, fig. 2 shows a flow diagram of a method of attribute rendering processing, as shown in fig. 2, the method at least comprising the steps of: in step S210, a weather correspondence between the conversion time data and the virtual weather data is obtained, and a light color correspondence between the conversion time data and the virtual light color data is obtained.
The weather correspondence may be data reflecting a change in the virtual weather data with the conversion time data. Moreover, the weather corresponding relationship may be in a form of a change curve between the virtual weather data and the conversion time data, or in a form of an algorithm between the virtual weather data and the conversion time data, which is not particularly limited in this exemplary embodiment.
The light color correspondence may be data reflecting a change in the virtual light color data with the conversion time data. The light color corresponding relationship may be in the form of a variation curve between the virtual light color data and the conversion time data, or in the form of an algorithm between the virtual light color data and the conversion time data, which is not limited in this exemplary embodiment.
It should be noted that, since the virtual weather data includes different types of data such as atmospheric fog data and volume cloud data, the weather correspondence relationship may include a plurality of weather correspondence relationships, that is, one weather correspondence relationship may reflect a relationship between one type of virtual weather data and conversion time data, and may also reflect the same relationship between a plurality of types of virtual weather data and conversion time data, which is not particularly limited in this exemplary embodiment.
In the updating step, the atmospheric fog data is taken as an example, and the atmospheric fog data may further include various data of atmospheric fog concentration, range and color, so that the weather correspondence relationship may be deepened to represent the relationship between one attribute in one virtual weather data and the conversion time data, and thus, the weather correspondence relationship between different attributes in one virtual data and the conversion time data may be different.
Correspondingly, since the virtual light color data includes different types of data such as a background map, skylight data, sunlight data, and the like, the light color corresponding relationship may include a plurality of virtual light color data, that is, one light color corresponding relationship may reflect a relationship between one virtual light color data and the conversion time data, and may also reflect the same relationship between a plurality of virtual light color data and the conversion time data, which is not limited in this exemplary embodiment.
In the updating step, the SkyLight data may further include various data of the illuminance, the color temperature, and the shadow softness of skyilight, so that the light color correspondence relationship may be further developed to represent a relationship between one attribute in one virtual light color data and the conversion time data, and thus, light color correspondence relationships between different attributes in one virtual data and the conversion time data may be different.
In step S220, an attribute rendering process is performed according to the conversion time data, the weather correspondence and the light color correspondence to obtain a virtual weather scene.
After the weather corresponding relationship of the virtual weather data of the virtual scene to be rendered and the light color corresponding relationship of the virtual light color data of the virtual scene to be rendered are obtained, the time data, the weather corresponding relationship and the light color corresponding relationship can be converted to perform attribute rendering processing to obtain the virtual weather scene.
Specifically, the attribute rendering processing may be performed by inputting the current conversion time data into the weather corresponding relationship to obtain a current value of the virtual weather data, and inputting the current conversion time data into the light color corresponding relationship to obtain a current value of the virtual light color data, so as to render the virtual weather scene by using the current value of the virtual weather data and the current value of the virtual light color data.
In the exemplary embodiment, the virtual weather scene is rendered by converting the time data, the weather corresponding relationship and the light color corresponding relationship, the weather effect of the virtual scene can be changed in real time, the intelligent degree and the automation degree are higher, various virtual weather effects can be created, various visual feelings are provided, and the user experience is richer.
It should be noted that, when the weather in the virtual environment is rendered by the method of steps S110-S120, the virtual scene is a scene linked with the current time data, so as to render a virtual weather scene consistent with the real scene.
In addition, compared with the existing game, the weather rendering method has higher richness. The weather rendering of the existing game focuses more on the game experience of the player, so that two types of weather rendering with large differentiation in the night and the daytime are emphasized, further fine-grained and deepened rendering cannot be achieved in the aspect of weather rendering, and the sensory experience of the player in the game is improved.
However, this is not limited to the application of the weather rendering method to weather rendering scenes in a game. When the method is applied to the weather rendering of the game, the richness of the weather rendering can be improved, and the fidelity of a game scene and the game experience of a player can be improved in the aspect of sensory experience.
After the virtual weather scene is rendered, the virtual weather scene can be used for influencing the display of the entity light source so as to achieve the effect of virtual combination.
In an alternative embodiment, fig. 3 shows a flow chart of a method for adjusting physical light source data, and as shown in fig. 3, the method at least includes the following steps: in step S310, target color value data in the scene weather data is acquired, and protocol data conversion is performed on the target color value data to obtain target protocol data.
The data source of the target color value data can be virtual weather data in scene weather data. The target color value data may be a sunlight color value in sunlight data in the virtual weather data. In addition, other color value data may be set in the target color value data according to actual conditions and requirements, which is not particularly limited in the present exemplary embodiment.
Further, the target color value data may be converted into target protocol data using a DMX data processing module.
In an alternative embodiment, the target protocol data includes: DMX512 protocol data.
Among them, DMX512 (Digital Multiple X512) protocol is a data dimming protocol proposed by american stage lighting association (USITT), which provides a protocol standard for communication between a light controller and a luminaire device, and is proposed in 1990, so the protocol is called as usittmx 512 (1990). The proposed protocol provides a good standard for controlling lighting devices using digital signals.
DMX512 is a digital dimming protocol, can carry out digital control to dimmers and other control equipment in places such as stages, theaters, studios and the like by applying the digital dimming protocol, is suitable for a one-point multi-point master-slave control system, adopts a multi-point bus structure in an interconnection form, does not have the problem of information channel blockage, and has simple connection and high reliability.
In addition, other ways to convert the target color value data into other protocol data may also be used, and this exemplary embodiment is not particularly limited in this respect.
It is noted that the target protocol data may be composed of three color channels of red (R), green (G), and blue (B).
In step S320, the entity light source data corresponding to the virtual scene is adjusted by using the target protocol data.
After the converted target protocol data is obtained, the entity light source data of the space where the virtual scene is located can be adjusted by using the target protocol data.
Since the target protocol data is composed of R, G, B three color channels and the illumination of the entity light source data also depends on R, G, B three color channels, the values of the three color channels of the entity light source data R, G, B can be adjusted to be the same as the values of the three color channels of R, G, B of the target protocol data, thereby achieving the adjustment of the entity light source data.
In the exemplary embodiment, the scene weather data is used to adjust the entity light source data corresponding to the virtual scene, so that the light color of the virtual scene is combined with the light color of the real scene, and the visual perception of the audience is more uniform and vivid.
The following describes a method for rendering weather in a virtual environment in the embodiment of the present disclosure in detail with reference to an application scenario.
Fig. 4 is a diagram of a system framework of a weather rendering method in a virtual environment in an application scenario, where as shown in fig. 4, the system framework includes three parts, namely a system time module, a weather system processing module, and a DMX data processing module.
In step S410, the current system time is acquired in real time.
The virtual scene may be any virtual scene such as live game, live virtual broadcast, MV production, and virtual reality performance, which is not limited in this exemplary embodiment.
When the virtual scene is a virtual live broadcast scene, the anchor can be in front of the green screen, and the process is entered by clicking the virtual broadcast of the broadcast background. Further, a UE (universal Engine) virtual background is selected to preview the effect after keying in real time. Then, the angle and other parameters of the camera are adjusted to click the playing control to complete the virtual playing.
The current time data may be time data of a system time block. And, the current time data may be time data in time, minute, second format.
Further, the current time data may be subjected to a format conversion process.
Specifically, the format conversion process may be converting the current time data in the time, minute, and second format into conversion time data in units of hours. In addition, the time data may also be converted into time data in other formats according to actual requirements, which is not particularly limited in this exemplary embodiment.
In step S420, the weather system processing module.
The weather system processing module acquires scene weather data for rendering the virtual scene, and changes the attributes of the weather and the light color of the virtual scene along with the change of the time value in a blueprint writing mode.
Wherein the scene weather data comprises: virtual weather data and virtual light color data.
Further, the virtual weather data and the virtual light color data may also include other data, respectively.
In one aspect, the virtual weather data may include: atmospheric fog data and volumetric cloud data.
Specifically, the atmospheric fog data may include the concentration, range, and color of the atmospheric fog, and may also include other data, which is not particularly limited in the present exemplary embodiment.
The volume cloud data may include data such as density, color, and movement speed of the volume cloud, and may also include other data, which is not particularly limited in this exemplary embodiment.
It should be noted that the virtual weather data may include rain data corresponding to raining and other weather-related data in any real scene, besides the atmospheric fog data and the volume cloud data, and this exemplary embodiment is not particularly limited in this respect.
In another aspect, the virtual light color data may include: background maps, sky light source data, and sunlight data.
The background map may include color, brightness, etc. of the HDRI background map, the sky-light-source data may include illuminance, color temperature, shadow softness, etc. of skyilight, and the sunlight data may include illuminance, color temperature, color value, shadow softness, location, etc. of sunlight. The virtual light color data may also include other data that affects light color, which is the same as that of the real scene, and the background map, the sky light source data, and the sunlight data may also include other data, which is not limited in this exemplary embodiment.
Furthermore, the weather system processing module presets a time and a change curve and an algorithm of the attribute, and along with the lapse of time, the photochromic attribute of the virtual scene changes in a variety of ways, and finally different weather effects are created.
For example, at 6 pm, the sun is west, the color of light turns golden, and the sky shows a scene of sunset at the lower mountain.
And acquiring a weather corresponding relation between the conversion time data and the virtual weather data, and acquiring a photochromic corresponding relation between the conversion time data and the virtual photochromic data.
The weather correspondence may be data reflecting a change in the virtual weather data with the conversion time data. Moreover, the weather corresponding relationship may be in a form of a change curve between the virtual weather data and the conversion time data, or in a form of an algorithm between the virtual weather data and the conversion time data, which is not particularly limited in this exemplary embodiment.
The light color correspondence may be data reflecting a change in the virtual light color data with the conversion time data. The light color corresponding relationship may be in the form of a variation curve between the virtual light color data and the conversion time data, or in the form of an algorithm between the virtual light color data and the conversion time data, which is not limited in this exemplary embodiment.
It should be noted that, since the virtual weather data includes different types of data such as atmospheric fog data and volume cloud data, the weather correspondence relationship may include a plurality of weather correspondence relationships, that is, one weather correspondence relationship may reflect a relationship between one type of virtual weather data and conversion time data, and may also reflect the same relationship between a plurality of types of virtual weather data and conversion time data, which is not particularly limited in this exemplary embodiment.
In the updating step, the atmospheric fog data is taken as an example, and the atmospheric fog data may further include various data of atmospheric fog concentration, range and color, so that the weather correspondence relationship may be deepened to represent the relationship between one attribute in one virtual weather data and the conversion time data, and thus, the weather correspondence relationship between different attributes in one virtual data and the conversion time data may be different.
Correspondingly, since the virtual light color data includes different types of data such as a background map, skylight data, sunlight data, and the like, the light color corresponding relationship may include a plurality of virtual light color data, that is, one light color corresponding relationship may reflect a relationship between one virtual light color data and the conversion time data, and may also reflect the same relationship between a plurality of virtual light color data and the conversion time data, which is not limited in this exemplary embodiment.
In the updating step, the SkyLight data may further include various data of the illuminance, the color temperature, and the shadow softness of skyilight, so that the light color correspondence relationship may be further developed to represent a relationship between one attribute in one virtual light color data and the conversion time data, and thus, light color correspondence relationships between different attributes in one virtual data and the conversion time data may be different.
Further, performing attribute rendering processing according to the conversion time data, the weather corresponding relation and the light color corresponding relation to obtain a virtual weather scene.
After the weather corresponding relationship of the virtual weather data of the virtual scene to be rendered and the light color corresponding relationship of the virtual light color data of the virtual scene to be rendered are obtained, the time data, the weather corresponding relationship and the light color corresponding relationship can be converted to perform attribute rendering processing to obtain the virtual weather scene.
Specifically, the attribute rendering processing may be performed by inputting the current conversion time data into the weather corresponding relationship to obtain a current value of the virtual weather data, and inputting the current conversion time data into the photochromic corresponding relationship to obtain a current value of the virtual photochromic data, so as to render the virtual weather scene by using the current value of the virtual weather data and the current value of the virtual photochromic data.
In step S430, the DMX data processing module.
The DMX data processing module obtains color values of light colors at different times in the virtual scene, i.e., target color value data.
The data source of the target color value data can be virtual weather data in scene weather data. The target color value data may be a sunlight color value in sunlight data in the virtual weather data. In addition, other color value data may be set in the target color value data according to actual conditions and requirements, which is not particularly limited in the present exemplary embodiment.
Further, the target color value data may be converted into target protocol data using a DMX data processing module.
Specifically, the target protocol data may include: DMX512 protocol data.
In addition, other ways to convert the target color value data into other protocol data may also be used, and this exemplary embodiment is not particularly limited in this respect.
It is noted that the target protocol data may be composed of three color channels of red (R), green (G), and blue (B).
In step S440, the studio hall lantern color Wen Zhaodu is changed.
And outputting the target protocol data to a lighting system of the real studio, so that the lighting of the studio is synchronously matched with the weather and the light color of the virtual scene, and the visual unification of the virtual scene is achieved.
Specifically, the entity light source data corresponding to the virtual scene is adjusted by using the target protocol data.
After the converted target protocol data is obtained, the entity light source data of the space where the virtual scene is located can be adjusted by using the target protocol data.
Since the target protocol data is composed of R, G, B three color channels and the illumination of the entity light source data also depends on R, G, B three color channels, the values of the three color channels of the entity light source data R, G, B can be adjusted to be the same as the values of the three color channels of R, G, B of the target protocol data, thereby achieving the adjustment of the entity light source data.
The entity light source data may include color temperature and illuminance, and may also include other data, which is not particularly limited in this exemplary embodiment.
Specifically, the color temperature is a unit of measure indicating that a color component is contained in the light. Theoretically, the black body temperature refers to the color that an absolute black body would appear after warming from absolute zero (-273 ℃). After being heated, the black body gradually turns from black to red, turns yellow and becomes white, and finally emits blue light. When heated to a certain temperature, the light emitted by a black body contains spectral components, referred to as the color temperature at that temperature, measured in "K" (kelvin).
A certain light source emits light having the same spectral composition as that of light emitted from a black body at a certain temperature, and is called a certain K color temperature. If the color of the light emitted by a 100W bulb is the same as the absolute black body at 2527 c, then the color temperature of the light emitted by this bulb is: (2527 + 273) K =2800K.
In a virtual live broadcast scene, when the target protocol data is characterized as warm tone, the entity light source data is also adjusted to be warm tone, so that the occurrence of the situation of color distortion of a main broadcast face is avoided.
Illumination intensity is a physical term that refers to the luminous flux of visible light received per unit area. Abbreviated to illuminance, in Lux or lx. Indicating the amount of illumination and the degree to which the surface area of the object is illuminated. According to the weather rendering method in the virtual environment under the application scene, attribute rendering processing is carried out on scene weather data according to conversion time data to obtain a virtual weather scene in the virtual scene, the weather effect of the virtual scene can be changed in real time, the problem of virtual scene rigid caused by single setting of weather and light color in the existing virtual scene is solved, the flexibility of weather rendering is improved, the intelligentization and automation degree of the weather rendering are improved, various virtual weather effects can be created by using various scene weather data, diversified visual feelings are provided, the user experience is enriched, and the user experience is optimized.
Further, in an exemplary embodiment of the present disclosure, there is also provided a weather rendering apparatus in a virtual environment. Fig. 5 is a schematic structural diagram illustrating a weather rendering apparatus in a virtual environment, and as shown in fig. 5, the weather rendering apparatus 500 in the virtual environment may include: a time conversion module 510 and a weather rendering module 520. Wherein:
a time conversion module 510, configured to obtain current time data in the virtual scene, and perform format conversion processing on the current time data to obtain conversion time data; and a weather rendering module 520 configured to obtain scene weather data for rendering the virtual scene, and perform attribute rendering on the scene weather data according to the conversion time data to obtain a virtual weather scene in the virtual scene.
In an exemplary embodiment of the invention, the method further comprises:
acquiring target color value data in the scene weather data, and performing protocol data conversion on the target color value data to obtain target protocol data;
and adjusting entity light source data corresponding to the virtual scene by using the target protocol data.
In an exemplary embodiment of the present invention, the target protocol data includes: DMX512 protocol data.
In an exemplary embodiment of the present invention, the scene weather data includes: virtual weather data and virtual light color data.
In an exemplary embodiment of the present invention, the performing attribute rendering processing on the scene weather data according to the conversion time data to obtain a virtual weather scene includes:
acquiring a weather corresponding relation between the conversion time data and the virtual weather data, and acquiring a light color corresponding relation between the conversion time data and the virtual light color data;
and performing attribute rendering processing according to the conversion time data, the weather corresponding relation and the light color corresponding relation to obtain a virtual weather scene.
In an exemplary embodiment of the present invention, the virtual weather data includes: atmospheric fog data and volumetric cloud data.
In an exemplary embodiment of the invention, the virtual photochromic data includes: background maps, sky light source data, and sunlight data.
The specific details of the weather rendering apparatus 500 in the virtual environment have been described in detail in the corresponding weather rendering method in the virtual environment, and therefore are not described herein again.
It should be noted that although several modules or units of the weather rendering apparatus 500 in a virtual environment are mentioned in the above detailed description, such division is not mandatory. Indeed, the features and functionality of two or more modules or units described above may be embodied in one module or unit, according to embodiments of the present disclosure. Conversely, the features and functions of one module or unit described above may be further divided into embodiments by a plurality of modules or units.
In addition, in an exemplary embodiment of the present disclosure, an electronic device capable of implementing the above method is also provided.
An electronic device 600 according to such an embodiment of the invention is described below with reference to fig. 6. The electronic device 600 shown in fig. 6 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 6, the electronic device 600 is embodied in the form of a general purpose computing device. The components of the electronic device 600 may include, but are not limited to: the at least one processing unit 610, the at least one memory unit 620, a bus 630 connecting different system components (including the memory unit 620 and the processing unit 610), and a display unit 640.
Wherein the storage unit stores program code that is executable by the processing unit 610 such that the processing unit 610 performs the steps according to various exemplary embodiments of the present invention as described in the above section "exemplary method" of the present specification.
The storage unit 620 may include readable media in the form of volatile memory units, such as a random access memory unit (RAM) 621 and/or a cache memory unit 622, and may further include a read only memory unit (ROM) 623.
The storage unit 620 may also include a program/utility 624 having a set (at least one) of program modules 625, such program modules 625 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
Bus 630 may be one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
The electronic device 600 may also communicate with one or more external devices 800 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 600, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 600 to communicate with one or more other computing devices. Such communication may occur via an input/output (I/O) interface 650. Also, the electronic device 600 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) via the network adapter 660. As shown, the network adapter 640 communicates with the other modules of the electronic device 600 via the bus 630. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, to name a few.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
In an exemplary embodiment of the present disclosure, there is also provided a computer readable storage medium having stored thereon a program product capable of implementing the above-described method of the present specification. In some possible embodiments, aspects of the invention may also be implemented in the form of a program product comprising program code means for causing a terminal device to carry out the steps according to various exemplary embodiments of the invention described in the above-mentioned "exemplary methods" section of the present description, when said program product is run on the terminal device.
Referring to fig. 7, a program product 700 for implementing the above method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited in this regard and, in the present document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A computer readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.

Claims (10)

1. A method of weather rendering in a virtual environment, the method comprising:
acquiring current time data in a virtual scene, and performing format conversion processing on the current time data to obtain conversion time data;
and obtaining scene weather data for rendering the virtual scene, and performing attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
2. The method of weather rendering in a virtual environment of claim 1, further comprising:
acquiring target color value data in the scene weather data, and performing protocol data conversion on the target color value data to obtain target protocol data;
and adjusting entity light source data corresponding to the virtual scene by using the target protocol data.
3. The method of weather rendering in a virtual environment of claim 2, wherein the target protocol data comprises: DMX512 protocol data.
4. The method of weather rendering in a virtual environment of claim 1, wherein the scene weather data comprises: virtual weather data and virtual light color data.
5. The method for rendering weather in a virtual environment according to claim 4, wherein performing attribute rendering on the scene weather data according to the conversion time data to obtain a virtual weather scene includes:
acquiring a weather corresponding relation between the conversion time data and the virtual weather data, and acquiring a light color corresponding relation between the conversion time data and the virtual light color data;
and performing attribute rendering processing according to the conversion time data, the weather corresponding relation and the light color corresponding relation to obtain a virtual weather scene.
6. The method for weather rendering in a virtual environment according to claim 4, wherein the virtual weather data includes: atmospheric fog data and volumetric cloud data.
7. The method for weather rendering in a virtual environment of claim 4, wherein the virtual light color data comprises: background maps, sky light source data, and sunlight data.
8. An apparatus for weather rendering in a virtual environment, comprising:
the time conversion module is configured to acquire current time data in a virtual scene and perform format conversion processing on the current time data to obtain conversion time data;
and the weather rendering module is configured to acquire scene weather data for rendering the virtual scene, and perform attribute rendering processing on the scene weather data according to the conversion time data to obtain the virtual weather scene in the virtual scene.
9. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out a method for weather rendering in a virtual environment according to any one of claims 1 to 7.
10. An electronic device, comprising:
a processor;
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform the method of weather rendering in a virtual environment of any of claims 1-7 via execution of the executable instructions.
CN202111116584.5A 2021-09-23 2021-09-23 Weather rendering method and device in virtual environment, storage medium and electronic equipment Pending CN115861502A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111116584.5A CN115861502A (en) 2021-09-23 2021-09-23 Weather rendering method and device in virtual environment, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111116584.5A CN115861502A (en) 2021-09-23 2021-09-23 Weather rendering method and device in virtual environment, storage medium and electronic equipment

Publications (1)

Publication Number Publication Date
CN115861502A true CN115861502A (en) 2023-03-28

Family

ID=85652320

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111116584.5A Pending CN115861502A (en) 2021-09-23 2021-09-23 Weather rendering method and device in virtual environment, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN115861502A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116832434A (en) * 2023-06-19 2023-10-03 广州怪力视效网络科技有限公司 Method and device for rendering virtual sky in game scene

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116832434A (en) * 2023-06-19 2023-10-03 广州怪力视效网络科技有限公司 Method and device for rendering virtual sky in game scene
CN116832434B (en) * 2023-06-19 2024-04-12 广州怪力视效网络科技有限公司 Method and device for rendering virtual sky in game scene

Similar Documents

Publication Publication Date Title
JP6276794B2 (en) Apparatus and method for defining a color regime
US11147134B2 (en) Illumination content translation
CN109887066B (en) Lighting effect processing method and device, electronic equipment and storage medium
ES2737993T3 (en) Gloss region-based devices and methods for encoding and decoding HDR images
CN105612737B (en) Digital Cinema Initiative Alliance and other content are shown on enhancing dynamic range projector
CN111756956B (en) Virtual light control method and device, medium and equipment in virtual studio
CN111736489B (en) Distributed stage lighting simulation system and method
WO2007122987A1 (en) Data transmitting device, data transmitting method, audiovisual environment control device, audiovisual environment control system and audiovisual environment control method
CN107079189A (en) Lamp is controlled
JP7080400B2 (en) Choosing a method for extracting colors for light effects from video content
CN113286094B (en) Automatic image exposure method, device, equipment and medium
CN106782385A (en) A kind of light-dimming method and its device for wearing display device
CN111408131B (en) Information processing method and device in game, electronic equipment and storage medium
CN115861502A (en) Weather rendering method and device in virtual environment, storage medium and electronic equipment
CN113597061A (en) Method, apparatus and computer readable storage medium for controlling a magic color light strip
CN112543344A (en) Live broadcast control method and device, computer readable medium and electronic equipment
CN105988369B (en) Content-driven intelligent household control method
US20200257831A1 (en) Led lighting simulation system
JP2022500837A (en) Video and audio weight-dependent determination of light effects based on video and audio information
CN109348207A (en) Color temperature adjusting method, image processing method and device, medium and electronic equipment
JP2009081822A (en) Data transmission device and method, and view environment control apparatus, system and method
CN109240499B (en) Virtual camera simulation interaction control system and method, and information data processing terminal
CN116485704A (en) Illumination information processing method and device, electronic equipment and storage medium
KR101373631B1 (en) System for composing images by real time and method thereof
US20080247727A1 (en) System for creating content for video based illumination systems

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination