Image processing method and device, equipment, medium and product

By responding to scene switching events in H5 games, determining the scene type, and adjusting pixel information, the problem of high resource production complexity and large game package size in existing technologies is solved, achieving efficient and realistic scene transitions and improving the user experience.

CN121544734APending Publication Date: 2026-02-17NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511562963.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-29
Publication Date
2026-02-17

AI Technical Summary

Technical Problem

When implementing dynamic scene visual changes, existing H5 games require the separate creation and storage of a complete set of scene texture resources for each scene state. This results in high complexity and cost of resource creation, increased game package size, and negatively impacts user experience.

Method used

By responding to scene switching events, the system determines the type of scene to be switched, obtains the corresponding scene material parameters, and determines the area to be processed from the image to be processed based on the scene type. The system then adjusts the pixel information and generates the target image, achieving efficient and realistic scene transitions.

Benefits of technology

It eliminates the need to create and store complete scene texture resources separately for each scene state, reducing the complexity and cost of resource creation, decreasing the game package size, and improving user experience and scene switching efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121544734A_ABST
    Figure CN121544734A_ABST
Patent Text Reader

Abstract

The invention discloses an image processing method and device, equipment, a medium and a product. The method comprises the steps of determining a to-be-switched scene type corresponding to a scene switching event by responding to the scene switching event for a to-be-processed image; obtaining scene material parameters corresponding to the to-be-switched scene type, and determining a to-be-processed area from the to-be-processed image based on the to-be-switched scene type; and adjusting the pixel information of the pixel points in the to-be-processed area based on the to-be-switched scene type and the scene material parameters to obtain a target image. According to the technical scheme provided by the invention, high-efficiency, low-consumption and real scene dynamic switching with rich visual effects is realized, and the requirements of games on lightweight dynamic scene change are met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer processing technology, and in particular to an image processing method, apparatus, device, medium, and product. Background Technology

[0002] With the rapid development of mobile internet technology, H5 (HyperText Markup Language) games have gained widespread application due to their low barrier to entry and high dissemination capabilities. However, limited by browser operating environments, device performance, and network transmission efficiency, H5 games face severe challenges in terms of resource representation and rendering performance.

[0003] In the construction of H5 game scenes, in order to ensure smooth operation on various terminal devices, the game scene is usually constructed by stitching together 2D UI (2D User Interface) image resources. That is, the scene elements are rendered as 2D texture atlases from a fixed perspective in advance, and then combined and displayed through the UI system.

[0004] However, this static image stitching method, when implementing dynamic scene visual changes (such as day-night cycles, weather changes, or seasonal changes), typically requires creating and storing a complete set of scene texture resources separately for each scene state, and then switching between them at runtime. This not only increases the game package size and user loading time, affecting user experience, but also increases the complexity and cost of resource creation. Summary of the Invention

[0005] This invention provides an image processing method, apparatus, device, medium, and product to achieve efficient, low-power, and visually rich and realistic scene dynamic switching, meeting the needs of games for lightweight dynamic scene changes.

[0006] According to one aspect of the present invention, an image processing method is provided, the method comprising:

[0007] In response to a scene switching event for the image to be processed, determine the scene type to be switched corresponding to the scene switching event;

[0008] Obtain the scene material parameters corresponding to the scene type to be switched, and determine the area to be processed from the image to be processed based on the scene type to be switched;

[0009] The pixel information of the pixels in the area to be processed is adjusted based on the scene type to be switched and the scene material parameters to obtain the target image.

[0010] According to another aspect of the present invention, an image processing apparatus is provided, the apparatus comprising:

[0011] A scene switching response module is used to respond to a scene switching event for an image to be processed and determine the scene type to be switched to corresponding to the scene switching event;

[0012] The region to be processed module is used to obtain scene material parameters corresponding to the scene type to be switched, and to determine the region to be processed from the image to be processed based on the scene type to be switched.

[0013] The target image determination module is used to adjust the pixel information of the pixels in the area to be processed based on the scene type to be switched and the scene material parameters to obtain the target image.

[0014] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:

[0015] At least one processor; and a memory communicatively connected to said at least one processor; wherein,

[0016] The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the image processing method according to any embodiment of the present invention.

[0017] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the image processing method according to any embodiment of the present invention.

[0018] According to another aspect of the present invention, a computer program product is provided, comprising a computer program that, when executed by a processor, implements the image processing method as described in any embodiment of the present invention.

[0019] The technical solution of this invention, in response to a scene switching event for an image to be processed, determines the scene type to be switched corresponding to the scene switching event; obtains the scene material parameters corresponding to the scene type to be switched; and determines the area to be processed from the image to be processed based on the scene type to be switched; and adjusts the pixel information of the pixels in the area to be processed based on the scene type to be switched and the scene material parameters to obtain the target image. This solves the problem in the prior art that a complete set of scene texture resources needs to be created and stored separately for each scene state, resulting in high complexity and cost of resource creation, increased game package size, increased user loading waiting time, and impact on user experience. The solution achieves this by determining the scene type to be switched corresponding to the scene switching event in response to the scene switching event for the image to be processed, and directly obtaining the scene material parameters for the triggered scene type to be switched. This improves the convenience and efficiency of scene switching. Based on the scene type to be switched, the area to be processed is identified from the image to be processed, enabling precise adjustment of pixel information by region, thereby generating a target image that conforms to the visual effect of the new scene and displaying it to the user. This ensures the realism and rationality of the scene effect after switching, achieving efficient and realistic scene transformation. Furthermore, this method eliminates the need to create and store complete scene texture resources separately for each scene state, reducing the complexity and cost of resource creation. It also effectively reduces the overall size of the game package, shortens the user's loading wait time, improves the user experience, and can quickly respond to different scene environment changes according to user needs, thus enhancing scene switching efficiency.

[0020] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description

[0021] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0022] Figure 1 This is a flowchart of an image processing method provided according to an embodiment of the present invention;

[0023] Figure 2 This is a schematic diagram for characterizing an image to be processed according to an embodiment of the present invention;

[0024] Figure 3 This is a flowchart of an image processing method provided according to an embodiment of the present invention;

[0025] Figure 4 This is a schematic diagram of a target image for characterizing snow cover type according to an embodiment of the present invention;

[0026] Figure 5 This is a flowchart of an image processing method provided according to an embodiment of the present invention;

[0027] Figure 6 This is a schematic diagram of a target image for characterizing permafrost types according to an embodiment of the present invention;

[0028] Figure 7 This is a flowchart of an image processing method provided according to an embodiment of the present invention;

[0029] Figure 8 This is a schematic diagram of a target image for characterizing wasteland types according to an embodiment of the present invention;

[0030] Figure 9 This is a schematic diagram of a target image used to characterize a type of famine, according to an embodiment of the present invention.

[0031] Figure 10 This is a flowchart of an image processing method provided according to an embodiment of the present invention;

[0032] Figure 11 This is a schematic diagram of a target image for characterizing winter type according to an embodiment of the present invention;

[0033] Figure 12 This is a schematic diagram of the structure of an image processing apparatus according to an embodiment of the present invention;

[0034] Figure 13 This is a schematic diagram of the structure of an electronic device that implements the image processing method of the present invention. Detailed Implementation

[0035] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0036] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0037] It should be noted that the collection, gathering, updating, analysis, processing, use, transmission, and storage of user personal information involved in the technical solution disclosed herein all comply with relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken to prevent unauthorized access to user personal information data and to maintain user personal information security and network security. It should also be noted that the collection, gathering, updating, analysis, processing, use, transmission, and storage of user personal information involved in the technical solution disclosed herein are all conducted with the user's knowledge and consent, and comply with relevant privacy protection regulations.

[0038] Figure 1 This is a flowchart of an image processing method according to an embodiment of the present invention. This embodiment is applicable to situations where multiple scene or seasonal visual styles are dynamically and efficiently switched in a game scene. The method can be executed by an image processing device, which can be implemented in hardware and / or software and can be configured in a computing device. Figure 1 As shown, the method includes:

[0039] S110. In response to a scene switching event for the image to be processed, determine the scene type to be switched to corresponding to the scene switching event.

[0040] The image to be processed can refer to an image for which a scene change is required. A scene change event can refer to an event triggered by user-initiated action or automatic system activation that requires a scene change for the image to be processed. The scene type to be changed can refer to the category of the target scene to be displayed (i.e., a new scene distinct from the scene of the image to be processed). For example, switching from "daytime mode" to "nighttime mode," from "spring" to "winter," or from "snow" to "wasteland," or from "snow" to "rainy day." Optionally, the scene type to be changed includes, but is not limited to, various scene types such as grassland, wasteland, famine, winter, snow, and frozen ground. In this technical solution, scene types can be identified using text, numbers, icons, strings, or other forms.

[0041] In this embodiment, the image to be processed can be an image captured in real time by a shooting device (such as a camera or video recording device) in the user terminal, an image pre-saved in the user terminal, or an image drawn using an image generation application; alternatively, it can be a dynamically rendered image in a real-time image interaction application (such as a game, virtual reality (VR), augmented reality (AR), simulation system, 3D design tool, or real-time animation engine). For example, the image to be processed can be any type of image, such as a virtual scene, a real-world rendering, a map interface, a 3D model, or a special effects animation. This embodiment of the invention does not limit the image type. The system can detect in real time or periodically whether a scene switching event for the image to be processed is triggered. Optionally, scene switching events include, but are not limited to, clicking a scene switching control, swiping to switch scenes, receiving voice commands for scene switching, changes in device angle (such as device rotation), entering a preset scene switching level, fulfilling a timed task, and receiving an image of the scene to be switched. When a scene switching event is detected, the type of scene to be switched can be analyzed based on the event data of the triggered scene switching event. For example, a scene switching event might occur when a user completes a task within the image to be processed. In this case, the current scene of the image can be switched to a scene suitable for the completed task (such as a meadow full of flowers), and this suitable scene can be used as the scene type to be switched to. Alternatively, a scene switching event might occur when a user enters level A of a game. In this case, the current scene of the image to be processed can be switched to a scene suitable for level A, and this suitable scene can be used as the scene type to be switched to. Or, a scene switching event might occur when a user clicks on control B. In this case, the current scene of the image to be processed can be switched to a scene associated with control B (such as a snow scene), and this associated scene can be used as the scene type to be switched to. The scene switching can then be performed after determining the scene type to be switched to.

[0042] For example, during the operation of a real-time graphical interactive application, users can browse images rendered in real time by the graphics engine. A scene transition event is considered triggered when a virtual object in the current image enters a scene transition area, or when the user selects to switch scene modes via menu, shortcut keys, or voice commands, or when the user enters a new task phase. At this time, the image to be processed is the currently rendered and displayed image. A schematic diagram of the image to be processed can be found in [reference needed]. Figure 2 It should be noted that, Figure 2 This is merely an illustrative example of the image to be processed. The image to be processed can be any display screen in any game scene, and there are no limitations on this.

[0043] S120. Obtain the scene material parameters corresponding to the scene type to be switched, and determine the area to be processed from the image to be processed based on the scene type to be switched.

[0044] Scene material parameters refer to configuration parameters used to construct the visual effects and content attributes of the target scene corresponding to the scene type to be switched. These scene material parameters determine the appearance and content characteristics of the target scene; for example, scene material parameters include, but are not limited to, light intensity, color, transparency, shadow mode, and brightness. No textures are included in the scene material parameters. The area to be processed refers to the specific spatial range in the image to be updated.

[0045] In this embodiment, after determining the scene type to be switched, scene material parameters associated with that scene type can be queried from a preset resource library or configuration file. Simultaneously, based on the scene type to be switched, it can be analyzed which areas of the image to be processed need to apply these scene material parameters. It should be noted that different scene types correspond to different scene effects, and correspondingly, the processing methods for different areas in the image to be processed may differ. That is, the area to be processed in the image can be one or more. For example, the area to be processed can be the entire image, or it can be several areas within the image (such as roads, buildings, sky, or specific regions).

[0046] For example, an identifier (such as the `num` parameter) can be pre-associated with different scene types. Each identifier is connected to the corresponding scene material parameter `switchterrain` for that scene type. For instance, there are six scene types: grassland, wasteland, famine, winter, snow, and frozen ground, each associated with an identifier of 0, 1, 2, 3, 4, and 5, respectively. The scene type to be switched can be determined by judging the identifier. The scene material parameter associated with the identifier of the scene type to be switched is obtained, and the switching between the six scene effects (grassland, wasteland, famine, winter, snow, and frozen ground) is implemented based on the scene material parameter.

[0047] The technical solution provided in this embodiment directly obtains scene material parameters by triggering the scene type to be switched, which can improve the convenience and efficiency of scene switching. At the same time, based on the scene type to be switched, the processing area to be processed is determined from the image to be processed, so that corresponding pixel processing can be performed in different areas. This can ensure the realism and rationality of the scene effect after switching, and achieve efficient and realistic scene transformation.

[0048] S130. Based on the scene type to be switched and the scene material parameters, adjust the pixel information of the pixels in the area to be processed to obtain the target image.

[0049] Pixel information can refer to pixel attributes such as color value (e.g., RGB or HSV), transparency (Alpha), depth value, contrast, hue, brightness, saturation, or color opacity of the corresponding pixel in the area to be processed. The target image can be an image that matches the scene effect corresponding to the scene type to be switched.

[0050] In this embodiment, based on the scene type to be switched, it can be determined which material parameters should be applied to which processing area. Then, the corresponding material parameters are applied to the pixel information of each pixel in the corresponding processing area to obtain the processed target image. The target image can be presented to the user, allowing them to view the image after the scene switch, ensuring that the displayed target image both meets the expected effect of the switched scene type and maintains visual realism. To enhance the user experience, the display process can also use animation effects such as fade-in, sliding, or gradual transitions to make the scene transition more natural and smooth.

[0051] It's important to note that different pixel attributes within the pixel information of the region to be processed can be handled on different interfaces. For example, the alpha (transparency information) of the region to be processed can be input into the opacity interface; the color information can be input into the emissive interface. Different interfaces handle different pixel attributes, improving image processing efficiency. After processing, the target image is obtained. The entire process of creating the target image involves only one scene material parameter, switchterrain. Changing the value of switchterrain allows for switching between different scene effects. This eliminates the need to generate redundant mix maps, maximizing memory savings and reducing costs.

[0052] The technical solution provided in this embodiment determines the scene type to be switched corresponding to the scene switching event in response to the scene switching event; obtains the scene material parameters corresponding to the scene type to be switched; and determines the area to be processed from the image to be processed based on the scene type to be switched; and adjusts the pixel information of the pixels in the area to be processed based on the scene type to be switched and the scene material parameters to obtain the target image. This solves the problem that in the prior art, a complete set of scene texture resources needs to be made and stored separately for each scene state, which results in high complexity and cost of resource production, increased game package size, increased user loading waiting time, and impact on user experience. The solution achieves the ability to determine the scene type to be switched corresponding to the scene switching event in response to the scene switching event of the image to be processed, and directly obtain the scene material parameters of the triggered scene type to be switched. This improves the convenience and efficiency of scene switching. Based on the scene type to be switched, the area to be processed is identified from the image to be processed, so that pixel information can be adjusted accurately by region, thereby generating a target image that conforms to the visual effect of the new scene and displaying it to the user. This ensures the realism and rationality of the scene effect after switching, and achieves efficient and realistic scene transformation. Furthermore, this method eliminates the need to create and store complete scene texture resources separately for each scene state, reducing the complexity and cost of resource creation. It also effectively reduces the overall size of the game package, shortens the user's loading wait time, improves the user experience, and can quickly respond to different scene environment changes according to user needs, thus enhancing scene switching efficiency.

[0053] Figure 3 This is a flowchart of an image processing method according to an embodiment of the present invention. Based on the foregoing embodiments, it is understood that different scene types require different processing areas in the image to be processed, and correspondingly, the methods for determining the target image also differ. The following describes how to determine the processing area and the target image when the scene type to be switched is snow. Specific implementation methods can be found in the technical solution of this embodiment. Technical terms that are the same as or corresponding to those in the above embodiments will not be repeated here.

[0054] like Figure 3 As shown, the method specifically includes the following steps:

[0055] S210. In response to a scene switching event for the image to be processed, determine the scene type to be switched to corresponding to the scene switching event.

[0056] S220. When the scene type to be switched is any one of the following types: snow, frozen soil, wasteland, winter, and famine, the image to be processed is determined as the area to be processed.

[0057] In this embodiment, the snow type can be used to characterize the visual effect of simulating a winter snowy environment (such as snow covering the ground). The permafrost type can be used to characterize the visual effect of simulating frozen ground. For example, the permafrost scene is characterized by a grayish-brown or brownish-yellow surface color, cracked texture, sparse vegetation, and weak reflectivity, presenting an overall cold and barren visual characteristic. The wasteland type can be used to characterize a scene environment simulating sparse vegetation, exposed land, and arid terrain, such as the edge of a desert or degraded land, visually appearing as yellowish-brown, grayish-brown, and with low green content. The winter type can be used to characterize a scene environment simulating the overall natural state of a cold season, including features such as withered grass, fallen leaves, bare branches, and thin snow cover, presenting a bleak and cold color scheme. The famine type can be used to characterize a scene environment simulating resource depletion, barren land, and harsh living conditions, visually appearing as a dark, monotonous, and dilapidated barren visual effect.

[0058] In practice, when the scene type to be switched is determined to be any one of the following types: snow, frozen soil, wasteland, winter, and famine, the image to be processed is marked as the area to be processed so that the pixels in the entire image can be processed to simulate a desolate feeling.

[0059] S230. When the scene type to be switched is snow, the area to be processed is divided into a snow mask area and a first remaining area excluding the snow mask area. The frozen soil mask area is processed based on the first saturation and the first brightness in the scene material parameters, and the first remaining area is processed based on the second saturation in the scene material parameters to obtain the target image.

[0060] The snow mask region refers to the pixel area in the image to be processed that requires the overlay of a snow visual effect. For example, the snow mask region can be a pixel area in the image that conforms to a preset object category (such as rooftops, ground, trees, roads) and / or color characteristics (such as dark gray, brown, green, etc., colors representing easily snow-covered surfaces). The snow mask region can be used to indicate which parts need to have the snow-covered visual effect applied. The first remaining region refers to the area remaining in the processing region after removing the snow mask region. For example, the first remaining region includes objects that are not easily or should not be covered by snow, such as the sky, light sources, or moving figures. The first saturation can be a color saturation adjustment value set for the snow mask region (i.e., the area expected to be covered by snow). The lower the saturation, the closer these areas appear to the color of snow, such as white or light gray. The first brightness can be a brightness adjustment value set for the snow mask region, which can be used to increase the brightness of these areas, making them appear as if illuminated by snow, better matching the snow-covered effect. The second saturation level can be applied to the remaining areas of the first level, used to adjust the color saturation of these background areas to fit the overall atmosphere of the snowy scene. For example, reducing the color saturation of background elements can create a cold and bleak winter feel.

[0061] In this embodiment, when it is detected that the current scene needs to be switched to the snow type, an image recognition model (such as a semantic segmentation network based on deep learning) can be used to identify different objects and their boundaries in the area to be processed, thereby identifying object categories that are prone to snow accumulation, such as building tops, vegetation, and road surfaces, to obtain a snow mask area. Furthermore, for the snow mask area, the saturation of the pixel information in the snow mask area can be reduced based on the first saturation parameter in the scene material parameters corresponding to the snow type, and the brightness of the pixel information in the snow mask area can be increased based on the first brightness parameter. This makes the surface color features of the snow mask area fade and the brightness increased, mimicking the visual effect of snow cover (pure and bright), thus obtaining the processed snow mask area. Meanwhile, for the remaining areas outside the snow-covered mask region, to maintain the consistency and realism of the overall snow scene, the saturation of the pixels in these areas can be reduced based on the second saturation parameter in the scene material parameters. This reduces the vibrancy of the background area, giving it a cold feel that matches the snowy environment, making the entire image harmonious and unified. For example, the sky color can be made darker, thereby enhancing the overall atmosphere of the snow scene. The processed snow-covered mask region and the processed remaining areas are integrated into the target image. At this point, the target image can display a consistent snow-covered scene. Whether it is the areas directly covered by snow (such as vegetation and road surfaces that appear smooth or have accumulated snow) or the surrounding environment, they all have a realistic feel, forming a lifelike snow-covered scene environment.

[0062] For example, the saturation of the snow-masked area (green vegetation and yellow-green road area) is reduced by 100% (i.e., first saturation), and the overall brightness is increased by 1.5 times (i.e., first brightness). The saturation of the remaining areas is reduced by 70% (i.e., second saturation), resulting in the target image. A schematic diagram of the target image corresponding to the snow type can be found in [reference needed]. Figure 4 .

[0063] To achieve accurate and natural snow cover effect positioning and ensure the realism and plausibility of the snow cover effect, the snow cover area can be determined from the area to be processed and the first remaining area other than the snow cover area can be determined from the area to be processed based on the preset first target surface color features and interpolation algorithm during the process of dividing the area to be processed into a snow cover area and a first remaining area other than the snow cover area.

[0064] The first target surface color feature can be used to characterize the color range of objects easily covered or affected by snow under different lighting conditions, and to identify specific ground feature areas in the image to which snow is to be applied. The first target surface color feature can be represented as a range within a color space (such as RGB, HSV). For example, in simulating a snow scene, the surface of the ground or grass needs to meet the specific effect of winter snow. In this case, the first target surface color feature could be the green color range corresponding to vegetation and the yellow-green color range corresponding to roads. For example, the first target surface color feature could be R (red): 100-180; G (green): 80-160; B (blue): 50-120. Another example is that the color ranges corresponding to dark gray (representing tiled roofs), brown (representing soil or tree trunks), and dark green (representing grass or trees) are the first target surface color features. Interpolation algorithms are used to smoothly transition and expand the range between discrete pixel colors, controlling the mixing ratio between different pixel colors. For example, interpolation algorithms can be linear interpolation (lerp), Lagrange interpolation, spline interpolation, nearest neighbor interpolation, bilinear interpolation, etc.

[0065] In this embodiment, when the scene type to be switched is determined to be snow, color recognition algorithms, image analysis algorithms, or pre-trained machine learning models can be used to check pixel color values ​​in the image to be processed to see if they fall into the color features of the first target surface. If so, the pixels that fall into the color features are assigned to the pixel region. Alternatively, the object region corresponding to the color features of the first target surface can be identified from the area to be processed, and the pixels in that object region that fall into the color features of the first target surface are taken as pixels in the pixel region. Furthermore, interpolation algorithms can be used to interpolate the pixels in the identified pixel region between different visual attributes (such as color, material, lighting, etc.) to obtain the snow mask region. The snow mask region guides the system to overlay the snow effect at which locations, ensuring that the snow effect appears accurately in the appropriate location, thereby realistically restoring the visual effect of the snow scene. To achieve a complete scene switch (such as switching from ordinary terrain to winter snow scene or permafrost environment), simply modifying the snow region is not enough. The background environment also needs to be adjusted synchronously, such as the sky turning gray, vegetation turning yellow, roads covered with a thin layer of snow, and lighting becoming softer. Based on this, when switching scenes, the area outside the snow mask area in the area to be processed can be regarded as the first remaining area. Then, corresponding pixel processing can be performed on the snow mask area and the first remaining area respectively. This ensures that not only the snow mask area has snow effects, but the first remaining area is also affected by the overall scene changes (such as reducing color saturation, enhancing shadows, adding fog effects, or partially covering semi-transparent snow layers). This simulates the overall environmental changes, ensures visual consistency and scene realism, avoids "abrupt" visual discontinuities, and enhances the immersion and realism of the target image in the entire snow scene.

[0066] For example, the interpolation algorithm can be a linear interpolation algorithm, in which it is assumed that the pixel change between pixel A in the first target surface color feature of the region to be processed and its surrounding pixels is linear. Interpolation can be performed between pixel A and its surrounding pixel B, and the interpolation t between pixel A and pixel B can be a pixel value between pixel A and pixel B. Alternatively, the interpolation algorithm can be a spline interpolation algorithm, in which it is assumed that the color change between pixel A in the first target surface color feature of the region to be processed and its multiple neighboring pixels follows a smooth curve. Interpolation can be performed in the local region formed by pixel A and its multiple surrounding pixels (such as B, C, D) by constructing a piecewise cubic polynomial function to ensure that not only the color value is continuous at the connection point, but also the change trend (such as gradient) is continuous. The interpolation result t between pixel A and its neighboring pixels is a smooth transition value obtained by solving a set of constraint equations based on the color values ​​and spatial positions of these pixels, thereby generating a more natural and realistic target surface color distribution in complex lighting or texture gradient regions.

[0067] The technical solution provided in this embodiment responds to scene switching events for the image to be processed, identifies the scene type to be switched, and dynamically marks the image to be processed as the area to be processed when specific scene types such as snow, permafrost, wasteland, winter, or famine are detected. Then, it performs fine-grained area division for snow types, distinguishing between the snow mask area where visual effects need to be applied and the first remaining area that maintains background consistency. Based on preset scene material parameters, it applies a first saturation and a first brightness to the snow mask area to adapt to the snow effect, enhancing the realism and brightness levels of the snow cover. At the same time, it applies an independently adjustable second saturation to the first remaining area to maintain overall image harmony, thus achieving a realistic simulation of the snow cover effect of the image.

[0068] Figure 5 This is a flowchart of an image processing method according to an embodiment of the present invention. Based on the foregoing embodiments, the following describes how to determine the area to be processed and the target image when the scene type to be switched is permafrost. Specific implementation methods can be found in the technical solution of this embodiment. Technical terms that are the same as or corresponding to those in the above embodiments will not be repeated here.

[0069] like Figure 5 As shown, the method specifically includes the following steps:

[0070] S310. In response to a scene switching event for the image to be processed, determine the scene type to be switched corresponding to the scene switching event.

[0071] S320. When the scene type to be switched is any one of the following types: snow, frozen soil, wasteland, winter, and famine, the image to be processed is determined as the area to be processed.

[0072] S330. When the scene type to be switched is permafrost, the area to be processed is divided into a permafrost mask area and a second remaining area other than the permafrost mask area. The permafrost mask area is processed based on the third saturation and the second brightness in the scene material parameters, and the second remaining area is processed based on the fourth saturation in the scene material parameters to obtain the first image.

[0073] The permafrost mask region refers to the pixel area in the image to be processed that requires the overlay of permafrost visual effects. For example, the permafrost mask region could be a pixel area representing object categories (such as rooftops, ground, trees, and roads) and / or color characteristics (such as dark gray, brown, and green representing permafrost surfaces) that are susceptible to permafrost conditions. The permafrost mask region can be used to indicate which parts require the application of permafrost visual effects (such as ice crack textures, frost spots, and gray-white hardened tones). The second remaining region refers to the area remaining in the image to be processed after removing the permafrost mask region. For example, if the permafrost mask region is roads and vegetation, the second remaining region could be buildings, water bodies, or the sky. The third saturation can be used to adjust the color saturation of the permafrost mask region (i.e., the identified surface area that may be permafrost). For example, a low to medium saturation level gives the surface a dry, barren tone. The second brightness can be used to adjust the overall brightness of the permafrost mask region. For example, the second brightness can be low to avoid overexposure that resembles snow. The fourth saturation setting can be used to adjust the color saturation of other areas (i.e., non-permafrost identification areas, such as buildings, sky, etc.), reducing the vibrancy of the background colors and creating a cold, desolate overall atmosphere. The first color parameter can refer to a preset hue or filter color (such as tan, yellowish-brown, or bluish-gray), used to cover or overlay the first image to enhance the color tendency of the permafrost environment. The first color opacity adjusts the transparency when the first color parameter is overlaid on the first image. A higher first color opacity value results in stronger color coverage; a medium first color opacity value can incorporate hues while preserving original image details. The first image can be the image generated after adjusting the saturation and brightness differences in different areas.

[0074] In this embodiment, when it is detected that the current scene needs to be switched to a dynamic type, an image recognition model can be used to identify different objects and their boundaries in the area to be processed. Surface areas conforming to permafrost landform characteristics, such as building rooftops, vegetation, and road surfaces, can be identified from the area to be processed to obtain permafrost mask areas. Further, for the permafrost mask areas, the saturation of the pixel information in the permafrost mask areas can be reduced based on the third saturation parameter in the scene material parameters corresponding to the permafrost type, weakening its color vibrancy and making the color of the permafrost mask areas tend towards grayish-yellow or brownish-gray, simulating the visual effect of frozen soil. Based on the second brightness parameter, the brightness of the pixel information in the permafrost mask areas is increased, highlighting the rough and light-absorbing characteristics of the permafrost surface. Simultaneously, for the remaining areas other than the permafrost mask areas, in order to maintain the consistency and realism of the overall permafrost scene, the saturation of the pixel information in the remaining areas can be reduced based on the fourth saturation parameter in the scene material parameters, decreasing its color vibrancy and weakening the expression of warm and lively tones, making the overall environment atmosphere more somber and cold, coordinating with the permafrost theme. After completing the above adjustments, the first image is obtained.

[0075] To achieve accurate and natural permafrost effect positioning and ensure the realism and rationality of the permafrost effect, during the process of dividing the area to be processed into a permafrost mask area and a second remaining area other than the permafrost mask area, the permafrost mask area can be determined from the area to be processed based on the preset second target surface color features and interpolation algorithm, and the second remaining area other than the permafrost mask area can be determined from the area to be processed.

[0076] The second target surface color feature can be used to characterize the color range of a surface susceptible to permafrost under different lighting conditions, and to identify specific ground feature areas in the image where permafrost is to be applied. For example, when simulating a permafrost scene, the surface of the ground or grassland needs to meet the specific effects of permafrost. In this case, the first target surface color feature can be the green color range corresponding to vegetation and the yellow-green color range corresponding to roads.

[0077] In this embodiment, when the scene type to be switched to is determined to be permafrost, color recognition algorithms, image analysis algorithms, or pre-trained machine learning models can be used to check pixel-by-pixel whether the pixel color value in the area to be processed falls into the color feature of the second target surface. If so, the pixel falling into the feature region is included. Alternatively, the target area corresponding to the object of the second target surface color feature can be identified from the area to be processed, and the pixels in the target area that fall into the second target surface color feature are taken as pixels in the feature region. Furthermore, interpolation algorithms can be used to interpolate the pixels in the identified feature region between different visual attributes (such as color, material, lighting, etc.) to obtain the permafrost mask region. The permafrost mask region guides the system to overlay the permafrost effect at which locations, ensuring that the permafrost effect appears accurately in the appropriate position, thereby realistically restoring the visual effect of the permafrost scene. To achieve a complete scene switching (such as switching from ordinary terrain to winter snow scene or permafrost environment), simply modifying the permafrost region is not enough. The background environment also needs to be adjusted accordingly. For example, the bright or neutral sky color can be changed to grayish-white, light blue, or dark gray with heavy clouds to simulate the skylight characteristics of high-latitude regions. Based on this, when switching scenes, the area to be processed, excluding the permafrost mask area, can be designated as the second remaining area. Pixel processing can then be applied to both the permafrost mask area and the first remaining area separately. This ensures that not only the permafrost mask area has permafrost effects, but the first remaining area is also affected by the overall scene changes, simulating overall environmental changes, ensuring visual consistency and scene realism, avoiding abrupt visual breaks, and enhancing the immersiveness and realism of the target image within the overall permafrost scene.

[0078] S340. Based on the first color parameter and the first color opacity in the scene material parameters, process the first image to obtain the target image.

[0079] To enhance the realism and visual consistency of the permafrost scene, the color parameters of each pixel in the first image can be multiplied by a first color parameter, and the intensity of the superimposed colors can be controlled according to the opacity of the first color to obtain the target image. At this time, the target image accurately presents the surface features of the permafrost in the local area, and also achieves a unified color atmosphere at the global level, allowing users to experience a realistic and immersive permafrost environment.

[0080] For example, the saturation of the permafrost mask area is reduced by 100% (i.e., the third saturation), and the overall brightness is increased by 1.5 times (i.e., the second brightness). The saturation of the remaining areas is reduced by 70% (i.e., the fourth saturation), resulting in the first image. Then, the first image is multiplied by a color parameter (i.e., the first color parameter), which can be (0.68, 0.7, 1), with an opacity of 85% (i.e., the first color opacity), to obtain the target image. A schematic diagram of the target image corresponding to the permafrost type can be found in [reference needed]. Figure 6 .

[0081] For example, pixel filtering can be performed in the area to be processed based on the second target surface color features of green vegetation and yellow-green road to obtain the pixel feature regions of green vegetation and yellow-green road, and the pixels associated with the pixel feature regions can be interpolated using the linear interpolation (lerp) algorithm to obtain the permafrost mask region.

[0082] For example, you can create a new object (e.g., a custom) node using a rendering (e.g., a splendor) node. The input is the image to be processed and a custom second target surface color feature. The output is a vegetation area consisting of a yellow-green road and green vegetation, which serves as a permafrost mask area. The second target surface color feature can include four parameters: green area threshold, yellow-green area threshold, green area smoothness, and yellow-green area smoothness. For example, the second target surface color feature could be float4(0, 0, 0.1, 0.05).

[0083] It should be noted that the above method of using the color features of the second target surface to identify the permafrost mask region in the image to be processed is only one possible implementation method in the embodiments of the present invention. Of course, there are other ways to identify the permafrost mask region in the image to be processed, such as using geographic information or elevation data to determine the permafrost mask region. Any method that can be used to identify the permafrost mask region in the image to be processed falls within the protection scope of the embodiments of the present invention.

[0084] It should also be noted that the first target surface color feature corresponding to the snow type and the second target surface color feature corresponding to the permafrost type can be the same or different. The target surface color feature can be obtained based on the analysis of a large amount of real image data, and can cover the area affected by snow (covering vegetation and roads) or permafrost (covering low vegetation).

[0085] The technical solution provided in this embodiment, targeting the specific type of permafrost to be switched scene, intelligently identifies the permafrost mask region that needs adjustment based on the second object color features and an interpolation algorithm, and includes this region along with the remaining parts of the image to be processed into the pixel processing area. When the scene type is switched to permafrost, the permafrost mask region is processed using the third saturation and second brightness, and the remaining areas are adjusted using the fourth saturation. Furthermore, the results are finely corrected using the first color parameter and opacity to ensure a realistic reproduction of the permafrost environment. This method achieves dynamic and high-precision adaptation to different extreme environmental changes without increasing additional storage resources. It not only significantly reduces the development cost and time required for large-scale scene changes in games or other applications, but also enhances the realism and immersion of the user experience, enabling the virtual environment to respond more flexibly to user needs and improving the interactivity and visual expressiveness of the content.

[0086] Figure 7 This is a flowchart of an image processing method according to an embodiment of the present invention. Based on the foregoing embodiments, it describes how to determine the area to be processed and the target image when the scene type to be switched is a wasteland type or a famine type. Specific implementation methods can be found in the technical solution of this embodiment. Technical terms that are the same as or corresponding to those in the above embodiments will not be repeated here.

[0087] like Figure 7 As shown, the method specifically includes the following steps:

[0088] S410, In response to a scene switching event for the image to be processed, determine the scene type to be switched corresponding to the scene switching event.

[0089] S420. When the scene type to be switched is any one of the following types: snow, frozen soil, wasteland, winter, and famine, the image to be processed is determined as the area to be processed.

[0090] It should be noted that when the scene type to be switched is detected to be any of the following: wasteland, winter, or famine, since the common feature of these scenes is a drastic change in the overall environmental atmosphere (such as global ecology or seasonal degradation) rather than a precise replacement of local features (such as specific area identification of snow or permafrost), the entire content of the image to be processed can be marked as the area to be processed. This allows the visual adjustment to cover the entire image and perform consistent rendering of the whole image, ensuring that the final target image is visually coordinated and coherent, and can truly reflect the environmental characteristics and emotional atmosphere that the target scene is meant to convey.

[0091] S430. When the scene type to be switched is wasteland or famine, the pixel information of the pixels in the area to be processed is processed based on the fifth saturation, the second color parameter and the second color opacity in the scene material parameters to obtain the target image.

[0092] The fifth saturation parameter can be used to reduce the color saturation of the area being processed, making the image appear dry and monotonous, weakening the presence of vibrant colors, and highlighting a sense of desolation. The second color parameter can be a preset base hue (such as ochre, grayish-brown, or dark olive), representing the dominant color tendency of a wasteland or famine environment, used to overlay on the image to unify the visual tone. The second color opacity is used to control the intensity or transparency of the second color parameter overlaid on the image.

[0093] In this embodiment, the method for determining the target image is similar when the scene type to be switched is a wasteland or famine type. Specifically, the saturation of the pixel information in the area to be processed can be reduced according to the fifth saturation parameter in the scene material parameters, thereby reducing the color vibrancy of all pixels. For example, green vegetation becomes grayish-green or yellowish-brown, the blue sky tends to be grayish-blue, and the overall color becomes darker, simulating visual degradation caused by long-term drought or resource depletion. The color values ​​of the pixel information in the area to be processed are multiplied by the second color parameter, and the intensity of the superimposed color is controlled according to the opacity of the second color to obtain the target image. This target image visually presents an overall atmosphere of cracked land, sparse vegetation, and a desolate environment, achieving a realistic simulation of wasteland or famine scenes.

[0094] It's important to note that the scene effects for the Wasteland and Famine types are different, and correspondingly, the scene material parameters can also be different. The Famine type scene effect requires a stronger color filter (such as dark gray, dark brown, and cool blue) to enhance this mood. Therefore, the color parameters for the Famine type can be greater than those for the Wasteland type, making the Famine scene closer to a gray-black, desolate state, ensuring the realism and immersion of the scene effect.

[0095] For example, when the scene type to be switched is wasteland, the saturation of the area to be processed can be reduced by 20% (i.e., the fifth saturation is 20%), the pixel color of the area to be processed can be multiplied by the second color parameter, which is (0.88, 0.48, 0.09); the opacity of the pixel color of the area to be processed can be 50% (i.e., the opacity of the second color is 20%), thus obtaining the target image corresponding to the wasteland type. A schematic diagram of the target image corresponding to the wasteland type can be found in [reference needed]. Figure 8When the scene type to be switched to is Don't Starve, the saturation of the area to be processed is reduced by 20% (i.e., the fifth saturation is 20%). The pixel color of the area to be processed is multiplied by the second color parameter, which is (0.73, 0.491, 0.209), where the three values ​​of the second color parameter are the values ​​of R (red), G (green), and B (blue), respectively. The opacity of the pixel color of the area to be processed is 50% (i.e., the opacity of the second color is 20%), resulting in the target image corresponding to the Don't Starve type. A schematic diagram of the target image corresponding to the Don't Starve type can be found in [link to diagram]. Figure 9 .

[0096] The technical solution provided in this embodiment treats the entire image as the processing area when the scene type to be switched is detected to be either wasteland or famine. By reducing the image's color vibrancy based on the fifth saturation parameter, and then combining this with the second color parameter and second color opacity for global tone fusion, the visual characteristics of barren land and depleted vegetation are effectively simulated, enhancing the user's immersion and interactive experience in the virtual environment.

[0097] Figure 10 This is a flowchart of an image processing method according to an embodiment of the present invention. Based on the foregoing embodiments, it describes how to determine the area to be processed and the target image when the scene type to be switched is winter. Specific implementation methods can be found in the technical solution of this embodiment. Technical terms that are the same as or corresponding to those in the above embodiments will not be repeated here.

[0098] like Figure 10 As shown, the method specifically includes the following steps:

[0099] S510, In response to a scene switching event for the image to be processed, determine the scene type to be switched corresponding to the scene switching event.

[0100] S520. When the scene type to be switched is any one of the following types: snow, frozen soil, wasteland, winter, and famine, the image to be processed is determined as the area to be processed.

[0101] S530. When the scene type to be switched is winter, the pixel information of the pixels in the area to be processed is processed based on the sixth saturation and the third brightness in the scene material parameters to obtain the second image; the color information of the pixels in the second image is processed based on the preset exponential function to obtain the target image.

[0102] The sixth saturation parameter can be used to adjust the overall vibrancy of the color in the area being processed. For example, it can make warm colors such as green and red appear darker, reflecting the dormancy and reduced vitality of plants in winter. The third brightness parameter is used to adjust the overall light and dark levels of the area being processed. For example, in winter, sunlight is weak, but snow reflects light strongly, so the third brightness can balance the overall gray tone with local highlights, creating a cool feeling. The third color parameter can be a preset cool color value (such as bluish-gray, light blue, or bluish-purple). The preset exponential function can be an exponential function with a preset value (such as 1.2) as the exponent, used to adjust the non-linear intensity distribution of color superposition, simulating the natural decay law of cool tones with changes in space or brightness in a winter environment. For example, the cool tone is stronger in shadow areas, and the transition in highlight areas is softer. Pixel information includes saturation, brightness, and color information. The specific value of the exponent in the preset exponential function (used to characterize the color decay rate) can be preset according to specific scene requirements.

[0103] In this embodiment, when the scene type to be switched to is winter, the saturation of the pixel information in the area to be processed can be reduced based on the sixth saturation parameter of the scene material parameters corresponding to winter, making the image appear withered yellow or grayish-green, consistent with the characteristics of withered plants in winter. The brightness of the pixel information in the area to be processed is reduced based on the third brightness parameter, making the overall image tend towards mid-gray tones, simulating the common overcast lighting conditions in winter. At the same time, some highlight areas (such as water surfaces and rooftops) can be retained to avoid a dull image. The processed area to be processed is used as the second image. To enhance the unique "chill" atmosphere of winter, the color values ​​corresponding to different pixels can be obtained by using the color information of the pixels in the second image as the base of a preset exponential function. These color values ​​are then used to update the original color information of the pixels in the second image. After the color information of all pixels in the second image is updated, the target image is obtained. This makes the target image not only conform to the characteristics of winter in terms of brightness and saturation, but also present a natural cool-toned color distribution, such as bluish shadows, grayish-white skies, and an overall clear and transparent feel. The target image at this time presents the visual effect of a cold winter.

[0104] For example, the saturation of the area to be processed can be reduced by 65% ​​(i.e., the sixth saturation level), and the pixel brightness of the area to be processed can be multiplied by 0.786 (i.e., the third brightness level) to reduce the brightness and obtain the second image. Then, a preset exponential function with an exponent of 1.2 is used to perform an exponential function operation on the color information of the pixels in the second image to obtain the target image. To further ensure that the target image has no color anomalies, a color constraint function (such as the clamp function) can be used to constrain the color information of the pixels in the target image to the range of 0-1, finally obtaining the target image corresponding to the winter type. A schematic diagram of the target image corresponding to the winter type can be found in [reference needed]. Figure 11 .

[0105] The technical solution of this embodiment, when detecting that the scene type to be switched is winter, treats the entire image to be processed as the processing area. Furthermore, it uses a sixth saturation level and a third brightness level to suppress color and adjust brightness across the entire image, generating a second image with a wintery tone. Then, it uses a preset exponential function to perform non-linear enhancement processing on the color information of the pixels, allowing cool tones to deepen naturally in shadows or low-brightness areas and transition smoothly in highlight areas. This more realistically recreates the cold and desolate atmosphere of winter, enhancing the user's immersion and interactive experience in the virtual environment, and meeting the needs of large-scale visualization, simulation systems, and mobile graphics applications for efficient and lightweight scene rendering.

[0106] Figure 12 This is a schematic diagram of the structure of an image processing apparatus according to an embodiment of the present invention. Figure 12 As shown, the device includes: a scene switching response module 610, a region to be processed determination module 620, and a target image determination module 630.

[0107] The scene switching response module 610 is used to respond to a scene switching event for the image to be processed and determine the scene type to be switched corresponding to the scene switching event; the processing area determination module 620 is used to obtain scene material parameters corresponding to the scene type to be switched and determine the processing area from the image to be processed based on the scene type to be switched; the target image determination module 630 is used to adjust the pixel information of the pixels in the processing area based on the scene type to be switched and the scene material parameters to obtain the target image.

[0108] The technical solution of this embodiment, in response to a scene switching event for an image to be processed, determines the scene type to be switched corresponding to the scene switching event; obtains the scene material parameters corresponding to the scene type to be switched; and determines the area to be processed from the image to be processed based on the scene type to be switched; and adjusts the pixel information of the pixels in the area to be processed based on the scene type to be switched and the scene material parameters to obtain the target image. This solves the problem in the prior art that a complete set of scene texture resources needs to be made and stored separately for each scene state, which results in high complexity and cost of resource production, increased game package size, increased user loading waiting time, and impact on user experience. It realizes that by responding to a scene switching event for an image to be processed, determining the scene type to be switched corresponding to the event, and directly obtaining the scene material parameters of the triggered scene type to be switched, the convenience and efficiency of scene switching can be improved. Based on the scene type to be switched, the area to be processed is identified from the image to be processed, so that pixel information can be adjusted precisely by region, thereby generating a target image that conforms to the visual effect of the new scene and displaying it to the user. This ensures the realism and rationality of the scene effect after switching, and achieves efficient and realistic scene transformation. Furthermore, this method eliminates the need to create and store complete scene texture resources separately for each scene state, reducing the complexity and cost of resource creation. It also effectively reduces the overall size of the game package, shortens the user's loading wait time, improves the user experience, and can quickly respond to different scene environment changes according to user needs, thus enhancing scene switching efficiency.

[0109] Based on the above-mentioned device, optionally, a processing area determination module 620 is used to determine the image to be processed as the processing area when the scene type to be switched is any one of snow, frozen soil, wasteland, winter, and famine.

[0110] Based on the above-described device, optionally, the target image determination module 630 includes:

[0111] The target image determination first unit is used to divide the area to be processed into a snow mask area and a first remaining area other than the snow mask area when the scene type to be switched is a snow type. The snow mask area is processed based on the first saturation and the first brightness in the scene material parameters, and the first remaining area is processed based on the second saturation in the scene material parameters to obtain the target image.

[0112] Based on the above-mentioned device, optionally, a target image determination first unit is used to determine a snow mask region from the region to be processed based on a preset first target surface color feature and an interpolation algorithm, and to determine a first remaining region from the region to be processed other than the snow mask region.

[0113] Based on the above-described device, optionally, the target image determination module 630 further includes:

[0114] The first image determination unit is used to divide the area to be processed into a frozen soil mask area and a second remaining area other than the frozen soil mask area when the scene type to be switched is frozen soil type. The frozen soil mask area is processed based on the third saturation and the second brightness in the scene material parameters, and the second remaining area is processed based on the fourth saturation in the scene material parameters to obtain the first image.

[0115] The second target image determination unit is used to process the first image based on the first color parameter and the first color opacity in the scene material parameters to obtain the target image.

[0116] Based on the above-mentioned device, optionally, a first image determination unit is used to determine a permafrost mask region from the region to be processed based on a preset second target surface color feature and an interpolation algorithm, and to determine a second remaining region from the region to be processed other than the permafrost mask region.

[0117] Based on the above-described device, optionally, the target image determination module 630 further includes:

[0118] The third unit for determining the target image is used to process the pixel information of the pixels in the area to be processed based on the fifth saturation, the second color parameter, and the second color opacity in the scene material parameters when the scene type to be switched is a wasteland type or a famine type, so as to obtain the target image.

[0119] Based on the above-described device, optionally, the target image determination module 630 further includes:

[0120] The second image determination unit is used to process the pixel information of the pixels in the area to be processed based on the sixth saturation and the third brightness in the scene material parameters when the scene type to be switched is winter type, so as to obtain a second image; the pixel information includes color information;

[0121] The fourth unit for target image determination is used to process the color information of pixels in the second image based on a preset exponential function to obtain the target image.

[0122] The image processing apparatus provided in the embodiments of the present invention can execute the image processing method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of executing the method.

[0123] Figure 13This is a schematic diagram of the structure of an electronic device implementing the image processing method of an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.

[0124] like Figure 13 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory 12 or a random access memory 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the read-only memory 12 or a computer program loaded from storage unit 18 into the random access memory 13. The random access memory 13 can also store various programs and data required for the operation of the electronic device 10. The processor 11, read-only memory 12, and random access memory 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0125] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0126] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as image processing methods.

[0127] In some embodiments, the image processing method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or mounted on electronic device 10 via read-only memory 12 and / or communication unit 19. When the computer program is loaded into random access memory 13 and executed by processor 11, one or more steps of the image processing method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the image processing method by any other suitable means (e.g., by means of firmware).

[0128] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0129] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0130] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory, read-only memory, erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0131] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0132] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or middleware components (e.g., application servers), or frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0133] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0134] In particular, according to embodiments of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of the present invention include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication unit 19, or installed from storage unit 18, or installed from read-only memory 12. When the computer program is executed by processor 11, it performs the functions defined in the methods of the embodiments of the present invention.

[0135] This invention also provides a computer program product, including a computer program that, when executed by a processor, implements the image processing method provided in any embodiment of this invention.

[0136] In implementing the computer program product, computer program code for performing the operations of this invention can be written in one or more programming languages ​​or a combination thereof. Programming languages ​​include object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0137] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

[0138] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. An image processing method, characterized by, The method comprises the following steps: In response to a scene switching event for a to-be-processed image, a to-be-switched scene type corresponding to the scene switching event is determined; A scene material parameter corresponding to the to-be-switched scene type is obtained, and a to-be-processed region is determined from the to-be-processed image based on the to-be-switched scene type; Pixel information of a pixel point in the to-be-processed region is adjusted based on the to-be-switched scene type and the scene material parameter, and a target image is obtained.

2. The method of claim 1, wherein, The step of determining the to-be-processed region from the to-be-processed image based on the to-be-switched scene type comprises the following steps: When the to-be-switched scene type is any one of a snow type, a frozen earth type, a wasteland type, a winter type, and a famine type, the to-be-processed image is determined as the to-be-processed region.

3. The method of claim 1, wherein, The step of adjusting the pixel information of the pixel point in the to-be-processed region based on the to-be-switched scene type and the scene material parameter to obtain the target image comprises the following steps: When the to-be-switched scene type is the snow type, the to-be-processed region is divided into a snow mask region and a first remaining region other than the snow mask region, the snow mask region is processed based on a first saturation and a first brightness in the scene material parameter, and the first remaining region is processed based on a second saturation in the scene material parameter, so as to obtain the target image.

4. The method of claim 3, wherein, The step of dividing the to-be-processed region into the snow mask region and the first remaining region other than the snow mask region comprises the following steps: A snow mask region is determined from the to-be-processed region based on a preset first target surface color feature and an interpolation algorithm, and a first remaining region other than the snow mask region is determined from the to-be-processed region.

5. The method of claim 1, wherein, The step of adjusting the pixel information of the pixel point in the to-be-processed region based on the to-be-switched scene type and the scene material parameter to obtain the target image comprises the following steps: When the to-be-switched scene type is the frozen earth type, the to-be-processed region is divided into a frozen earth mask region and a second remaining region other than the frozen earth mask region, the frozen earth mask region is processed based on a third saturation and a second brightness in the scene material parameter, and the second remaining region is processed based on a fourth saturation in the scene material parameter, so as to obtain a first image; The first image is processed based on a first color parameter and a first color opacity in the scene material parameter, so as to obtain the target image.

6. The method of claim 5, wherein, The step of dividing the to-be-processed region into the frozen earth mask region and the second remaining region other than the frozen earth mask region comprises the following steps: The frozen earth mask region is determined from the to-be-processed region based on a preset second target surface color feature and an interpolation algorithm, and the second remaining region other than the frozen earth mask region is determined from the to-be-processed region.

7. The method of claim 1, wherein, The step of adjusting the pixel information of the pixel point in the to-be-processed region based on the to-be-switched scene type and the scene material parameter to obtain the target image comprises the following steps: When the to-be-switched scene type is a wasteland type or a famine type, pixel information of a pixel point in the to-be-processed region is processed based on a fifth saturation, a second color parameter, and a second color opacity in the scene material parameters to obtain a target image.

8. The method of claim 1, wherein, The adjusting the pixel information of the pixel point in the to-be-processed region based on the to-be-switched scene type and the scene material parameters to obtain the target image comprises: When the to-be-switched scene type is a winter type, pixel information of a pixel point in the to-be-processed region is processed based on a sixth saturation and a third brightness in the scene material parameters to obtain a second image; the pixel information comprises color information; Color information of the pixel point in the second image is processed based on a preset exponential function to obtain the target image.

9. An image processing apparatus characterized by comprising: Comprise: A scene switching response module, configured to determine a to-be-switched scene type corresponding to a scene switching event of a to-be-processed image in response to the scene switching event; A to-be-processed region determination module, configured to acquire scene material parameters corresponding to the to-be-switched scene type, and determine a to-be-processed region from the to-be-processed image based on the to-be-switched scene type; A target image determination module, configured to adjust pixel information of a pixel point in the to-be-processed region based on the to-be-switched scene type and the scene material parameters to obtain a target image.

10. An electronic device, comprising: The electronic device comprises: At least one processor; and a memory connected with the at least one processor in communication; wherein The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the image processing method in any one of claims 1-8.

11. A computer program product comprising a computer program, characterized in that, The computer program, when executed by the processor, implements the image processing method in any one of claims 1-8. The computer program, when executed by the processor, implements the image processing method in any one of claims 1-8.