Game recording method, device and electronic device
By replacing the target object decorative elements in the actual game screen during the game recording process, and generating game recording videos that are different from those seen by the user but are more interesting, the problem of low enthusiasm for game screen recording in the existing technology is solved, and the problem of improving the User experience.
Patent Information
- Application Number
- CN202111372812.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-18
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2041-11-18
AI Technical Summary
In the prior art, the actual game play screen is exactly the same as the game recording video screen, resulting in a low enthusiasm for recording the game screen.
In response to the game recording instruction, the target object that can be operated in the actual picture frame of the game is determined, and its current decorative element is replaced with the target decorative element, a game recording picture frame is generated, and finally combined into a game recording video.
By replacing the target object decoration elements in the actual game screen, a game recording video that is different from the ones that the user actually sees but is more interesting is generated, which increases the enthusiasm of users to use the game recording function.
Smart Images

Figure CN114191813B_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present application relate to the computer field, and in particular, to a game recording method and device, an electronic device, a computer-readable storage medium, and a computer program product. Background Art
[0002] With the continuous development of the Internet, more and more games have built-in game recording functions. Through the game recording function, users can review the gameplay, which makes it easier for users to review the game and improve their combat skills, and also makes it easier for users to share their in-game performance on social media.
[0003] In the related art, in order to allow users to review the game process after the game is over, the actual display screen frames of the game are usually obtained in real time during the user's game process, and the actual display screen frames are stored in a memory. Thereafter, the actual display screen frames are combined in the order in which they are generated to obtain a game recording video.
[0004] However, in the above method, the game screen that the user sees during the game is exactly the same as the game screen in the recorded video, which cannot arouse the user's interest in watching and sharing, resulting in a low willingness of the user to use the screen recording function. Summary of the invention
[0005] The embodiments of the present application provide a game recording method and device, an electronic device, a computer-readable storage medium, and a computer program product to solve the problem in the related art that the actual game play screen is exactly the same as the game recorded video screen, and the user's enthusiasm for game screen recording is low.
[0006] In a first aspect, an embodiment of the present application provides a game recording method, the method comprising:
[0007] In the process of responding to the game recording instruction and recording the game video, determining an operable target object in the actual game screen frame obtained by recording;
[0008] Replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element;
[0009] The game recording screen frames are combined to obtain a game recording video.
[0010] In an optional implementation manner, the step of replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame includes:
[0011] Acquire a first rendering parameter for rendering an actual game screen frame, wherein the first rendering parameter includes a current decoration element of the target object;
[0012] Replacing the current decoration element in the first rendering parameter with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame;
[0013] The game recording screen frame is rendered according to the second rendering parameter.
[0014] In an optional implementation, the method further includes:
[0015] Rendering according to the first rendering parameters to obtain the actual game screen frame;
[0016] According to the order in which the first rendering parameters are obtained, the actual game picture frames are displayed on the screen in real time.
[0017] In an optional implementation, the step of replacing the current decorative element in the first rendering parameter with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame includes:
[0018] Obtaining a game recording frame rate value, and calculating a frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent a time interval between two adjacent frames in the game recording video;
[0019] The current decoration element in the first rendering parameter having the frame interval duration between generation times is replaced with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame.
[0020] In an optional implementation, rendering the game recording screen frame according to the second rendering parameter includes:
[0021] Get the system's hardware configuration information and the game's actual running screen settings;
[0022] Determine the recording resolution according to the hardware configuration information and the setting information;
[0023] The game recording screen frames that meet the recording resolution are rendered according to the second rendering parameters.
[0024] In an optional implementation, the method further includes:
[0025] Get the account information and decoration element information of the game account;
[0026] A target decorative element of the target object is determined according to the account information and the decorative element information.
[0027] In an optional implementation manner, determining the target decorative element of the target object according to the account information and the decorative element information includes:
[0028] Determine other accounts whose similarity to the account information exceeds a preset similarity;
[0029] Determining, according to the decoration element information of the other accounts, a holding rate of each virtual decoration element, wherein the holding rate is used to represent the probability that the other accounts hold the virtual decoration element;
[0030] The virtual decorative element with a holding rate higher than a preset probability is used as the target decorative element.
[0031] In an optional implementation, after combining the game recording screen frames to obtain the game recording video, the method further includes:
[0032] When the game account ends the current game process, the game recording video and the target decoration element are displayed on the screen.
[0033] In a second aspect, an embodiment of the present application provides a game recording device, the device comprising:
[0034] A determination module is configured to determine an operable target object in an actual game screen frame obtained by recording in response to a game recording instruction and in the process of recording a game video;
[0035] a replacement module, configured to replace the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element;
[0036] The video module is configured to combine the game recording screen frames to obtain the game recording video.
[0037] In an optional implementation, the replacement module includes:
[0038] An instruction acquisition submodule is configured to acquire a first rendering parameter for rendering an actual game screen frame, wherein the first rendering parameter includes a current decorative element of the target object;
[0039] A replacement submodule is configured to replace the current decoration element in the first rendering parameter with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame;
[0040] The rendering submodule is configured to render the game recording screen frame according to the second rendering parameters.
[0041] In an optional embodiment, the device further comprises:
[0042] A rendering module, configured to render the actual game screen frame according to the first rendering parameters;
[0043] The display module is configured to display the actual game screen frames on the screen in real time according to the acquisition order of the first rendering parameters.
[0044] In an optional implementation, the replacement submodule includes:
[0045] A frame interval submodule is configured to obtain a game recording frame rate value, and calculate a frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent a time interval between two adjacent frames in the game recording video;
[0046] The instruction determination submodule is configured to replace the current decorative element in the first rendering parameter with the frame interval duration between generation times with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame.
[0047] In an optional implementation, the rendering submodule includes:
[0048] The information determination submodule is configured to obtain the hardware configuration information of the system and the setting information of the actual running screen of the game;
[0049] A resolution submodule, configured to determine a recording resolution according to the hardware configuration information and the setting information;
[0050] The recording screen frame submodule is configured to render a game recording screen frame that meets the recording resolution according to the second rendering parameters.
[0051] In an optional embodiment, the device further comprises:
[0052] An information acquisition module, configured to acquire account information and decoration element information of a game account;
[0053] The target element module is configured to determine the target decorative element of the target object according to the account information and the decorative element information.
[0054] In an optional implementation, the determining submodule includes:
[0055] Other account submodule, configured to determine other accounts whose similarity with the account information exceeds a preset similarity;
[0056] a holding rate submodule, configured to determine a holding rate of each virtual decorative element according to the decorative element information of the other accounts, wherein the holding rate is used to represent a probability that the other accounts hold the virtual decorative element;
[0057] The target element submodule is configured to use the virtual decorative element whose holding rate is higher than a preset probability as the target decorative element.
[0058] In an optional embodiment, the device further comprises:
[0059] The display submodule is configured to display the game recording video and the target decoration element on the screen when the game account ends the current game process.
[0060] In a third aspect, an embodiment of the present application further provides an electronic device, comprising a memory for storing instructions executable by the processor; wherein the processor is configured to execute the instructions to implement the game recording method.
[0061] In a fourth aspect, an embodiment of the present application further provides a computer-readable storage medium, which, when instructions in the computer-readable storage medium are executed by a processor of an electronic device, enables the electronic device to execute the game recording method.
[0062] In a fifth aspect, an embodiment of the present application further provides a computer program product, including a computer program, which implements the game recording method when executed by a processor.
[0063] In an embodiment of the present application, in the process of responding to a game recording instruction and recording a game video, the target object that can be operated in the actual game screen frame obtained by recording can be determined; the current decorative element of the target object in the actual game screen frame can be replaced with the target decorative element to obtain a game recording screen frame, and the current decorative element is different from the target decorative element; the game recording screen frames are combined to obtain a game recording video. Therefore, by replacing the current decorative element of the target object in the actual game screen, the target object in the recorded game recording screen can use a target decorative element different from the current decorative element seen by the user, and then a game recording video different from the actual game screen seen by the user can be obtained according to the game recording video frame, which increases the fun of game recording, and also facilitates users to experience a variety of decorative elements, and enhances the user's enthusiasm for using the game recording function.
[0064] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present application. Also, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:
[0066] Figure 1 is a flowchart of a game recording method provided by an embodiment of the present application;
[0067] Figure 2 This is a schematic diagram of an actual game screen frame provided by an embodiment of the present application;
[0068] Figure 3 This is a schematic diagram of a game recording screen frame provided by an embodiment of the present application;
[0069] Figure 4 is a flowchart of another game recording method provided by an embodiment of the present application;
[0070] Figure 5 It is a structural diagram of a game recording model provided in an embodiment of the present application;
[0071] Figure 6 is a logic block diagram of an electronic device according to an embodiment of the present application;
[0072] Figure 7 It is a logic block diagram of an electronic device according to another embodiment of the present application. DETAILED DESCRIPTION
[0073] The exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present application are shown in the accompanying drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present application and to fully convey the scope of the present application to those skilled in the art.
[0074] Games generally have built-in game recording functions, through which users can record game screens. The game recording function can be started manually by the user or automatically by the game. For example, users can manually turn on the game recording function during the game to record the game screen after the game recording function is turned on. Users can also set the time node for the game recording function to automatically start, such as when each game starts or when exciting operations occur in the game.
[0075] Unlike the screen recording function of the terminal, the game recording function can only record the game screen, and will not record other content that covers the game screen. For example, the user receives a message reminder during the game and a message pop-up window is displayed on the terminal screen. The ordinary screen recording function will record everything displayed on the screen, including the message pop-up window, while the game recording function can only record the game screen, and can even continue to record the game screen after the user switches the game to the background running mode.
[0076] Figure 1 is a flowchart of a game recording method provided by an embodiment of the present application, such as Figure 1 As shown, the method includes:
[0077] Step 101: In the process of responding to a game recording instruction and recording a game video, determine an operable target object in the actual game screen frame obtained by recording.
[0078] The game recording instruction may be manually sent by the user through an input device, for example, the user clicks a game recording button on the device screen during the game to send the game recording instruction. The game recording instruction may also be sent by the game client itself, for example, the game client automatically sends the game recording instruction after the user enters the game to record each play process.
[0079] After receiving the game recording instruction, the game client first determines the target object whose decorative elements need to be replaced, where the target object can refer to any element in the game whose appearance can be manipulated by the user to change the decorative style. For example, the characters in the game, the weapons used by the characters, and any other game props and scenes that can change the display appearance.
[0080] The target object can be specified by the user, for example, after responding to the game recording instruction, a list of objects is displayed to the user through a pop-up window or other means, and the user selects one or more target objects from the list of objects. The target object can also be pre-specified by the game operator and pushed to the specified game client. For example, if the game operator launches a new skin for a character, the object corresponding to the new skin can be pushed as the target object to all game clients, so that all game clients determine the object corresponding to the new skin as the target object when recording the video.
[0081] Step 102: Replace the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element.
[0082] When the game is running on the terminal, the actual game screen will be rendered in units of one frame, and each rendered frame of the actual game screen will be continuously displayed to the user on the terminal screen so that the user can see a coherent dynamic game screen.
[0083] In the embodiment of the present application, after the target object is determined, it is also necessary to determine the target decorative element of the target object to be replaced, wherein the target decorative element of the target object is a decorative element different from the current decorative element of the target object.
[0084] For example, when the target object is a character, the target decorative element can be the character's skin, appearance model, skill special effects, etc. When the target object is the character's weapon, the target decorative element can be the weapon's skin, appearance model, attack special effects, etc.
[0085] Specifically, the target decorative element may be manually specified by the user. For example, after the target object is determined, a list of decorative elements of the target object may be displayed to the user for the user to select the target decorative element. The target decorative element may also be specified by the game operator. For example, the game operator recently launched a new skin for a character. The new skin may be pushed to all game clients as the target decorative element, so that all game clients display the new skin as the decorative element of the corresponding target object in the game recording video when recording the video.
[0086] Replacing the current decorative elements of the target object in the actual game screen frame can be performed when the actual game screen frame is generated. Specifically, when rendering the actual game screen frame, the current decorative elements of the target object can be replaced with the target decorative elements in the screen rendering parameters used to render the actual game screen frame, and the replaced screen rendering parameters can be used to directly render the game recording screen frame after the decorative elements are replaced.
[0087] After the rendering of the actual game screen frame is completed, the target object in the actual game screen frame can be identified, and the position of the current decorative element of the target object in the actual game screen frame can be determined. Then, the target decorative element corresponding to the target object can be used to overwrite or replace the current decorative element in the actual game screen frame to obtain the game recording screen frame.
[0088] Reference Figure 2 and Figure 3 , Figure 2 is a schematic diagram of an actual game screen frame provided by an embodiment of the present application, Figure 3 Schematic diagram of a game recording screen frame provided by an embodiment of the present application. Figure 2 and Figure 3As shown, the hat 1 of the game character in the actual game screen frame is the target object. In the actual game screen frame, the current decorative element of the target object hat 1 is pure white. Figure 2 After replacing the hat 1 in the actual game screen frame shown, we get Figure 3 The game recording screen frame shown, in which the decorative element of the target object's hat 1 is replaced by a black and white target decorative element.
[0089] In addition, since the actual game screen frames must be input to the user during the game operation, if the game recorded screen frames that are different from the actual game screen frames are obtained synchronously, the load of the terminal device may increase, resulting in a decrease in the game running frame rate or a freeze. Therefore, in order to avoid affecting the game operation efficiency, the screen rendering parameters of the actual game screen frames or the actual game screen frames can also be recorded during the user's game process. And after the user finishes recording or the game game ends, the corresponding game recorded screen frames are generated according to the recorded screen rendering parameters of the actual game screen frames or the actual game screen frames. In this way, during the game, there is no need to perform complex screen calculation operations when recording the game screen, which avoids the recording of the game screen from having a significant impact on the game operation efficiency.
[0090] Step 103: Combine the game recording screen frames to obtain a game recording video.
[0091] After obtaining the game recording screen frames, the game recording screen frames can be combined according to the display order of the actual game screen frames corresponding to the game recording screen frames on the terminal screen to obtain the game recording video.
[0092] Furthermore, since the game frame rate may fluctuate, the display time between every two frames of the actual game screen may be different. For example, in a certain time period during the game operation, the game frame rate is 50 frames / second. In this time period, the display time between every two frames of the actual game screen is 0.02 seconds apart. Correspondingly, when the game recording screen frames corresponding to the actual game screen frames in this time period are combined into a game recording video, the time interval between them should also be 0.02 seconds. In another time period during the game operation, the game frame rate is 25 frames / second. In this time period, the display time between every two frames of the actual game screen is 0.04 seconds apart. Correspondingly, when the game recording screen frames corresponding to the actual game screen frames in this time period are combined into a game recording video, the time interval between them should also be 0.04 seconds. Therefore, the final game recording video can be a variable frame rate video file.
[0093] In an embodiment of the present application, a game recording method is disclosed, including: in the process of responding to a game recording instruction and recording a game video, determining an operable target object in the actual game screen frame obtained by recording; replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element; and combining the game recording screen frames to obtain a game recording video. Therefore, by replacing the current decorative element of the target object in the actual game screen, the target object in the recorded game recording screen can adopt a target decorative element different from the current decorative element seen by the user, and then a game recording video different from the actual game screen seen by the user can be obtained according to the game recording video frame, which increases the fun of game recording, and also facilitates users to experience a variety of decorative elements, thereby enhancing the user's enthusiasm for using the game recording function.
[0094] Figure 4 is a flowchart of another game recording method provided by an embodiment of the present application. Figure 4 As shown, the method includes:
[0095] Step 201: In the process of responding to a game recording instruction and recording a game video, determine an operable target object in the actual game screen frame obtained by recording.
[0096] In the embodiment of the present application, in order to record a game recording screen that is different from the actual game screen, it is ultimately necessary to replace the target decorative element of the target object in the actual game screen. Therefore, after determining the target object, it is also necessary to determine the target decorative element.
[0097] Step 202: Obtain account information and decoration element information of the game account.
[0098] Specifically, the target decorative element may be specified by the game operator in the manner described in step 102 above, and may also be personalized so that different users may replace the decorative element of interest.
[0099] Account information may include the ID information of the game account used by the user to log in to the game client, the account name, and other information that can uniquely identify the user. For some games that include visitor functions, they can be played without logging in, so the account information may also include the identity identification code of the terminal device, the identification code of the game client, etc.
[0100] The decorative element information represents the decorative elements available for the account information used to log into the game client, and may include default decorative elements for each object, decorative elements purchased by the user, and decorative elements obtained through other means. The decorative elements in the decorative element information are decorative elements available to the user and can be selected by the user at any time. Therefore, when determining the target decorative elements, the decorative elements in the decorative element information can be excluded.
[0101] Step 203: Determine the target decorative element of the target object according to the account information and the decorative element information.
[0102] The account information may also include the user's gender, age and other personal information, and the user's personal information may be obtained after obtaining the user's consent. Through the user's personal information and the user's decorative element information, it is possible to further determine the decorative elements that the user does not yet have but is more interested in, and use them as target decorative elements to replace the current decorative elements in the actual game screen. Specifically, the target decorative elements recommended for the user may be determined in the following sub-steps A1 to A3.
[0103] By using the account information and decoration element information of the game account, determining the target decoration element with a high degree of user interest can make the obtained game recording video more likely to arouse the user's interest.
[0104] Optionally, step 203 may further include:
[0105] Sub-step 2031: Determine other accounts whose similarity to the account information exceeds a preset similarity.
[0106] Since users with similar personal information are likely to have similar preferences for decorative elements, in order to determine suitable target decorative elements, other accounts similar to the user's account information can be determined based on the user's account information, and based on the decorative elements owned by other accounts, the decorative elements that the user corresponding to the account information may be interested in can be determined.
[0107] Specifically, the account information of the game account can be compared with the account information of other accounts to determine at least one other account with the highest similarity to the account information of the game account. The account information of the game account can also be compared with the account information of other accounts to determine all other accounts with similarity to the account information of the game account exceeding a preset similarity threshold.
[0108] Sub-step 2032: determining the holding rate of each virtual decorative element according to the decorative element information of the other account, wherein the holding rate is used to represent the probability that the other account holds the virtual decorative element.
[0109] After determining the other accounts corresponding to the game account, obtain the virtual decorative elements of the other accounts, and calculate the holding rate of each decorative element in the virtual decorative elements of the other accounts. For example, there are two other accounts A and other accounts B, other account A has decorative elements A and decorative elements B, and other account B has decorative elements B and decorative elements C, then the holding rate of decorative element A is 50%, the holding rate of decorative element B is 100%, and the holding rate of decorative element C is 50%.
[0110] Then, the decorative element with the highest holding rate that does not exist in the decorative element information of the game account is used as the target decorative element. Using the above example, if the decorative element information of the game account includes decorative element C, the decorative element with the highest holding rate that does not exist in the decorative element information of the game account is decorative element B, and decorative element B is determined as the target decorative element.
[0111] In an embodiment of the present application, target decorative elements can be recommended to a game account based on decorative elements owned by other user accounts similar to the game account, thereby greatly increasing the probability that the target decorative elements will be liked by the user of the game account.
[0112] Sub-step 2033: taking the virtual decorative element whose holding rate is higher than a preset probability as the target decorative element.
[0113] In this way, since the target decoration element finally determined is the decoration element already owned by other user accounts, and the other user accounts are accounts similar to the currently logged in game account, the decoration elements already owned by other user accounts have a greater probability of being the decoration elements that the user using the game account is interested in. Taking the decoration element as the target decoration element can greatly increase the interest of the user corresponding to the game account.
[0114] Step 204: Obtain first rendering parameters for rendering actual game screen frames, where the first rendering parameters include current decorative elements of the target object.
[0115] When the game is running on the terminal, the game client will calculate the first rendering parameters of each frame of the actual game screen based on user operations, game progress, etc. The rendering engine of the game client will render the actual game screen in units of one frame according to the first rendering parameters, and send each rendered frame of the actual game screen to the operating system. The operating system will continuously display the actual game screen frames to the user on the terminal screen so that the user can see a coherent dynamic game screen.
[0116] The first rendering parameters include all screen elements constituting the actual game screen, as well as information such as the position and angle of each screen element. In order to generate a game recording screen that replaces the current decorative elements, the first rendering parameters for rendering the actual game screen frame may be first obtained.
[0117] Step 204 may also include:
[0118] Sub-step 2041, rendering according to the first rendering parameters to obtain the actual game screen frame.
[0119] Since the game recording process cannot affect the user's normal game play, after the game client generates the first rendering parameter, the actual game screen can be rendered according to the first rendering parameter to display the actual game screen normally during the game recording process, avoiding affecting the user's gaming experience when recording the game.
[0120] Sub-step 2042: displaying the actual game frame on the screen in real time according to the order in which the first rendering parameters are obtained.
[0121] Step 205: Replace the current decorative element in the first rendering parameter with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame.
[0122] Since the target object and the target decorative element of the target object have been determined in advance, after obtaining the first rendering parameter, the current decorative element of the target object in the first rendering parameter can be replaced with the target decorative element to obtain the second rendering parameter. In this way, the second rendering parameter can be used to render a game recording screen frame that is different from the actual game screen frame.
[0123] Step 205 may also include:
[0124] Sub-step 2051, obtaining the game recording frame rate value, and calculating the frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent the time interval between two adjacent frames in the game recording video.
[0125] After recording, a game recording video needs to be generated. However, unlike the variable frame rate of the actual game screen, the frame rate of the game recording video is generally fixed due to the limitation of the video format. For example, common video formats include 24 frames / second, 30 frames / second, 60 frames / second, etc. Therefore, in order to ensure that the time interval between two adjacent frames in the game recording video is fixed, it is necessary to select a combination of game recording screen frames corresponding to the actual game screen frames with a fixed time interval according to the display time of the actual game screen frames to obtain the game recording video. In other words, the frame rate of the actual game screen may not be consistent with the frame rate of the game recording video. For example, the frame rate of the actual game screen is 60 frames / second, while the frame rate of the game recording video may be 30 frames / second. At this time, it is only necessary to replace part of the first rendering parameters and obtain the second rendering parameters to render enough game recording screen frames to generate the game recording video, which can greatly save the resource consumption of the terminal device and reduce the impact of the game recording process on the game performance.
[0126] Specifically, the frame interval duration can be calculated according to the frame rate of the game recording video selected by the user or the frame rate of the game recording video set by the game client by default. For example, if the frame rate of the game recording video is 50 frames per second, the corresponding frame interval duration is 1 / 50 seconds, that is, 0.02 seconds.
[0127] Sub-step 2052: Replace the current decorative element in the first rendering parameter having the frame interval between the generated times with the target decorative element, to obtain a second rendering parameter for rendering the game recording screen frame.
[0128] Since the generation frequency of the first rendering parameters is related to the frame rate of the actual game screen, the higher the frame rate of the actual game screen, the shorter the time interval between the generation of two adjacent first rendering parameters, and the lower the frame rate of the actual game screen, the longer the time interval between the generation of two adjacent first rendering parameters. For example, if the game frame rate is 100 frames / second, the first first rendering parameter is generated at 0 seconds, then the second first rendering parameter is generated at 0.01 seconds, and so on. If the game frame rate is 50 frames / second, the first first rendering parameter is generated at 0 seconds, then the second first rendering parameter is generated at 0.02 seconds, and so on.
[0129] Since the frame rate of the game recording video is fixed and not necessarily the same as the frame rate of the actual game screen, it is necessary to obtain the game recording screen frames used to combine the game recording video according to the frame rate of the game recording video and the frame interval duration. Therefore, it is necessary to replace the current decorative element in the first rendering parameter with the frame interval duration to obtain the second rendering parameter.
[0130] For example, if the game frame rate is 100 frames per second and the game recording video frame rate is 50 frames per second, the first rendering parameter needs to be replaced with a frame interval of 0.02 seconds. In other words, there is one first rendering parameter between two first rendering parameters corresponding to adjacent second rendering parameters.
[0131] Furthermore, since the game frame rate and the game recording video frame rate are not always an integer multiple relationship, it is possible that the game frame rate is 50 frames per second, while the game refers to the video frame rate of 30 frames per second. It is also possible that the game frame rate is not stable, but changes at all times. At this time, the generation time of the first rendering parameter can be marked as a first time point on the timeline, and the second time point can be marked on the timeline according to the frame interval duration, and the first rendering parameter corresponding to the first time point closest to each second time point is replaced to obtain the same number of second rendering parameters as the second time points.
[0132] In an embodiment of the present application, a second rendering parameter matching the frame rate of the game recording video can be obtained by measuring the frame interval duration of adjacent frames of a game recording video generated by the first rendering parameter. This not only makes the game recording video rendered by the second rendering parameter smoother, but also greatly reduces the number of second rendering parameters that need to be processed, reduces the computing resources consumed by the game recording process, and reduces the impact on game operation.
[0133] Step 206: Render according to the second rendering parameters to obtain a game recording screen frame.
[0134] For each second rendering parameter, the game recording screen frame can be directly rendered according to the second rendering parameter after being obtained, so that the game recording video can be directly obtained when the game recording ends.
[0135] In order to further reduce the impact on the game operation, the second rendering parameter can also be stored during the game process, and after the game recording is completed, the game recording screen frame is rendered according to the stored second rendering parameter. In this way, it can be avoided that the rendering of the game recording screen frame while rendering the actual game screen frame affects the game operation efficiency.
[0136] Step 206 may also include:
[0137] Sub-step 2061, obtaining the system's hardware configuration information and the setting information of the actual game running screen.
[0138] In order to further avoid the impact of the game recording process on the game operation, the resolution of the game recording video can be automatically adjusted according to the hardware configuration information of the terminal device and the setting information of the actual game running screen, that is, the resolution of the game recording screen frame rendered by the second rendering parameter is adjusted. The lower the resolution of the game recording screen frame, the less system resources are occupied by rendering the game recording screen frame.
[0139] When the hardware configuration of the terminal device is fixed, the more detailed the settings of the actual game running screen and the higher the frame rate, the more system resources the game takes up. Conversely, the system resources the game takes up are lower.
[0140] Specifically, in order to determine the computing resources required to meet the setting information of the actual running screen of the current game, it is necessary to adjust the rendering resolution of the game recording screen frame to meet the performance requirements of the actual running screen of the current game. First, it is necessary to obtain the hardware configuration information of the system and the setting information of the actual running screen of the game. The hardware configuration information may include CPU information, GPU information, memory information and other hardware information that affects the performance of the terminal device. The setting information of the actual running screen of the game may include resolution settings, anti-aliasing settings, shadow settings and other settings that affect the resource consumption of rendering the actual game screen frame.
[0141] Sub-step 2062: determining a recording resolution according to the hardware configuration information and the setting information.
[0142] After obtaining the hardware configuration information of the terminal device, you can query the configuration performance table to determine the hardware performance score corresponding to the hardware configuration of the current terminal device. The configuration performance table contains the corresponding relationship between the configuration and the performance score, and the configuration performance table can be obtained by the technicians through actual testing of terminal devices with different hardware configurations.
[0143] After obtaining the setting information of the actual running screen of the game, the setting performance table can be queried to determine the running performance score required for the current game screen setting. The setting performance table contains the corresponding relationship between the screen setting and the performance score. The setting performance table can be obtained by the technicians through actual testing of the hardware performance required for running the game under different settings.
[0144] The remaining performance score of the terminal device is determined by the difference between the hardware performance score and the running performance score. For example, the hardware performance score of a terminal device is 100 points, and the running performance score corresponding to the setting information of the actual running screen of the current game is 70 points. Then the remaining performance score of the terminal device is calculated to be 30 points.
[0145] After determining the remaining performance score of the terminal device, you can query the recording resolution table corresponding to the current recording frame rate to determine the recording resolution corresponding to the remaining performance score at the current recording frame rate. The recording resolution table contains the corresponding relationship between performance scores and resolutions. The recording resolution table corresponding to a certain recording frame rate can be obtained by technicians through actual testing of the performance scores consumed by different recording resolutions at the recording frame rate.
[0146] It should be noted that the recording resolution can also be set manually by the user.
[0147] Sub-step 2063, rendering according to the second rendering parameters to obtain a game recording screen frame that meets the recording resolution.
[0148] In the embodiment of the present application, the appropriate recording resolution can be automatically set according to the performance of the terminal device and the performance requirements of the game, so that the terminal device can record the game screen while meeting the game performance requirements, avoiding the situation where the performance required by the game cannot be met due to rendering the game recording screen frames during the game, thereby greatly improving the user's gaming experience when applying the embodiment of the present application.
[0149] Step 207: Combine the game recording screen frames to obtain a game recording video.
[0150] The game client operation process usually includes a play part and a menu part. After the user opens the game software, he usually enters the menu part of the game. The user can select and start the play part of the game in the menu part. After the game is over, the user will exit the play part and return to the menu part.
[0151] In an embodiment of the present application, after the game client ends the playing part, it can automatically stop the game recording process and input all the obtained game recording screen frames into the video encoder. The video encoder encodes all the game recording screen frames according to the recording frame rate and recording resolution to generate a game recording video.
[0152] Furthermore, the user can also set different game recording video formats, such as MP4 video format, AVI video format, etc. After finishing the playing part, the game client can input the game recording screen frames into the corresponding video encoder for encoding according to the game recording video format set by the user.
[0153] It is understandable that the encoding of the game recording screen frames can also be performed synchronously during the game process, so that the encoded game recording video can be output immediately after the game recording process is stopped.
[0154] Step 208: When the game account ends playing, the game recording video and the target decoration element are displayed on the screen.
[0155] After obtaining the game recording video, the game recording video and the target decorative element can be displayed to the user to remind the user that the game recording operation has been completed, and the current decorative element in the actual game screen is replaced with the target decorative element. At the same time, the save and delete options of the game recording video can also be displayed to the user to facilitate the user to process the game recording video.
[0156] In an embodiment of the present application, a game recording method is disclosed, including: in the process of responding to a game recording instruction and recording a game video, determining an operable target object in the actual game screen frame obtained by recording; replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element; and combining the game recording screen frames to obtain a game recording video. Therefore, by replacing the current decorative element of the target object in the actual game screen, the target object in the recorded game recording screen can adopt a target decorative element different from the current decorative element seen by the user, and then a game recording video different from the actual game screen seen by the user can be obtained according to the game recording video frame, which increases the fun of game recording, and also facilitates users to experience a variety of decorative elements, thereby enhancing the user's enthusiasm for using the game recording function.
[0157] Corresponding to the method provided by the above-mentioned embodiment of the game recording method of the present invention, see Figure 5 The present invention also provides a game recording device structure diagram. In this embodiment, the device may include:
[0158] The determination module 301 is configured to determine an operable target object in the actual game screen frame obtained by recording in response to the game recording instruction and in the process of recording the game video;
[0159] A replacement module 302 is configured to replace the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element;
[0160] The video module 303 is configured to combine the game recording screen frames to obtain a game recording video.
[0161] In an optional implementation, the replacement module includes:
[0162] An instruction acquisition submodule is configured to acquire a first rendering parameter for rendering an actual game screen frame, wherein the first rendering parameter includes a current decorative element of the target object;
[0163] A replacement submodule is configured to replace the current decoration element in the first rendering parameter with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame;
[0164] The rendering submodule is configured to render the game recording screen frame according to the second rendering parameters.
[0165] In an optional embodiment, the device further comprises:
[0166] A rendering module, configured to render the actual game screen frame according to the first rendering parameters;
[0167] The display module is configured to display the actual game screen frames on the screen in real time according to the acquisition order of the first rendering parameters.
[0168] In an optional implementation, the replacement submodule includes:
[0169] A frame interval submodule is configured to obtain a game recording frame rate value, and calculate a frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent a time interval between two adjacent frames in the game recording video;
[0170] The instruction determination submodule is configured to replace the current decorative element in the first rendering parameter with the frame interval duration between generation times with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame.
[0171] In an optional implementation, the rendering submodule includes:
[0172] The information determination submodule is configured to obtain the hardware configuration information of the system and the setting information of the actual running screen of the game;
[0173] A resolution submodule, configured to determine a recording resolution according to the hardware configuration information and the setting information;
[0174] The recording screen frame submodule is configured to render a game recording screen frame that meets the recording resolution according to the second rendering parameters.
[0175] In an optional embodiment, the device further comprises:
[0176] An information acquisition module, configured to acquire account information and decoration element information of a game account;
[0177] The target element module is configured to determine the target decorative element of the target object according to the account information and the decorative element information.
[0178] In an optional implementation, the determining submodule includes:
[0179] Other account submodule, configured to determine other accounts whose similarity with the account information exceeds a preset similarity;
[0180] a holding rate submodule, configured to determine a holding rate of each virtual decorative element according to the decorative element information of the other accounts, wherein the holding rate is used to represent a probability that the other accounts hold the virtual decorative element;
[0181] The target element submodule is configured to use the virtual decorative element whose holding rate is higher than a preset probability as the target decorative element.
[0182] In an optional embodiment, the device further comprises:
[0183] The display submodule is configured to display the game recording video and the target decoration element on the screen when the game account ends the current game process.
[0184] In summary, a game recording model generation device provided by an embodiment of the present application includes: a determination module, configured to determine an operable target object in the actual game screen frame obtained by recording in the process of responding to a game recording instruction and recording a game video; a replacement module, configured to replace the current decorative element of the target object in the actual game screen frame with a target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element; and a video module, configured to combine the game recording screen frames to obtain a game recording video. Therefore, by replacing the current decorative element of the target object in the actual game screen, the target object in the recorded game recording screen can adopt a target decorative element different from the current decorative element seen by the user, and then a game recording video different from the actual game screen seen by the user can be obtained based on the game recording video frame, which increases the fun of game recording, and also facilitates users to experience a variety of decorative elements, thereby enhancing the user's enthusiasm for using the game recording function.
[0185] Figure 6 is a block diagram of an electronic device 600 according to an exemplary embodiment. For example, the electronic device 600 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0186] Reference Figure 6 , the electronic device 600 may include one or more of the following components: a processing component 602 , a memory 604 , a power component 606 , a multimedia component 608 , an audio component 610 , an input / output (I / O) interface 612 , a sensor component 614 , and a communication component 616 .
[0187] The processing component 602 generally controls the overall operation of the electronic device 600, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 602 may include one or more processors 620 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 602 may include one or more modules to facilitate the interaction between the processing component 602 and other components. For example, the processing component 602 may include a multimedia module to facilitate the interaction between the multimedia component 608 and the processing component 602.
[0188] The memory 604 is used to store various types of data to support the operation of the electronic device 600. Examples of such data include instructions for any application or method operating on the electronic device 600, contact data, phone book data, messages, pictures, videos, etc. The memory 604 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0189] The power supply component 606 provides power to the various components of the electronic device 600. The power supply component 606 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 600.
[0190] The multimedia component 608 includes a screen that provides an output interface between the electronic device 600 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 608 includes a front camera and / or a rear camera. When the electronic device 600 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
[0191] The audio component 610 is used to output and / or input audio signals. For example, the audio component 610 includes a microphone (MIC), and when the electronic device 600 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is used to receive an external audio signal. The received audio signal can be further stored in the memory 604 or sent via the communication component 616. In some embodiments, the audio component 610 also includes a speaker for outputting audio signals.
[0192] I / O interface 612 provides an interface between processing component 602 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.
[0193] The sensor assembly 614 includes one or more sensors for providing various aspects of status assessment for the electronic device 600. For example, the sensor assembly 614 can detect the open / closed state of the electronic device 600, the relative positioning of the components, such as the display and keypad of the electronic device 600, and the sensor assembly 614 can also detect the position change of the electronic device 600 or a component of the electronic device 600, the presence or absence of contact between the user and the electronic device 600, the orientation or acceleration / deceleration of the electronic device 600, and the temperature change of the electronic device 600. The sensor assembly 614 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 614 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 614 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0194] The communication component 616 is used to facilitate wired or wireless communication between the electronic device 600 and other devices. The electronic device 600 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 616 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 616 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0195] In an exemplary embodiment, the electronic device 600 can be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components to implement a game recording method provided in an embodiment of the present application.
[0196] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 604 including instructions, and the instructions can be executed by a processor 620 of an electronic device 600 to perform the above method. For example, the non-transitory storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0197] Figure 7is a block diagram of an electronic device 700 according to an exemplary embodiment. For example, the electronic device 700 may be provided as a server. Figure 7 The electronic device 700 includes a processing component 722, which further includes one or more processors, and a memory resource represented by a memory 732 for storing instructions executable by the processing component 722, such as an application. The application stored in the memory 732 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 722 is configured to execute instructions to perform a game recording method provided in an embodiment of the present application.
[0198] The electronic device 700 may also include a power supply component 726 configured to perform power management of the electronic device 700, a wired or wireless network interface 750 configured to connect the electronic device 700 to a network, and an input / output (I / O) interface 758. The electronic device 700 may operate based on an operating system stored in the memory 732, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™ or the like.
[0199] An embodiment of the present application also provides a computer program product, including a computer program, which implements the game recording method when executed by a processor.
[0200] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the application disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.
[0201] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A game recording method, characterized in that: The method comprises: In the process of responding to the game recording instruction and recording the game video, determining an operable target object in the actual game screen frame obtained by recording; Replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element, and the replacement of the current decorative element of the target object in the actual game screen frame is performed when the actual game screen frame is generated; Combining the game recording screen frames to obtain a game recording video; The step of replacing the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame includes: Obtain a first rendering parameter for rendering an actual game screen frame, wherein the first rendering parameter includes a current decorative element of the target object; replace the current decorative element in the first rendering parameter with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame; and render the game recording screen frame according to the second rendering parameter.
2. The method according to claim 1, characterized in that The method further comprises: Rendering according to the first rendering parameters to obtain the actual game screen frame; According to the order in which the first rendering parameters are obtained, the actual game picture frames are displayed on the screen in real time.
3. The method according to claim 1, characterized in that The step of replacing the current decoration element in the first rendering parameter with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame includes: Obtaining a game recording frame rate value, and calculating a frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent a time interval between two adjacent frames in the game recording video; The current decoration element in the first rendering parameter having the frame interval duration between generation times is replaced with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame.
4. The method according to claim 1, characterized in that: The rendering according to the second rendering parameter to obtain a game recording screen frame includes: Get the system's hardware configuration information and the game's actual running screen settings; Determine the recording resolution according to the hardware configuration information and the setting information; The game recording screen frames that meet the recording resolution are rendered according to the second rendering parameters.
5. The method according to claim 1, characterized in that The method further comprises: Get the account information and decoration element information of the game account; A target decorative element of the target object is determined according to the account information and the decorative element information.
6. The method according to claim 5, characterized in that The step of determining the target decorative element of the target object according to the account information and the decorative element information includes: Determine other accounts whose similarity to the account information exceeds a preset similarity; Determining, according to the decoration element information of the other accounts, a holding rate of each virtual decoration element, wherein the holding rate is used to represent the probability that the other accounts hold the virtual decoration element; The virtual decorative element with a holding rate higher than a preset probability is used as the target decorative element.
7. The method according to claim 1, characterized in that After combining the game recording screen frames to obtain the game recording video, the method further includes: When the game account ends the current game process, the game recording video and the target decoration element are displayed on the screen.
8. A game recording device, characterized in that: The device comprises: A determination module is configured to determine an operable target object in an actual game screen frame obtained by recording in response to a game recording instruction and in the process of recording a game video; a replacement module, configured to replace the current decorative element of the target object in the actual game screen frame with the target decorative element to obtain a game recording screen frame, wherein the current decorative element is different from the target decorative element, and the replacement of the current decorative element of the target object in the actual game screen frame is performed when the actual game screen frame is generated; A video module, configured to combine the game recording screen frames to obtain a game recording video; Wherein, the replacement module includes: An instruction acquisition submodule is configured to acquire a first rendering parameter for rendering an actual game screen frame, wherein the first rendering parameter includes a current decorative element of the target object; A replacement submodule is configured to replace the current decoration element in the first rendering parameter with the target decoration element to obtain a second rendering parameter for rendering a game recording screen frame; The rendering submodule is configured to render the game recording screen frame according to the second rendering parameters.
9. The device according to claim 8, characterized in that The device also includes: A rendering module, configured to render the actual game screen frame according to the first rendering parameters; The display module is configured to display the actual game screen frames on the screen in real time according to the acquisition order of the first rendering parameters.
10. The device according to claim 8, characterized in that The replacement submodule comprises: A frame interval submodule is configured to obtain a game recording frame rate value, and calculate a frame interval duration according to the game recording frame rate value, wherein the frame interval duration is used to represent a time interval between two adjacent frames in the game recording video; The instruction determination submodule is configured to replace the current decorative element in the first rendering parameter with the frame interval duration between generation times with the target decorative element to obtain a second rendering parameter for rendering a game recording screen frame.
11. The device according to claim 8, characterized in that The rendering submodule includes: The information determination submodule is configured to obtain the hardware configuration information of the system and the setting information of the actual running screen of the game; A resolution submodule, configured to determine a recording resolution according to the hardware configuration information and the setting information; The recording screen frame submodule is configured to render a game recording screen frame that meets the recording resolution according to the second rendering parameters.
12. The device according to claim 8, characterized in that The device also includes: An information acquisition module, configured to acquire account information and decoration element information of a game account; The target element module is configured to determine the target decorative element of the target object according to the account information and the decorative element information.
13. The device according to claim 12, characterized in that The determination submodule comprises: Other account submodule, configured to determine other accounts whose similarity with the account information exceeds a preset similarity; a holding rate submodule, configured to determine a holding rate of each virtual decorative element according to the decorative element information of the other accounts, wherein the holding rate is used to represent a probability that the other accounts hold the virtual decorative element; The target element submodule is configured to use the virtual decorative element whose holding rate is higher than a preset probability as the target decorative element.
14. The device according to claim 8, characterized in that The device also includes: The display submodule is configured to display the game recording video and the target decoration element on the screen when the game account ends the current game process.
15. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; The processor is configured to execute the instructions to implement the method according to any one of claims 1 to 7.
16. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to perform the method as claimed in any one of claims 1 to 7.
17. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Game video recording method and game video recording device
CN104811787A
Game video generation method and device
CN107551546A
Live-streaming costume dress-up method and device based on self-adaptive threshold value segmentation
CN108010038A