Display Method, Device, Electronic Device, and Storage Medium
By controlling the movement of the transition special effects area in the display screen, adjusting the area size, and using the transition special effects picture to switch scenes, the problem of stiff game scene switching is solved, improving the smoothness and reducing performance consumption.
Patent Information
- Application Number
- CN202211215062.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-30
- Publication Date
- 2025-08-01
- Estimated Expiration
- 2042-09-30
AI Technical Summary
In the prior art, the user interface display scene switching process is relatively stiff when switching game scenes, which affects the smoothness of game screen switching.
By controlling the transition effect area to move in the preset direction in the display screen, adjust the size of the first and second areas, use the transition effect picture to perform scene switching, reduce video editing and adopt video replacement method to achieve smooth scene switching.
Improves the smoothness of the game screen during scene switching and reduces performance consumption due to video editing.
Smart Images

Figure CN115501590B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a display method, device, electronic device, and storage medium. Background Art
[0002] With the development of mobile communication technology, it has become increasingly popular for users to use smart terminal devices such as mobile phones and tablets to play online games. Some online games, for example, card-based turn-based RPG (Role-playing game) games, are deeply loved by users due to their high fluency and exquisite graphics.
[0003] Currently, in the game, when the user operates the game character to complete a specific operation, the next scene screen will be automatically loaded and switched. However, when loading and switching the next scene screen, the scene switching process displayed on the user interface is relatively stiff, thus affecting the smoothness of the game screen scene switching. Summary of the Invention
[0004] The embodiments of the present application provide a display method, device, electronic device, and storage medium that can improve the smoothness of switching game screen scenes.
[0005] The present invention provides a display method, including:
[0006] Displaying a display screen, the display screen includes a first area, and the first area displays a first virtual scene rendering screen;
[0007] Controlling the transition effect area to move from an initial position in a preset direction in the display screen, and displaying a transition effect screen in the transition effect area;
[0008] The second virtual scene rendering image is displayed in the second area, and the second area is the display image that the transition special effect area passes through.
[0009] The present application also provides a display device, including:
[0010] A display unit, configured to display a display screen, the display screen including a first area, the first area displaying a first virtual scene rendering screen;
[0011] A control unit, configured to control the transition effect area to move from an initial position in a preset direction in the display image, wherein a transition effect image is displayed in the transition effect area;
[0012] The display unit is used to display a second virtual scene rendering image in the second area, and the second area is the display image that the transition special effect area passes through.
[0013] An embodiment of the present application further provides an electronic device, including a memory storing multiple instructions; a processor loads instructions from the memory to execute the steps in any one of the display methods provided by the embodiments of the present application.
[0014] An embodiment of the present application further provides a computer-readable storage medium storing multiple instructions, which are suitable for being loaded by a processor to execute the steps in any one of the display methods provided by the embodiments of the present application.
[0015] In the embodiments of the present application, by controlling the movement of the transition special effect area in the display screen, the sizes of the first area and the second area can be adjusted, so that when performing a scene switch, the rendered screen of the first virtual scene to be switched is reduced by using the movement of the transition special effect screen moving from the initial position in a preset direction, and the rendered screen of the second virtual scene to be displayed gradually expands in the display screen until it covers the rendered screen of the first virtual scene.
[0016] In the present application, by controlling the movement of the transition special effect area in the display screen, the smooth movement of the transition special effect area can be controlled, the size changes of the first area and the second area can be adjusted smoothly and evenly, and during the adjustment process, the rendered screen can be directly displayed in the first area and the second area. Furthermore, on the premise of reducing the performance consumption caused by scene switching by means of two video clips and video replacement, the smoothness of the display screen during scene switching is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those skilled in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0018] Figure 1a is a schematic diagram of the scene of the display method provided by the embodiments of the present application;
[0019] Figure 1b is a schematic flowchart of the display method provided by the embodiments of the present application;
[0020] Figure 1c is an effect diagram of the display screen composed of the transition special effect area and the first area provided by the embodiments of the present application;
[0021] Figure 1d is an effect diagram of the display screen composed of the first area, the second area, and the transition special effect area provided by the embodiments of the present application;
[0022] Figure 1eIt is a schematic diagram of the effect of the first texture map characterized by a gradient texture map provided by an embodiment of the present application;
[0023] Figure 1f It is a schematic diagram of the effect of the second texture map characterized by a noise texture map provided by an embodiment of the present application;
[0024] Figure 2a It is a schematic diagram of the process of applying the display method provided by an embodiment of the present application in a terminal scenario;
[0025] Figure 2b It is a schematic diagram of the effect of the switching scene screen and the switched scene screen displayed during the scene switching process provided by an embodiment of the present application;
[0026] Figure 2c It is a schematic diagram of the effect of displaying a gradient feature during the scene switching process provided by an embodiment of the present application;
[0027] Figure 3 It is a schematic diagram of the structure of the display device provided by an embodiment of the present application;
[0028] Figure 4 It is a schematic diagram of the structure of the electronic device provided by an embodiment of the present application. Detailed implementation manners
[0029] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without creative efforts shall fall within the protection scope of the present application.
[0030] The embodiments of the present application provide a display method, a device, an electronic device, and a storage medium.
[0031] Among them, the display device can be specifically integrated in an electronic device, and the electronic device can be a device such as a terminal or a server. Among them, the terminal can be a device such as a mobile phone, a tablet computer, a smart Bluetooth device, a laptop computer, or a personal computer (PC); the server can be a single server or a server cluster composed of multiple servers.
[0032] In some embodiments, the display device can also be integrated in multiple electronic devices. For example, the display device can be integrated in multiple servers, and the display method of the present application can be implemented by multiple servers.
[0033] In some embodiments, the server can also be implemented in the form of a terminal.
[0034] For example, refer toFigure 1a , the electronic device may be a mobile terminal. This embodiment can display a display screen, which includes a first area where a first virtual scene rendering screen is displayed; control the transition special effect area to move from the initial position in a preset direction in the display screen, and a transition special effect screen is displayed in the transition special effect area; display a second virtual scene rendering screen in a second area, and the second area is the display screen passed by the transition special effect area.
[0035] A character control method in one of the embodiments of the present disclosure can run on a terminal device or a server. Among them, the terminal device may be a local terminal device. When the character control method runs on the server, the method can be implemented and executed based on a cloud interaction system, where the cloud interaction system includes a server and client devices.
[0036] In an alternative embodiment, various cloud applications can run under the cloud interaction system, such as cloud games. Taking cloud games as an example, cloud games refer to a game mode based on cloud computing. In the operation mode of cloud games, the running entity of the game program and the presenting entity of the game screen are separated. The storage and running of the character control method are completed on the cloud game server, and the role of the client device is to receive, send, and present the game screen. For example, the client device can be a display device with data transmission function near the user side, such as a behavior terminal, a television, a computer, a handheld computer, etc.; however, the terminal device for character control is the cloud game server in the cloud. When playing a game, the user operates the client device to send an operation instruction to the cloud game server, such as an operation instruction for a touch operation. The cloud game server runs the game according to the operation instruction, encodes and compresses data such as the game screen, returns it to the client device through the network, and finally, the client device decodes and outputs the game screen.
[0037] In an alternative embodiment, the terminal device may be a local terminal device. Taking a game as an example, the local terminal device stores a game program and is used to present the game screen. The local terminal device is used to interact with the user through a graphical user interface, that is, conventionally, the game program is downloaded and installed on the electronic device and run. The way the local terminal device provides the graphical user interface to the user can include various methods. For example, it can be rendered and displayed on the display screen of the terminal, or provided to the user through holographic projection. For example, the local terminal device may include a display screen and a processor. The display screen is used to present the graphical user interface, which includes the game screen, and the processor is used to run the game, generate the graphical user interface, and control the display of the graphical user interface on the display screen.
[0038] A game scene (or virtual scene) is a virtual scene displayed (or provided) when an application runs on a terminal or a server. Optionally, the virtual scene is a simulation environment of the real world, or a semi-simulated and semi-fictional virtual environment, or a purely fictional virtual environment. The virtual scene can be either a two-dimensional virtual scene or a three-dimensional virtual scene. The virtual environment can be the sky, land, ocean, etc. Among them, the land includes environmental elements such as deserts and cities. Among them, the virtual scene is a scene for the complete game logic of virtual objects such as user control. For example, in a sandbox 3D shooting game, the virtual scene is a 3D game world for users to control virtual objects to fight. An exemplary virtual scene can include at least one of the elements of mountains, plains, rivers, lakes, oceans, deserts, sky, plants, buildings, and vehicles.
[0039] A game interface refers to the interface corresponding to an application provided or displayed through a graphical user interface. This interface includes a graphical user interface for user interaction and a game screen, and the game screen is the screen of the game scene.
[0040] In an alternative embodiment, the UI interface may include game controls (such as skill controls, behavior controls, function controls, etc.), indication marks (such as direction indication marks, character indication marks, etc.), information display areas (such as the number of kills, game time, etc.), or game setting controls (such as system settings, stores, gold coins, etc.).
[0041] For example, in some embodiments, the graphical user interface may include a behavior control.
[0042] In an alternative embodiment, the game screen is the display screen corresponding to the terminal device displaying the virtual scene. The game screen may include virtual objects such as game objects, NPC characters, and AI characters that execute game logic in the virtual scene.
[0043] For example, in some embodiments, the content displayed in the graphical user interface at least partially includes the game scene, and among them, the game scene includes at least one game object.
[0044] In some embodiments, the game objects in the game scene include virtual objects controlled by players.
[0045] A game object (or virtual object, game object) refers to a dynamic object that can be controlled in a virtual scene. Optionally, the dynamic object can be a virtual character, virtual animal, anime character, etc. The virtual object is a character controlled by the user through an input device, or an artificial intelligence (AI) set in a virtual environment battle through training, or a non-player character (NPC) set in a virtual scene battle.
[0046] Optionally, the virtual object is a virtual character competing in a virtual scene. Optionally, the number of virtual objects in the virtual scene battle is preset or dynamically determined according to the number of client devices joining the battle. The embodiments of the present application do not limit this.
[0047] In a possible implementation, the user can control the virtual object to perform game behaviors in the virtual scene. The game behaviors can include moving, casting skills, using items, having conversations, etc. For example, controlling the virtual object to run, jump, crawl, etc., and also being able to control the virtual object to use skills and virtual items provided by the application to fight against other virtual objects.
[0048] The virtual camera is an essential component for the game scene screen, used for presenting the game scene screen. At least one virtual camera corresponds to a game scene. According to actual needs, there can be two or more. As a window for game rendering, it captures and presents the picture content of the game world for the user. By setting the parameters of the virtual camera, the user's viewing perspective of the game world can be adjusted, such as the first-person perspective and the third-person perspective.
[0049] In an optional embodiment, the embodiments of the present invention provide a character control method. A graphical user interface is provided through a terminal device, where the terminal device can be the aforementioned local terminal device or the client device in the aforementioned cloud interaction system.
[0050] The following will be described in detail respectively. It should be noted that the sequence numbers of the following embodiments do not limit the preferred order of the embodiments.
[0051] As Figure 1b shown, the specific process of the display method can be as follows:
[0052] 110. Display a display screen. The display screen includes a first area, and the first area displays a first virtual scene rendering screen.
[0053] Among them, the display screen refers to the virtual scene screen displayed on the graphical user interface. The virtual scene screen can be the screen obtained by a virtual camera from the virtual scene. For example, in some embodiments, the virtual scene screen can be the scene screen shown when a virtual object releases a skill in a game scene, or the environmental screen or interaction screen when the virtual object performs a game behavior in the game scene.
[0054] Displaying the display screen means presenting the display screen to the user in the interface corresponding to the application provided or displayed through the graphical user interface.
[0055] The first area can be a partial area on the display screen or the entire area on the display screen.
[0056] The rendered screen refers to the screen obtained after performing image rendering processing on the target area. Image rendering is the process of converting three-dimensional light energy transfer processing into a two-dimensional image. Among them, the image rendering processing can be rendering of an image screen or rendering of a video frame screen.
[0057] The first virtual scene rendered screen refers to the scene screen obtained after performing image rendering processing on the first area. The first virtual scene rendered screen can be the display screen or a part of the display screen. Among them, the first virtual scene rendered screen can be rendered as the size of the first area changes.
[0058] For example, in some embodiments, in a turn-based battle game scene, the display screen can include the game character controlled by the user and the game scene where the game character is located. The first area can be the area where the game scene is located in the display screen, and the first virtual scene rendered screen can be the scene screen or animation screen rendered for the first area.
[0059] 120. Control the transition special effect area to move from the initial position in the display screen in a preset direction, and a transition special effect screen is displayed in the transition special effect area.
[0060] Among them, the transition special effect area can be the area for displaying the transition special effect screen when switching the first virtual scene rendered screen. Among them, the shape of the transition special effect area can be designed arbitrarily. For example, in some embodiments, the transition special effect area can be a regular-shaped bar area, a circular area, or an irregular-shaped area. For example, in some embodiments, the transition special effect area can be an area whose shape and size change dynamically during the switching process, or an area whose shape and size are stable during the switching process.
[0061] Controlling the transition special effect area to move in the display screen can mean moving in the display screen along a preset direction starting from the initial position.
[0062] The initial position can be the position of the transition special effect area before moving. The initial position can be artificially set at any position in the display screen. For example, in some embodiments, the initial position can be outside the first area or inside the first area. There can be multiple initial positions or one initial position.
[0063] The transition special effect screen in the transition special effect area can be directly superimposed on the initial position or can be generated at the initial position in response to a switching signal.
[0064] The preset direction can be the direction of the transition special effect area when moving. The preset direction can be artificially set. The preset direction can be composed of multiple directions or can be one direction. For example, in some embodiments, the transition special effect area can move radially outward with the initial position as the center or can move in a predetermined straight line direction. The preset direction can also be a straight line direction or an arc direction.
[0065] For example, in the embodiments of the present application, as Figure 1c shown in the schematic diagram of the display screen formed by the transition special effect area and the first area. Among them, the lower left corner of the display screen can be the initial position. The black area can represent the transition special effect area, and the transition special effect screen can be displayed within the black area. The black area moves from the lower left corner to the upper right corner. The gray area is the first area, and the first virtual scene rendering screen can be displayed within the first area. As the black area moves, the area size of the first area gradually decreases. Among them, the direction from the lower left to the upper right is the preset direction.
[0066] Among them, in the embodiments of the present application, before controlling the transition special effect area to move in the display screen from the initial position in the preset direction, the method for determining the initial position and the preset direction can include:
[0067] Obtain the first texture map corresponding to the transition special effect area. The first texture map is a gradient texture map;
[0068] Adjust and process the gradient direction and gradient range of the gradient texture on the first texture map to obtain the target first texture map;
[0069] Obtain the gradient starting position and gradient direction on the target first texture map;
[0070] Determine the initial position and the preset direction. The initial position is the gradient starting position, and the preset direction is the gradient direction.
[0071] Among them, as Figure 1e shown in the first texture map, the first texture map can refer to a two-dimensional image, and a certain number of pixel points can be discretely distributed on the image.
[0072] The gradient texture map can distribute the pixel points on the first texture map according to a specific rule. Among them, the specific rule can be a gradient distribution from large to small or from small to large in a direction according to the pixel values of the pixel points, so that the first texture map can generate a texture from dark to bright or from bright to dark.
[0073] The gradient direction can refer to the gradient distribution direction of the gradient texture on the first texture map, that is, it can be the change direction from dark to bright or from bright to dark on the first texture map. For example, in some embodiments, as Figure 1e shown, when the pixel value of the pixel point in the lower left corner of the first texture map is small, the pixel value of the pixel point in the upper right corner is large, and the pixel value gradually increases from the lower left to the upper right of the pixel points in the middle, the gradient direction is Figure 1e the gradient direction from the lower left to the upper right as indicated by the arrow in
[0074] The gradient range can be the size of the change range of the texture on the first texture map along the gradient direction. For example, in some embodiments, the gradient range can be the number of pixel points with smaller pixel values in the lower left corner of the first texture map, and the number of pixel points with larger pixel values in the upper right corner of the first texture map. By setting the number of pixel values of different sizes, it can be shown whether the gradient direction on the first texture map spreads outwards or converges towards a certain position.
[0075] The adjustment process can refer to the process of adjusting the gradient direction and the gradient range. By adjusting the gradient direction and the gradient range, during the switching process of the first virtual scene rendering image, the switching process can be made more controllable, and the switching process of the first virtual scene rendering image can be made more smooth and natural, improving the display effect of the switching. Among them, when performing the adjustment process, the shader algorithm can be used to adjust the gradient texture and the gradient direction of the first texture map.
[0076] The target first texture map is the texture map obtained after adjusting the gradient direction and the gradient range of the texture on the first texture map. After obtaining the target first texture map, the gradient start position and the gradient direction can be determined according to the texture gradient situation on the target first texture map. For example, in some embodiments, after obtaining the target first texture map, the gray values of each pixel point in the target first texture map can be obtained, and according to the size of the gray values, the gradient start position where the gray value is less than the first threshold and the gradient end position where the gray value is greater than the second threshold can be determined, and the gradient direction can be determined according to the gradient start position, the gradient end position and the distribution sequence of the gray values.
[0077] Among them, in the embodiments of the present application, the gradient starting position can be the same as the initial position, and the gradient direction can be the same as the preset direction. Thus, when determining the gradient starting position and the gradient direction, the initial position and the preset direction can be directly obtained. Therefore, the settings of the initial position and the preset direction can be quickly performed, improving the efficiency.
[0078] After determining the initial position and the preset direction, the movement of the transition special effect area in the display screen can be controlled. Among them, the method of controlling the movement of the transition special effect area in the display screen can include: moving the transition special effect screen in the transition special effect area to the first virtual scene rendering screen, or adjusting the transparency of the first virtual scene rendering screen along the preset direction to display the transition special effect screen below the first virtual scene rendering screen.
[0079] The transition special effect area can be an area for displaying the transition special effect screen. The transition special effect area can be an area where any two boundaries or three boundaries in the display screen are connected, or an area that is not connected to the boundaries in the display screen. The shape of the transition special effect area can be set arbitrarily. For example, in some embodiments, as Figure 1d shown in the schematic diagram of the display screen composed of the first area, the second area, and the transition special effect area, where the transition special effect area is a bar-shaped area inclined in the middle of the display screen, and this bar-shaped area is connected to the two side boundaries in the display screen.
[0080] The transition special effect screen can be the screen shown during the process of switching the first virtual scene rendering screen. The transition special effect screen can be rendered within the transition special effect area. Among them, the transition special effect screen can be a scene screen or an animation screen. By means of the transition special effect screen, it can be avoided that the switching process of the first virtual scene rendering screen is too rigid when directly switching the first virtual scene rendering screen. For example, in the embodiments of the present application, as Figure 1d shown in the schematic diagram of the display screen composed of the first area, the second area, and the transition special effect area, the first area is a black area in the upper right of the display screen, the transition special effect area is a bar-shaped area inclined in the middle of the display screen, where the transition special effect screen is displayed within this bar-shaped area, and the second area is a black area in the lower left of the display screen. Before the switching, the first area is displayed in the display screen, and the first virtual scene rendering screen is displayed in the first area. During the switching process, the transition special effect area moves from the lower left corner to the upper right corner of the display screen within the first area. When it moves to the preset time, the second area moves from the lower left corner to the upper right corner of the display screen within the transition special effect area. When the second area moves to the upper right corner of the display screen, the second virtual scene rendering screen in the second area is displayed on the display screen.
[0081] Among them, in some embodiments, the layer where the transition special effect screen is located can be above the first virtual scene rendering screen in the vertical direction. In this way, when moving the transition special effect area, the transition special effect screen can be superimposed above the first virtual scene rendering screen, so as to display the transition special effect screen.
[0082] Among them, in the embodiments of the present application, the method of controlling the transition special effect area to move from the initial position in the display screen in a preset direction, and a transition special effect screen is displayed in the transition special effect area may further include:
[0083] Display a preset special effect at the junction of the transition special effect area and the first area.
[0084] Among them, the preset special effect can be a special effect screen displayed between the first virtual scene rendering screen and the transition special effect screen when switching. Among them, the special effect screen can include flame special effects, shredded paper special effects, water waves special effects, smoke special effects, etc.
[0085] Since the edges of the special effect particles in the above special effect screen are often uneven and constantly changing in shape, a noise texture map can be used to control the shape of the above special effect particles. For example, a noise texture map is used to achieve the dynamic changes of special effects such as flames, water waves, and smoke. Therefore, by modifying the noise texture map, the display effect of the special effect screen can be controlled.
[0086] In some embodiments, the noise texture map can be modified by adjusting the parameters of the noise texture map. The parameters can include noise type, scaling ratio, interpolation, vertex gradient, attenuation degree, etc. Among them, the noise type can include but is not limited to Value noise, Perlin noise, Simplex noise, Worley noise, etc.
[0087] Therefore, in the embodiments of the present application, the method of displaying a preset special effect at the junction of the transition special effect area and the first area may include:
[0088] Obtain a second texture map corresponding to the preset special effect. The second texture map is a noise texture map;
[0089] Adjust the parameters of the second texture map to obtain a target second texture map;
[0090] According to the preset direction and the initial position, add a dissolve special effect to the target second texture map at a preset dissolve speed to obtain a dissolve special effect animation;
[0091] Display the dissolve special effect animation at the junction of the transition special effect area and the first area.
[0092] Among them, as Figure 1f shown in the second texture map, the second texture map can refer to a two-dimensional image, and there are light and dark pixel points distributed on the image.
[0093] A noise texture map can refer to a random number between 0 and 1 for each pixel on an image to represent the brightness (gray value) of the pixel, thereby obtaining an image similar to the effect of black and white snowflakes. Among them, the random numbers of each pixel on the image are discrete. When the gray value is 0, the pixel is displayed as black, indicating that the pixel is completely opaque. When the gray value is 1, the pixel is displayed as white, indicating that the pixel is completely transparent.
[0094] After obtaining the noise texture map, in order to control the display effect of the dissolution special effect and make the switching between the first virtual scene rendering image and the transition special effect image smoother, the parameters of the noise texture map can be adjusted to adjust the display effect of the dissolution special effect. Among them, in some embodiments, when the noise texture map is used, since the map includes different pixels, when dissolving, the dissolution animations of each pixel are different. Therefore, the dissolution special effect of flame burning can be simulated.
[0095] Among them, the parameters include color parameters. In the embodiments of the present application, displaying the dissolution special effect animation includes:
[0096] Determining a color change sequence according to the color parameters, and the color change sequence includes multiple changing color values;
[0097] Performing color value parameter adjustment processing on the target second texture map according to each color value to obtain an animation frame corresponding to the color value;
[0098] Playing the animation frames corresponding to each color value in the order of the color values in the color change sequence.
[0099] Among them, the color parameters include but are not limited to transparency parameters, gray scale parameters, and contrast parameters.
[0100] The color change sequence can represent the change situation of the color values of different pixels on the noise texture map. For example, in some embodiments, when the color parameter is the contrast parameter, the color change sequence can include the black and white contrast of the pixels on the noise texture map.
[0101] The color value parameter adjustment processing can refer to the process of adjusting the color value. For example, in some embodiments, when the color parameter is the contrast parameter, the black and white contrast on the target second texture map can be adjusted to a predetermined maximum value, thereby obtaining the animation frame after dissolving the target second texture map.
[0102] An animation frame can refer to a single image frame, which is the smallest unit in an image animation. The animation frame corresponding to the contrast value can refer to the animation of adjusting the gray value of the pixel to a preset value. Thus, when displaying the dissolution special effect animation, the dissolution special effect can be displayed by playing the animation frames corresponding to each contrast value.
[0103] Among them, in the embodiments of the present application, the method for displaying a dissolution special effect animation may include:
[0104] Add a special effect to the target second texture map to obtain an animation frame, where the resolution of the target second texture map is related to the resolution of the animation frame;
[0105] Display the dissolution special effect animation according to the animation frame.
[0106] Among them, the resolution may refer to how many pixels the display screen can display.
[0107] Among them, when the resolution of the target second texture map is higher, the resolution of the obtained animation frame is also higher, and the display effect of the dissolution special effect animation is better.
[0108] In the embodiments of the present application, by adjusting the color parameters and resolution of the second target texture map, the switching special effect between the transition special effect screen and the first virtual scene rendering screen can be quickly generated and adjusted, so as to ensure that the special effect displayed during the screen switching is more realistic, and at the same time, more quickly help the user improve the efficiency of the special effect setting during the screen switching.
[0109] Among them, as Figure 1d shown, when the transition special effect screen moves in the display screen, at the junction of the transition special effect screen and the first virtual scene rendering screen, a dissolution special effect animation simulating flame combustion can be displayed. Among them, the user can quickly adjust the combustion direction and the realism of the flame combustion special effect by setting the gradient direction of the target first texture map, the color parameters and the resolution of the target second texture map.
[0110] The target second texture map is the second texture map after parameter adjustment. Adding a dissolution special effect to the target second texture map may refer to the process of changing the gray value of the pixel points on the target second texture map from 0 to 1. Since the gray values of each pixel point on the target second texture map are different, and the density of the black pixel points is also different, a dissolution special effect animation of the combustion special effect can be displayed during the dissolution special effect. Among them, the dissolution speed is the speed of the process of changing the gray value of the pixel point from 0 to 1.
[0111] Among them, in the embodiments of the present application, in order to better display the preset special effect at the junction of the transition special effect area and the first area, a first connection edge area is generated at the junction of the transition special effect area and the first area, and the preset special effect is displayed in the first connection edge area. Among them, the method for displaying the preset special effect at the junction of the transition special effect area and the first area further includes:
[0112] Determine the first connection edge at the junction of the transition special effect area and the first area;
[0113] Adjust the saturation of the first connection edge to obtain a first adjusted edge;
[0114] Adjust the edge width of the first adjusted edge to generate a first connected edge area;
[0115] Display a preset special effect within the first connected edge area.
[0116] Among them, the first connected edge is the connection edge line between the transition special effect screen and the first virtual scene rendering screen. In order to obtain the first connected edge more clearly, the saturation of the first connected edge can be adjusted, so that the connection edge between the transition special effect screen and the first virtual scene rendering screen is clearer, thereby obtaining the first adjusted edge.
[0117] In order to better display the preset special effect, the edge width of the first adjusted edge is adjusted to obtain the first connected edge area. Among them, the width of the edge width adjustment can be set artificially according to needs. For example, in some embodiments, when the width of the first adjusted edge obtained after the edge width adjustment is 1, rendering processing can be performed within the first connected edge area. When the width of the first adjusted edge obtained after the edge width adjustment is greater than 1, gradient color rendering processing can be performed within the first connected edge area, thereby enhancing the display effect of the first connected edge area.
[0118] 130. Display a second virtual scene rendering screen in the second area, where the second area is the display screen passed by the transition special effect area.
[0119] Among them, the second area is the display screen passed by the transition special effect area, and the area size of the second area can change as the transition special effect area moves. For example, in some embodiments, the display screen can include an initial position, a transition position, and an end position. Among them, the transition position is the position on the display screen when the transition special effect area moves from the initial position to the end position. When the transition special effect area is at the initial position, the area size of the second area can be zero. When the transition special effect area moves to the transition position, the part of the display screen passed by the transition special effect area is the second area. When the transition special effect area moves to the end position, the entire display screen passed by the transition special effect area is the second area.
[0120] The second virtual scene rendering screen refers to the scene screen obtained by performing image rendering processing on the second area. Among them, the second virtual scene rendering screen can be rendered as the size of the second area changes.
[0121] For example, in some embodiments, in a turn-based battle game scenario, the display screen may include a game character controlled by the user and the game scenario where the game character is located. The first area may be the area where the game scenario is located in the display screen, and the first virtual scene rendering screen may be a scene screen or an animation screen rendered for the first area. When the user controls the game character to perform a skill release operation, the control transition special effect area moves from the initial position at the lower left of the display screen to the upper right direction. Among them, the game scenario passed by the transition special effect area may be the second area, and the second virtual scene rendering screen is obtained by rendering the second area, so as to display the scene screen or animation screen of the game character performing a skill release.
[0122] Among them, in the embodiments of the present application, taking the display screen passed by the transition special effect area as the second area further includes:
[0123] At the junction of the transition special effect area and the second area, a preset special effect is displayed.
[0124] Among them, the preset special effect may be a special effect screen displayed between the transition special effect screen and the second virtual scene rendering screen when switching. Among them, the special effect screen displayed between the transition special effect screen and the second virtual scene rendering screen may be the same as or different from the special effect screen displayed between the first virtual scene rendering screen and the transition special effect screen when switching.
[0125] Among them, in the embodiments of the present application, displaying a preset special effect at the junction of the transition special effect area and the second area includes:
[0126] Obtain a second texture map corresponding to the preset special effect, and the second texture map is a noise texture map;
[0127] Adjust the parameters of the second texture map to obtain a target second texture map;
[0128] According to the preset direction and the initial position, add a dissolution special effect to the target second texture map at a preset dissolution speed to obtain a dissolution special effect animation;
[0129] Display the dissolution special effect animation at the junction of the second area and the transition special effect area.
[0130] Among them, the dissolution special effect animation displayed at the junction of the transition special effect area and the second area may be the same as or slightly different from the dissolution special effect animation displayed at the junction of the first area and the transition special effect area.
[0131] For example, in some embodiments, when switching the rendering screen of the first virtual scene, the special effect screen at the junction of the transition special effect area and the first area when moving to a position in the display screen may be the same as the special effect screen at the junction of the second area and the transition special effect area when moving to this position when switching the transition special effect screen.
[0132] Among them, the parameters include color parameters. In the embodiments of the present application, displaying a dissolution special effect animation includes: determining a color change sequence according to the color parameters, where the color change sequence includes multiple changing color values; performing color value parameter adjustment processing on the target second texture map according to each color value to obtain an animation frame corresponding to the color value; playing each animation frame corresponding to the color value in the order of the color values in the color change sequence.
[0133] The method for displaying a dissolution special effect animation may include: adding a special effect to the target second texture map to obtain an animation frame, where the resolution of the target second texture map is related to the resolution of the animation frame; displaying a dissolution special effect animation according to the animation frame.
[0134] Among them, in the embodiments of the present application, when displaying a preset special effect at the junction of the transition special effect area and the second area, it further includes:
[0135] Determining a second connection edge at the junction of the transition special effect area and the second area;
[0136] Performing saturation adjustment on the second connection edge to obtain a second adjusted edge;
[0137] Performing edge width adjustment on the second adjusted edge to generate a second connection edge area;
[0138] Displaying a preset special effect within the second connection edge area.
[0139] Among them, the preset special effect displayed within the second connection edge area may be the same special effect as the preset special effect displayed within the first connection edge area, or may be a special effect different from the preset special effect displayed within the first connection edge area.
[0140] Among them, in the embodiments of the present application, when the display screen includes a virtual object, the display method further includes:
[0141] Obtaining the virtual object;
[0142] Performing rendering processing on the virtual object to obtain a virtual object screen;
[0143] Overlaying and displaying the virtual object screen on the display screen.
[0144] Among them, the virtual object can be a virtual character competing in a virtual scene or a virtual item displayed in a virtual scene. To enable the virtual object to be displayed in the virtual scene, the virtual object can be rendered to obtain a virtual object image, and the virtual object image can be superimposed and displayed on the display screen.
[0145] For example, in some embodiments, the virtual object can be a virtual character releasing a skill in the display screen. When the virtual character is within the first area, the virtual character is superimposed on the first virtual scene rendering screen; when the virtual character is within the transition special effect area, the virtual character is superimposed on the transition special effect screen; when the virtual character is within the second area, the virtual character is superimposed on the second virtual scene rendering screen.
[0146] Through the method provided by the embodiments of the present application, the movement of the transition special effect area in the display screen can be controlled, so as to adjust the sizes of the first area and the second area, and when switching scenes, use the movement of the transition special effect screen moving from the initial position in a preset direction to shrink the first virtual scene rendering screen to be switched, and make the second virtual scene rendering screen to be displayed gradually expand in the display screen until it covers the first virtual scene rendering screen.
[0147] In the present application, by controlling the movement of the transition special effect area in the display screen, the smooth movement of the transition special effect area can be controlled, the size changes of the first area and the second area can be adjusted smoothly and evenly, and during the adjustment process, the rendering screens can be directly displayed in the first area and the second area, thereby improving the smoothness of the display screen during scene switching on the premise of reducing the performance consumption caused by switching scenes by splicing two videos and replacing them with videos.
[0148] The method described in the above embodiments will be further described in detail below.
[0149] In this embodiment, taking the adjustment of the parameters of the second texture map as an example, the method of the embodiments of the present application will be described in detail.
[0150] As Figure 2a shown, the specific process of a display method applied to the terminal scenario is as follows:
[0151] 201. Determine the virtual object, the switched scene screen, and the scene screen to be switched in the display screen.
[0152] Among them, as Figure 1c shown, the switched scene screen can be the second virtual scene rendering screen and the transition special effect screen in the display screen; the scene screen to be switched can be the transition special effect screen and the first virtual scene rendering screen in the display screen.
[0153] Among them, the display screen may include virtual objects, and the virtual objects are displayed on the display screen.
[0154] In the embodiments of the present application, the virtual object, the switching scene screen, and the switched scene screen may be respectively saved as three textures of "rt_person", "rt1", and "rt2". Among them, the virtual object can exist independently of the scene screen. During the switching process between the switching scene screen and the switched scene screen, the position of the virtual object can remain unchanged.
[0155] Among them, since the position of the virtual object can remain unchanged during the switching process between the switching scene screen and the switched scene screen, the transparency of the virtual object person_alpha = clamp(person.a, 0.0f, 1.0f) can be obtained, so that the transparency of the virtual object is maintained between 0 and 1, preventing the transparency from exceeding the range. Among them, a transparency of 0 represents completely transparent, and a transparency of 1 represents completely opaque, that is, solid.
[0156] And by calculating rt1 = clamp(rt_person * person_alpha + rt1 * (1 - person_alpha), 0.0f, 1.0f), rt2 = clamp(rt_person * person_alpha + rt2 * (1 - person_alpha), 0.0f, 1.0f), the virtual object is respectively placed on the switching scene screen and the switched scene screen. The transparency of the virtual object is person_alpha, and the transparency of the scene is 1 - person_alpha. The scene and the virtual object are blended through the transparency of the virtual object. Thus, rt1 and rt2 with virtual objects are obtained.
[0157] 202. Generate a noise map and a gradient map in the display screen.
[0158] Among them, by generating a noise map and a gradient map in the display screen, the number of pictures to be sampled can be reduced, improving the efficiency.
[0159] Among them, the uneven effect of the burning edge can also be simulated by adjusting the texture density and black - and - white contrast of the pixel points in the noise map, and the direction and trend of the burning in the burning special effect can be simulated by adjusting the gradient angle and gradient range in the gradient map.
[0160] Among them, due to the different graphics environments of OpenGL and DirectX, it is necessary to declare in the primitive processor that uv in DirectX is uv = FLOAT2(input.uv.x, (1 - input.uv.y)); uv in OpenGL is uv = input.uv.
[0161] 203. Set the special effect parameters of the dissolution special effect according to the noise map and the gradient map;
[0162] 204. Obtain the initial dissolution special effect animation of the switching scene screen when switching the switched scene screen according to the switching scene screen and the special effect parameters.
[0163] Among them, the switching scene screen can be set in the display screen, and Dissolve Start Amount and Dissolve End Amount are set as the start value and the end value of the dissolution respectively, where Dissolve Start Amount is less than Dissolve End Amount. Set Dissolve Switch as the dissolution switch. When Dissolve Switch is 0, there is no dissolution at all, and the switched scene screen is displayed; when Dissolve Switch is [value not specified in the original, seems incorrect in the context], the switched scene screen is completely dissolved, and the switching scene screen is displayed.
[0164] The dissolution value dissolve_amount = lerp(Dissolve Start Amount, Dissolve End Amount, 1 - Dissolve Switch)+grad; where grad is the gradient map, and lerp(x, y, a)=x+(y - x)*a. The purpose of this step is to calculate the dissolution value. By dissolve_amount - twist, that is, the dissolution value minus the noise map, the effect as shown can be obtained. Figure 2b As shown, the upper right is the white area, the lower left is the black area, and the middle part is the gray gradient area with noise. The direction from the lower left to the upper right is the gradient direction. Thus, by controlling the values of Dissolve Start Amount, Dissolve End Amount and Dissolve Switch, the display effect can be controlled.
[0165] 205. Obtain the edge at the junction when the switching scene screen and the switched scene screen are switched;
[0166] 206. Adjust the width of the edge at the junction to obtain the edge area;
[0167] 207. Render the edge area with a gradient color to obtain the gradient special effect;
[0168] 208. Superimpose the gradient special effect on the initial dissolution special effect animation to obtain the target dissolution special effect animation.
[0169] It should be noted that there seems to be an unclear or incorrect part in the original text for item where "Dissolve Switch is [value not specified in the original, seems incorrect in the context]" is an issue in the provided Chinese text that needs to be further clarified in the original source for an accurate translation.Among them, the saturation of the four intersection edges (including intersection edge 1, intersection edge 2, intersection edge 3, and intersection edge 4) can be calculated by clip_outline4 = saturate(dissolve_amount + Edge Outline1Width + Edge Outline2 Width + Edge Outline3 Width + Edge Outline4 Width - twist), where Edge Outline1 Width, Edge Outline2 Width, Edge Outline3 Width, and EdgeOutline4 Width are the widths of the four intersection edges respectively. Saturate(x) fixes the value of x between 0 and 1, taking 0 for the part less than 0 and 1 for the part greater than 1.
[0170] Among them, it can also be through clip_outline4 = smoothstep(Dissolve Edge Softness, 1, clip_outline4); where smoothstep(min, max, x) is used to generate a smooth transition value from min to max, and Dissolve Edge Softness is the softness and hardness of the dissolved edge.
[0171] Among them, through the formula: screen_outline4 = lerp(rt2, Edge Outline4 Color, ip_outline4), as Figure 2c shown, replace the black and white parts at the intersection in clip_outline4 with the colors of the black area in the lower left corner of rt2 ( Figure 2c in) and intersection edge 4 (Edge Outline4Color).
[0172] Among them, it can be through the formula: FLOAT clip_outline3 = saturate(dissolve_amount + EdgeOutline1 Width + Edge Outline2Width + Edge Outline3 Width - twist); add the color of intersection edge 3 (Edge Outline3 Color) to intersection edge 4.
[0173] Finally, it can be through the formula: clip_outline2 = saturate(dissolve_amount + EdgeOutline1 Width + Edge Outline2 Width - twist);
[0174] clip_outline2=smoothstep(Dissolve Edge Softness, 1, clip_outline2);
[0175] screen_outline2=lerp(screen_outline, Edge Outline2 Color, clip_outline2);
[0176] clip_outline1=saturate(dissolve_amount+Edge Outline1 Width-twist);
[0177] clip_outline1=smoothstep(Dissolve Edge Softness, 1, clip_outline1);
[0178] screen_outline1=lerp(screen_outline2, Edge Outline1 Color, clip_outline1).
[0179] The four intersection edges can be colored with gradient colors to obtain a gradient color effect.
[0180] After obtaining the gradient color effect, the formula clip_tex=saturate(dissolve_amount-twist) is used;
[0181] clip_tex=smoothstep(Dissolve Edge Softness, 1, clip_tex);
[0182] screen=lerp(screen_outline1, screen1, clip_tex); such as Figure 2c As shown, rt1 (the black area in the upper right corner of the figure) is added to the display screen, so that the flame characteristics displayed are better when rt1 and rt2 are switched.
[0183] 209. When the switching scene screen performs switching processing on the switched scene screen, a target dissolving special effect animation is displayed in the switching scene screen.
[0184] When the display screen includes the first virtual scene rendering screen, the transition special effect screen, and the second virtual scene rendering screen, the formula:
[0185] clip_golden = saturate(dissolve_amount - twist - GoldTex_Width); where GoldTex_Width is the width of the transition effect screen.
[0186] clip_golden = smoothstep(Gold Tex_Gradient Intensity, 1, clip_golden); where GoldTex_GradientIntensity is the gradient intensity of the transition effect screen.
[0187] clip_golden = saturate(clip_golden - 1 + clip_tex);
[0188] screen_golden = lerp(screen, golden_tex, clip_tex - clip_golden), output screen_golden, by controlling the dissolve switch of Dissolve Switch, changing the value of dissolve_amount, and then changing the ratio of the rendering screen of the first virtual scene and the rendering screen of the second virtual scene in the display screen to achieve screen switching.
[0189] As can be seen from the above, the embodiments of the present application can make the process of switching the scene screen and the switched scene screen smoother during switching by adjusting the parameters of the noise map and the gradient map, and at the same time, it is convenient for users to adjust the entire switching process. In addition, it also reduces the performance consumption caused by switching scenes by splicing two videos and replacing them with videos.
[0190] To better implement the above method, the embodiments of the present application also provide a display device, which can be specifically integrated in an electronic device, and the electronic device can be a device such as a terminal or a server. Among them, the terminal can be a device such as a mobile phone, a tablet computer, a smart Bluetooth device, a notebook computer, or a personal computer; the server can be a single server or a server cluster composed of multiple servers.
[0191] For example, in this embodiment, taking the display device specifically integrated in the terminal as an example, the method of the embodiments of the present application will be described in detail.
[0192] For example, as Figure 3 shown, the display device may include:
[0193] A display unit 301 for displaying a display screen, and the display screen includes a first area, and a rendering screen of a first virtual scene is displayed in the first area;
[0194] A control unit 302, configured to control the transition effect area to move from an initial position in a preset direction in a display screen, where a transition effect screen is displayed in the transition effect area;
[0195] A display unit 303, configured to display a second virtual scene rendering screen in a second area, where the second area is the display screen passed by the transition effect area.
[0196] In some embodiments, the display device further includes:
[0197] A virtual object obtaining unit, configured to obtain a virtual object;
[0198] A virtual object screen obtaining unit, configured to perform rendering processing on the virtual object to obtain a virtual object screen;
[0199] An overlay display unit, configured to overlay and display the virtual object screen on the display screen.
[0200] In some embodiments, the control unit 302 may further be configured to:
[0201] Obtain a first texture map corresponding to the transition effect area, where the first texture map is a gradient texture map;
[0202] Adjust the gradient direction and gradient range of the gradient texture on the first texture map to obtain a target first texture map;
[0203] Obtain the gradient start position and gradient direction on the target first texture map;
[0204] Determine the initial position and the preset direction, where the initial position is the gradient start position and the preset direction is the gradient direction.
[0205] In some embodiments, the control unit 302 may further be configured to:
[0206] Display a preset special effect at the junction of the transition effect area and the first area.
[0207] In some embodiments, the control unit 302 may further be configured to:
[0208] Obtain a second texture map corresponding to the preset special effect, where the second texture map is a noise texture map;
[0209] Adjust the parameters of the second texture map to obtain a target second texture map;
[0210] Add a dissolution special effect to the target second texture map at a preset dissolution speed according to the preset direction and the initial position to obtain a dissolution special effect animation;
[0211] Display the dissolution special effect animation at the junction of the transition effect area and the first area.
[0212] In some embodiments, the control unit 302 may further be configured to:
[0213] Determine a first connection edge at the junction of the transition special effect area and the first area;
[0214] Adjust the saturation of the first connection edge to obtain a first adjusted edge;
[0215] Adjust the edge width of the first adjusted edge to generate a first connection edge area;
[0216] Display a preset special effect within the first connection edge area.
[0217] In some embodiments, the display unit 303 may further be configured to:
[0218] Display a preset special effect at the junction of the transition special effect area and the second area.
[0219] In some embodiments, the display unit 303 may further be configured to:
[0220] Obtain a second texture map corresponding to the preset special effect, where the second texture map is a noise texture map;
[0221] Adjust the parameters of the second texture map to obtain a target second texture map;
[0222] Add a dissolution special effect to the target second texture map at a preset dissolution speed according to a preset direction and an initial position to obtain a dissolution special effect animation;
[0223] Display the dissolution special effect animation at the junction of the second area and the transition special effect area.
[0224] In some embodiments, the display unit 303 may further be configured to:
[0225] Determine a second connection edge at the junction of the transition special effect area and the second area;
[0226] Adjust the saturation of the second connection edge to obtain a second adjusted edge;
[0227] Adjust the edge width of the second adjusted edge to generate a second connection edge area;
[0228] Display a preset special effect within the second connection edge area.
[0229] In some embodiments, the parameters include color parameters, and the display device further includes:
[0230] A color change sequence determination unit, configured to determine a color change sequence according to the color parameters, where the color change sequence includes multiple changing color values;
[0231] A color value parameter adjustment processing unit, configured to perform color value parameter adjustment processing on a target second texture map according to each color value, and obtain an animation frame corresponding to the color value;
[0232] An animation frame playing unit, configured to play the animation frame corresponding to each color value in the order of the color values in the color change sequence.
[0233] In some embodiments, the display device further includes:
[0234] A special effect adding unit, configured to add a special effect to the target second texture map to obtain an animation frame, where the resolution of the target second texture map is related to the resolution of the animation frame;
[0235] A display dissolution special effect animation unit, configured to display a dissolution special effect animation according to the animation frame.
[0236] In specific implementation, each of the above units may be implemented as an independent entity, or may be combined arbitrarily and implemented as the same or several entities. For the specific implementation of each of the above units, reference may be made to the foregoing method embodiments, which will not be elaborated herein.
[0237] As can be seen from the above, the display device in this embodiment includes a display unit 301 for displaying a display screen, where the display screen includes a first area, and a first virtual scene rendering screen is displayed in the first area; a control unit 302 for controlling the transition special effect area to move from an initial position in the display screen in a preset direction, and a transition special effect screen is displayed in the transition special effect area; a display unit 303 for displaying a second virtual scene rendering screen in a second area, where the second area is the display screen passed by the transition special effect area.
[0238] Therefore, the embodiment of the present application can improve the smoothness of the display screen during scene switching by controlling the movement of the transition special effect area in the display screen, so as to control the smooth movement of the transition special effect area, smoothly and evenly adjust the size changes of the first area and the second area, and directly display the rendering screen in the first area and the second area during the adjustment process, thereby reducing the performance consumption caused by scene switching through two video clips and replacing them with videos.
[0239] Correspondingly, the embodiment of the present application further provides a computer device, which may be a terminal or a server, and the terminal may be a terminal device such as a smart phone, a tablet computer, a notebook computer, a touch screen, a game console, a personal computer, or a personal digital assistant (Personal Digital Assistant, PDA).
[0240] Such as Figure 4 shown Figure 4A schematic structural diagram of the electronic device provided by the embodiment of the present application. Among them, the electronic device may be a computer device 400, which includes a processor 401 with one or more processing cores, a memory 402 with one or more computer-readable storage media, and a computer program stored on the memory 402 and executable on the processor. Among them, the processor 401 is electrically connected to the memory 402. Those skilled in the art can understand that the computer device structure shown in the figure does not constitute a limitation on the computer device, and it may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0241] The processor 401 is the control center of the computer device 400, connecting various parts of the entire computer device 400 through various interfaces and lines. By running or loading software programs and / or modules stored in the memory 402, and calling data stored in the memory 402, it executes various functions of the computer device 400 and processes data, thereby monitoring the entire computer device 400.
[0242] In the embodiment of the present application, the processor 401 in the computer device 400 will load the instructions corresponding to the processes of one or more application programs into the memory 402 according to the following steps, and the processor 401 will run the application programs stored in the memory 402 to implement various functions:
[0243] Display a display screen, where the display screen includes a first area, and a first virtual scene rendering screen is displayed in the first area;
[0244] Control the transition special effect area to move from the initial position in the display screen in a preset direction. A transition special effect screen is displayed in the transition special effect area;
[0245] Display a second virtual scene rendering screen in the second area, where the second area is the display screen passed by the transition special effect area.
[0246] For the specific implementation of each of the above operations, reference can be made to the previous embodiments, which will not be elaborated here.
[0247] Optionally, as Figure 4 shown, the computer device 400 further includes: a touch display screen 403, a radio frequency circuit 404, an audio circuit 405, an input unit 406, and a power supply 407. Among them, the processor 401 is electrically connected to the touch display screen 403, the radio frequency circuit 404, the audio circuit 405, the input unit 406, and the power supply 407 respectively. Those skilled in the art can understand that Figure 4 the computer device structure shown in
[0248] The touch display screen 403 can be used to display a graphical user interface and receive operation instructions generated by a user's interaction with the graphical user interface. The touch display screen 403 may include a display panel and a touch panel. Among them, the display panel can be used to display information input by the user or information provided to the user, as well as various graphical user interfaces of the computer device. These graphical user interfaces can be composed of graphics, text, icons, videos, and any combination thereof. Optionally, the display panel can be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), etc. The touch panel can be used to collect touch operations of the user on or near it (such as operations of the user using a finger, a stylus, or any suitable object or accessory on or near the touch panel), and generate corresponding operation instructions, and the operation instructions execute the corresponding program. Optionally, the touch panel can include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the touch position of the user and detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 401, and can receive and execute the commands sent by the processor 401. The touch panel can cover the display panel. When the touch panel detects a touch operation on or near it, it transmits it to the processor 401 to determine the type of touch event. Subsequently, the processor 401 provides a corresponding visual output on the display panel according to the type of touch event. In the embodiments of the present application, the touch panel and the display panel can be integrated into the touch display screen 403 to implement input and output functions. However, in some embodiments, the touch panel and the touch panel can be implemented as two independent components to implement input and output functions. That is, the touch display screen 403 can also be used as a part of the input unit 406 to implement the input function.
[0249] In the embodiments of the present application, the processor 401 executes a game application to generate a graphical user interface on the touch display screen 403. The touch display screen 403 can be used to present the graphical user interface and receive operation instructions generated by a user's interaction with the graphical user interface.
[0250] The radio frequency circuit 404 can be used to transmit and receive radio frequency signals to establish wireless communication with a network device or other computer devices through wireless communication, and transmit and receive signals with the network device or other computer devices.
[0251] The audio circuit 405 can be used to provide an audio interface between the user and the computer device through a speaker and a microphone. The audio circuit 405 can convert the received audio data into an electrical signal and transmit it to the speaker, which converts it into a sound signal for output. On the other hand, the microphone converts the collected sound signal into an electrical signal, which is received by the audio circuit 405, converted into audio data, and then the audio data is output to the processor 401 for processing. After that, it is sent through the radio frequency circuit 404 to, for example, another computer device, or the audio data is output to the memory 402 for further processing. The audio circuit 405 may also include an earphone jack to provide communication between the peripheral earphone and the computer device.
[0252] The input unit 406 can be used to receive input digital, character information or user feature information (such as fingerprint, iris, face information, etc.), and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function controls.
[0253] The power supply 407 is used to supply power to each component of the computer device 400. Optionally, the power supply 407 can be logically connected to the processor 401 through a power management system, so as to realize functions such as management of charging, discharging, and power consumption management through the power management system. The power supply 407 may also include any components such as one or more DC or AC power supplies, a recharge system, a power failure detection circuit, a power converter or inverter, and a power status indicator.
[0254] Although Figure 4 not shown in the figure, the computer device 400 may also include a camera, a sensor, a Wi-Fi module, a Bluetooth module, etc., which will not be elaborated here.
[0255] In the above embodiments, the descriptions of each embodiment have their own focuses. For the parts not detailed in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0256] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructions, or by controlling relevant hardware through instructions. The instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.
[0257] For this reason, an embodiment of the present application provides a computer-readable storage medium, in which multiple computer programs are stored. The computer programs can be loaded by a processor to execute the steps in any of the display methods provided by the embodiments of the present application. For example, the computer program can execute the following steps:
[0258] Display a display screen, where the display screen includes a first area, and a first virtual scene rendering screen is displayed in the first area;
[0259] Control the transition effect area to move from the initial position in a preset direction in the display screen, and a transition effect screen is displayed in the transition effect area;
[0260] Display the second virtual scene rendering screen in the second area, where the second area is the display screen passed by the transition effect area.
[0261] For the specific implementation of each of the above operations, reference can be made to the previous embodiments, which will not be elaborated here.
[0262] Among them, the storage medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disc, etc.
[0263] Since the computer program stored in the storage medium can execute the steps in any of the display methods provided in the embodiments of the present application, the beneficial effects achievable by any of the display methods provided in the embodiments of the present application can be achieved. For details, refer to the previous embodiments, which will not be elaborated here.
[0264] The above has introduced in detail a display method, device, electronic device and storage medium provided by the embodiments of the present application. Specific examples are used in this article to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present application.
Claims
1. A display method, characterized in that, The method includes: Displaying a display screen, the display screen including a first area where a first virtual scene rendering screen is displayed; Obtaining a first texture map corresponding to a transition special effect area, the first texture map being a gradient texture map; Adjusting and processing the gradient direction and gradient range of the gradient texture on the first texture map to obtain a target first texture map; Obtaining the gradient start position and gradient direction on the target first texture map; Determining an initial position and a preset direction, the initial position being the gradient start position and the preset direction being the gradient direction; Controlling the transition special effect area to move in the display screen from the initial position in the preset direction, and a transition special effect screen being displayed in the transition special effect area; Displaying a second virtual scene rendering screen in a second area, the second area being the display screen passed by the transition special effect area, so as to switch the first virtual scene rendering screen displayed in the display screen to the second virtual scene rendering screen.
2. The method according to claim 1, wherein It further includes: Obtaining a virtual object; Performing rendering processing on the virtual object to obtain a virtual object screen; Overlaying and displaying the virtual object screen on the display screen.
3. The method according to claim 1, wherein The controlling the transition special effect area to move in the display screen from the initial position in the preset direction, and a transition special effect screen being displayed in the transition special effect area, further includes: Displaying a preset special effect at the junction of the transition special effect area and the first area.
4. The method according to claim 3, characterized in that, The displaying a preset special effect at the junction of the transition special effect area and the first area includes: Obtaining a second texture map corresponding to the preset special effect, the second texture map being a noise texture map; Adjusting the parameters of the second texture map to obtain a target second texture map; Adding a dissolution special effect to the target second texture map at a preset dissolution speed according to the preset direction and the initial position to obtain a dissolution special effect animation; Displaying the dissolution special effect animation at the junction of the transition special effect area and the first area.
5. The method according to claim 3, characterized in that The displaying a preset special effect at the junction of the transition special effect area and the first area includes: Determining a first connection edge at the junction of the transition special effect area and the first area; Adjusting the saturation of the first connection edge to obtain a first adjusted edge; Adjusting the edge width of the first adjusted edge to generate a first connection edge area; Displaying the preset special effect within the first connection edge area.
6. The method according to claim 1, wherein The taking the display screen passed by the transition special effect area as the second area further includes: Displaying a preset special effect at the junction of the transition special effect area and the second area.
7. The method according to claim 6, wherein The displaying a preset special effect at the junction of the transition special effect area and the second area includes: Obtaining a second texture map corresponding to the preset special effect, the second texture map being a noise texture map; Adjusting the parameters of the second texture map to obtain a target second texture map; Adding a dissolution special effect to the target second texture map at a preset dissolution speed according to the preset direction and the initial position to obtain a dissolution special effect animation; Displaying the dissolution special effect animation at the junction of the second area and the transition special effect area.
8. The method according to claim 6, wherein Displaying a preset special effect at the junction of the transition special effect area and the second area includes: Determining a second connection edge at the junction of the transition special effect area and the second area; Adjusting the saturation of the second connection edge to obtain a second adjusted edge; Adjusting the edge width of the second adjusted edge to generate a second connection edge area; Displaying the preset special effect within the second connection edge area.
9. The method according to claim 4 or 7, characterized in that The parameters include color parameters; The displaying of the dissolution special effect animation includes: Determining a color change sequence according to the color parameters, the color change sequence including a plurality of changing color values; Performing color value parameter adjustment processing on the target second texture map according to each color value to obtain an animation frame corresponding to the color value; Playing the animation frames corresponding to each color value in the order of the color values in the color change sequence.
10. The method according to claim 4 or 7, characterized in that The displaying of the dissolution special effect animation includes: Adding a special effect to the target second texture map to obtain an animation frame, the resolution of the target second texture map being related to the resolution of the animation frame; Displaying the dissolution special effect animation according to the animation frame.
11. A display device, characterized in that, Includes: A display unit for displaying a display screen, the display screen including a first area where a first virtual scene rendering screen is displayed; A control unit for obtaining a first texture map corresponding to a transition special effect area, the first texture map being a gradient texture map, adjusting the gradient direction and gradient range of the gradient texture on the first texture map to obtain a target first texture map, obtaining the gradient start position and gradient direction on the target first texture map, determining an initial position and a preset direction, the initial position being the gradient start position, the preset direction being the gradient direction, and controlling the transition special effect area to move in the display screen from the initial position in the preset direction, a transition special effect screen being displayed in the transition special effect area; A display unit for displaying a second virtual scene rendering screen in a second area, the second area being the display screen passed by the transition special effect area, so as to switch the first virtual scene rendering screen displayed in the display screen to the second virtual scene rendering screen.
12. An electronic device, characterized in that, Includes a processor and a memory, the memory storing a plurality of instructions; the processor loads the instructions from the memory to execute the steps in the display method according to any one of claims 1 to 10.
13. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a plurality of instructions, the instructions being suitable for being loaded by a processor to execute the steps in the display method according to any one of claims 1 to 10.
Citation Information
Patent Citations
Augmented reality display method and device, electronic equipment and storage medium
CN111142967A
Multimedia coding techniques for transitional effects
US20070074117A1