Audio processing methods, apparatus, storage media, and electronic devices in games.
The audio processing method enhances game audio by determining spatial regions and generating audio data based on position changes, addressing poor playback effects in virtual item movements.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- NETEASE (HANGZHOU) NETWORK CO LTD
- Filing Date
- 2022-09-28
- Publication Date
- 2026-06-04
AI Technical Summary
Current games struggle with poor audio playback effects due to fixed position sound effects for virtual items, failing to account for changes during high-speed movement.
An audio processing method that determines a target position and spatial region for virtual items, using first and second position information to generate audio data indicating orientation changes during movement, enhancing audio playback with an audio engine.
Improves audio playback effects by accurately representing orientation changes of virtual items, providing a more realistic audio experience in games.
Smart Images

Figure 0007870345000001 
Figure 0007870345000002 
Figure 0007870345000003
Abstract
Description
Technical Field
[0001] This disclosure claims priority based on a Chinese patent application with an application number of 202210135103.3 and a title of "Audio Processing Method, Apparatus, Storage Medium, and Electronic Device in a Game", which was filed on February 14, 2022, and incorporates all the content of the Chinese patent application into this application.
[0002] This disclosure relates to the field of computers, and specifically, to an audio processing method, apparatus, storage medium, and electronic device in a game.
Background Art
[0003] Currently, most games can only play the attack effect sounds of virtual items at fixed positions, and it is difficult to consider the changes in the effect sounds during the high-speed movement of virtual items, resulting in the technical problem of poor audio playback effect in games.
[0004] Regarding the problem of poor audio playback effect in games, currently, no effective solution has been proposed.
Summary of the Invention
[0005] At least some embodiments of this disclosure provide an audio processing method, apparatus, storage medium, and electronic device in a game to at least solve the technical problem of poor audio playback effect in games.
[0006] To achieve the above objective, an audio processing method for a game is provided according to one embodiment of the present disclosure. The method may include: determining a target position in which a virtual game character is located in a game scene; determining a target spatial region in the game scene based on the target position; determining a first position information when a virtual item enters the target spatial region and a second position information when it leaves the target spatial region; and determining first audio data corresponding to the virtual item based on the first and second position information, wherein the first audio data is used to indicate the azimuthal change state of the virtual item during the process of moving from the first position information to the second position information.
[0007] To achieve the above objectives, another aspect of the present disclosure further provides an audio processing device for a game. The device may include a first determination unit for determining a target position in which a virtual game character is located in a game scene; a second determination unit for determining a target spatial region in the game scene based on the target position; a third determination unit for determining first position information when a virtual item enters the target spatial region and second position information when it leaves the target spatial region; and a fourth determination unit for determining first audio data corresponding to the virtual item based on the first and second position information, wherein the first audio data is used to indicate the orientation change state of the virtual item during the process of moving from the first position information to the second position information.
[0008] To achieve the above objectives, another aspect of the present disclosure further provides a computer-readable storage medium in which a computer program is stored, and which, when executed by a processor, controls the device on which the computer-readable storage medium is located to execute an audio processing method in a game of an embodiment of the present disclosure.
[0009] To achieve the above objectives, electronic devices are further provided according to another aspect of the present disclosure. The electronic devices may include memory and a processor, the memory storing a computer program and the processor being configured to execute the computer program by the processor to perform the audio processing method in the game of the embodiment of the present disclosure.
[0010] In at least some embodiments of this disclosure, a target position where a virtual game character is located in a game scene is determined, a target spatial region is determined in the game scene based on the target position, first position information when a virtual object enters the target spatial region and second position information when it leaves the target spatial region are determined, and first audio data corresponding to the virtual object is determined based on the first and second position information, where the first audio data is used to indicate the orientation change state of the virtual object during the process of moving from the first position information to the second position information. In other words, this disclosure acquires the orientation change state of the virtual object during the process of moving from the first position information to the second position information, transmits the first and second position information to an audio engine, and causes the audio engine to determine and play the first audio data corresponding to the virtual object, thereby providing accurate orientation representation to the flight sound of the virtual object, and realizing a technical effect that further improves the audio playback effect in games, thereby solving the technical problem of poor audio playback effect in games. [Brief explanation of the drawing]
[0011] The drawings described herein provide further understanding of the Disclosure and constitute part of the Disclosure. Exemplary embodiments and their descriptions are for illustrative purposes only and do not unduly limit the Disclosure. In the drawings, [Figure 1] This is a block diagram showing the hardware structure of a mobile terminal for an audio processing method in a game according to one embodiment of the present disclosure. [Figure 2] This is a flowchart of an audio processing method in a game according to one embodiment of the present disclosure. [Figure 3] This is a schematic diagram of the trigger for the sound effect of a projectile in flight in related technology 1. [Figure 4] This is a schematic diagram of the waveform and sound image table of the projectile flight sound effect in related technology 1. [Figure 5] This is a schematic diagram of a trigger for a projectile flight sound effect according to one embodiment of the present disclosure. [Figure 6] This is a schematic diagram of the waveform and sound image of the sound effect of a projectile in flight when an enemy fires from directly to the right to directly to the left, according to one embodiment of the present disclosure. [Figure 7] This is a flowchart of an audio processing method in a game according to one embodiment of the present disclosure. [Figure 8] This is a schematic diagram of the adjustment parameters according to one embodiment of the present disclosure. [Figure 9] This is a schematic diagram of a spherical audible range with coordinate information attached to its surface according to one embodiment of the present disclosure. [Figure 10] This is a schematic diagram illustrating how to establish real-time control parameters and set attributes according to one embodiment of the present disclosure. [Figure 11(a)] This is a schematic diagram illustrating the selection and basic settings of a bullet flight sound effect sample according to one embodiment of the present disclosure. [Figure 11(b)] This is a schematic diagram of the waveform of a sample of a projectile flight sound effect according to one embodiment of the present disclosure. [Figure 12] This is a schematic diagram illustrating the relationship between a sample and real-time control parameters according to one embodiment of the present disclosure. [Figure 13] This is a structural block diagram of an audio processing device in a game according to one embodiment of the present disclosure. [Figure 14] This is a structural block diagram of an electronic device according to an embodiment of the present disclosure. [Modes for carrying out the invention]
[0012] To enable those skilled in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present disclosure. It is clear that the described embodiments are only a part of the embodiments of the present disclosure, not all of them. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative efforts shall be included in the protection scope of the present disclosure.
[0013] In addition, the terms such as "first", "second", etc. in the specification, claims and the above-mentioned accompanying drawings of the present disclosure are used to distinguish similar objects and do not need to be used to explain a specific order or arrangement. It is understood that the data used in this way can be appropriately exchanged so that the embodiments of the present disclosure described in this specification can be implemented in an order other than those illustrated or described in this specification. Also, the terms "comprising", "having" and their variants are intended to be non-exclusive inclusion. For example, a process, method, system, product or device consisting of a series of steps or units does not necessarily have to be limited to these steps or units. However, it may include other steps or units not explicitly described or specific to those processes, methods, products, devices.
[0014] First, some nouns or terms that appear in the process of describing the embodiments of the present disclosure are applicable to the following description.
[0015] The audio engine (Wwise) is used for an audio engine that docks with a game engine and can realize a rich audio solution for game interconnection.
[0016] An event (Event) is used to receive calls from the game engine. For an Event, it is set which audio-related operation this call corresponds to execute. For example, the most common operations include playing a certain audio, stopping a certain audio, resetting a certain number of parameters, etc.
[0017] Due to the Doppler effect, for example, when a car speeds past in front of a listener, the listener hears the pitch of the car's sound change from high to low.
[0018] The left and right audio image parameters (Pan) of stereo audio act based on the "binaural effect" of humans. For example, when the left and right audio image parameters are set extremely to the left, the earphone / horn emits sound only from the left channel, and the listener perceives the sound source to be on the left side.
[0019] Low Pass allows only the filter effect of filtering high frequencies and passing low frequencies. When such an effect is used on audio, the emitted sound is described as being "enclosed".
[0020] Volume refers to the parameter of the loudness in the audio field.
[0021] A Digital Audio Workstation (abbreviated as DAW) refers to multi-track, multi-functional audio, and music editing software.
[0022] Automation is the automation information in a digital audio workstation. It is always added to the track in the form of a "drawing line" in the digital audio workstation and is controlled in association with these "lines" during playback. It is executed according to various Musical Instrument Digital Interface (abbreviated as MIDI) parameters and audio parameters, and furthermore, the sound parameters change following the pre-edited parameter effects, such as the volume fading out, the left and right audio images fading to the left and right, and switches for muting tracks.
[0023] Real-time control parameters (RTPCs) are a type of control information within the audio engine. Similar to the function of automatic control information in a digital audio workstation, they can significantly influence sound parameters in the audio engine. The only difference is that the specific real-time parameter control values are not predetermined like automatic control information, but are determined by certain data within the game.
[0024] First-person shooter (FPS) games are a general term for electronic shooting games in which the player's first-person field of view is used as the primary field of view, and usually require the use of firearms or other weapons.
[0025] Third-person shooter (TPS) games are a type of shooting game, and the difference from first-person shooter games is that in first-person shooter games, only the main character's field of view is displayed on the screen, whereas in third-person shooter games, the sense of movement is more emphasized, and the main character can be seen on the game screen.
[0026] A sound sample refers to an audio segment or audio file that was actually played in a game sound effect.
[0027] Random sampling refers to the practice of creating a collection of multiple very similar sound samples and randomly triggering one each time, often to make the representation of certain sounds in a game more realistic and reduce their reproducibility.
[0028] A whoosh is a "whoosh" or "whoosh" sound produced when an object flies rapidly or when an object is shaken. It is used to describe sounds produced by a car speeding from the front, an object flying, a weapon being swung, a rope being swung, etc. For example, a bullet whoosh can mean "the sound of a bullet flying."
[0029] According to one embodiment of the present disclosure, an embodiment of an audio processing method in a game is provided, wherein the steps shown in the flowchart of the accompanying drawings may be performed on a computer system such as a set of computer-executable instructions, and although a logical sequence is shown in the flowchart, in some examples the steps shown or described may be performed in a different order than those shown herein.
[0030] Embodiments of this method can be executed on a mobile terminal, a computer terminal, or a similar computing device. When executed on a mobile terminal, for example, this mobile terminal may be a terminal device such as a smartphone (e.g., an Android phone, an iOS phone), a tablet terminal, a handheld computer, a Mobile Internet Device (MID), a PAD, or a game console. Figure 1 is a block diagram showing the hardware structure of a mobile terminal for an audio processing method in a game according to an embodiment of the present disclosure. As shown in Figure 1, the mobile terminal may include, but is not limited to, one or more (only one is shown in Figure 1) processors 102 (processors 102 are processing units such as a central processing unit (CPU), a graphics processor (GPU), a digital signal processing (DSP) chip, a microprocessor (MCU), a programmable logic device (FPGA), a neural network processor (NPU), a tensor processor (TPU), or an artificial intelligence (AI) type processor) and memory 104 for storing data. Optionally, the mobile terminal may further include a transmitting device 106, an input / output device 108, and a display device 110 for communication functions. Those skilled in the art will understand that the structure shown in Figure 1 is schematic and does not limit the structure of the mobile terminal. For example, the mobile terminal may further include more or fewer components than those shown in Figure 1, or may have a different configuration than that shown in Figure 1.
[0031] Memory 104 is used to store computer programs such as software programs and modules of application software corresponding to the audio processing method in the game in the embodiments of this disclosure, for example. The processor 102 executes various functional applications and data processing by executing the computer programs stored in memory 104, thereby realizing the audio processing method in the game described above. Memory 104 may include high-speed random-access memory, or it may include non-volatile memory such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some embodiments, memory 104 may further include memory located remotely from the processor 102, and these remote memories may be connected to a mobile terminal via a network. Examples of the network include, but are not limited to, the Internet, a corporate intranet, a local area network, a mobile communication network, and combinations thereof.
[0032] The transmission device 106 transmits and receives data over a network. Specific examples of the above network may include a wireless network provided by a mobile terminal's carrier. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, abbreviated as NIC) that can connect to other network equipment via a base station to communicate with the Internet. In one example, the transmission device 106 may also be a radio frequency (RF) module used for wireless communication with the Internet.
[0033] The inputs to the input / output device 108 may come from multiple Human Interface Devices (HIDs). For example, these may be keyboards, mice, game handles, or other dedicated game controllers (e.g., steering wheels, fishing rods, dance mats, remote controls, etc.). Some Human Interface Devices may provide output functions in addition to input functions, such as force feedback and vibration from a game handle, or audio output from a controller.
[0034] The display device 110 may be, for example, a head-up display (HUD), a touchscreen liquid crystal display (LCD), and a touch display (also called a “touchscreen” or “touch display”). The liquid crystal display is for the user to interact with the user interface of the mobile terminal. In some embodiments, the mobile terminal has a graphical user interface (GUI) that allows the user to interact with the GUI by touching and / or gestures of their finger on a touch-sensitive surface, where the human-computer interaction functions optionally include web page creation, drawing, word processing, electronic document creation, games, video conferencing, instant messaging, sending and receiving emails, call interfaces, digital video playback, digital music playback, and / or web browsing, and the executable instructions for performing the above human-computer interaction functions are configured / stored in one or more processor-executable computer program products or readable storage media.
[0035] This embodiment provides a method for determining the rendering time performed on the mobile device described above. Figure 2 is a flowchart of an audio processing method in a game according to one embodiment of this disclosure. As shown in Figure 2, the method includes the following steps.
[0036] In step S202, the target position where the virtual game character is located in the game scene is determined.
[0037] In the proposed technology provided by step S202 of this disclosure, a target position is determined in which a virtual game character is located in a game scene, where the virtual game character may be a game object in the game scene, and the target position may be the position in which the virtual game character is located.
[0038] In step S204, the target spatial region in the game scene is determined based on the target position.
[0039] In the proposed technology provided by step S204 of this disclosure, a target position in which a virtual game character is located in a game scene is determined, and a target spatial region in the game scene is determined based on the target position, where the target spatial region may be a spatial region with coordinate information simulated around the virtual game character, for example, a spherical space with coordinate information.
[0040] The system arbitrarily determines a target position for a virtual game character in a game scene and simulates a spatial region with coordinate information centered on that target position.
[0041] In step S204, the first position information of the virtual item when it enters the target spatial region and the second position information of the virtual item when it leaves the target spatial region are determined.
[0042] In the proposed technology provided by step S204 of this disclosure, a spatial region with coordinate information is simulated centered on a target location where a virtual game character is located, first position information is generated when a virtual item enters the target spatial region, and second position information is generated when the virtual item leaves the target spatial region, where the first position information may be a set of coordinate information represented as (X-axis, Y-axis, Z-axis), and the second position information may be a set of coordinate information represented as (X-out, Y-out, Z-out), and the virtual item may be virtual equipment that requires motion sound effects such as bullets, darts, hand grenades, or missiles.
[0043] Furthermore, the hypothetical cedar article in this embodiment is not limited to offensive equipment, and may also include other types of offensive equipment, such as mobile sound sources, and is not specifically limited here.
[0044] When a virtual object optionally passes through the target spatial region, first and second positional information are generated. The first positional information is the coordinates of the point where the virtual object intersects the surface of the target spatial region when entering it, and the second positional information is the coordinates of the point where the virtual object intersects the surface of the target spatial region when leaving it.
[0045] For example, when a projectile passes through a spherical target space region, two sets of coordinates are generated: one set is the coordinates of the intersection point with the sphere's surface when the projectile enters the sphere, and the other set is the coordinates when it leaves the sphere. The coordinates of the intersection point when entering the sphere can be denoted as (X-direction, Y-direction, Z-direction), and the coordinates of the intersection point when leaving the sphere can be denoted as (X-out, Y-out, Z-out). If the listener is at the center of the sphere and facing directly towards the screen, the radius of the set audible range is 300. When the projectile enters the target space region, the distance can be automatically measured and first and second position information can be generated. For example, if X-direction = 290, Y-direction = 12, Z-direction = -5, X-out = -290, Y-out = -13, Z-out = 10 is measured, the first and second position information will be (290, 12, -5) and (-290, -13, 10), respectively.
[0046] In step S206, first audio data corresponding to the virtual item is determined based on the first and second location information, where the first audio data is used to indicate the change in orientation of the virtual item during the process of moving from the first location information to the second location information.
[0047] In the proposed technology provided by step S206 of the present disclosure, when a virtual article passes through a target spatial region, first position information and second position information are generated and transmitted to an audio engine, which determines and plays first audio data corresponding to the virtual article based on the first and second position information, wherein the first audio data may be used to indicate the orientation change state of the virtual article during the process of moving from the first position information to the second position information.
[0048] Optionally, the first audio data may be obtained by creating and editing audio data using an audio engine, or it may be selected from audio data purchased elsewhere. The audio engine may obtain the first audio data by placing the audio data resources in the game engine's engineering directory via a plugin, and then calling and playing the audio data resources from the engineering directory when the game engine is executed. Alternatively, the audio engine may be provided within the game engine, that is, the game engine may have the functionality of an audio engine, or it may purchase an audio engine created elsewhere and associate it with the game engine.
[0049] When a virtual object optionally passes through a target spatial region, first and second position information are generated, the first and second position information are transmitted to the audio engine, the corresponding first audio data is determined during the process of passing through the first and second position information, and the first audio data is played back.
[0050] Optionally, the first audio data may be real-time control parameters (RTPCs), named BulletWhoosh_Left_Right, BulletWhoosh_Front_Rear, and BulletWhoosh_Up_Down, and the corresponding first audio data is determined based on the first and second position information as the virtual object passes through the target spatial region.
[0051] For example, when a virtual object passes through a target spatial region, the real-time control parameters generate corresponding first audio data based on first and second position information, for example, generating X-movement and X-exit for shot_left_right, Y-movement and Y-exit for shot_forward_backward, and Z-movement and Z-exit for shot_up_down.
[0052] In step S208, first audio data corresponding to the virtual item is determined based on the first and second location information, where the first audio data is used to indicate the change in orientation of the virtual item during the process of moving from the first location information to the second location information.
[0053] In the proposed technology provided by step S208 of this disclosure, the corresponding first audio data of the virtual article during the process of moving from the first location to the second location is determined based on the first location information of the received virtual article when it enters the target spatial region and the second location information of the virtual article when it leaves the target spatial region.
[0054] Optionally, the audio engine can synchronously establish real-time control parameter components for projectile sound_left_right, projectile sound_front_back, and projectile sound_up_down. After a virtual object passes through the target spatial region, the real-time control parameters can generate corresponding numerical values and transmit them to the audio engine. The audio engine receives the first and second position information generated by the virtual object and converts the received first and second position information into corresponding first audio data, thereby achieving the objective of determining the corresponding first audio data for the virtual object during its movement from the first to the second position information.
[0055] Steps S202 to S208 of this disclosure determine the target position where a virtual game character is located in a game scene, determine the target spatial region in the game scene based on the target position, determine first position information when a virtual item enters the target spatial region and second position information when it leaves the target spatial region, and determine first audio data corresponding to the virtual item based on the first and second position information, where the first audio data is used to indicate the orientation change state of the virtual item during the process of moving from the first position information to the second position information. In other words, this disclosure acquires the orientation change state of the virtual item during the process of moving from the first position information to the second position information, transmits the first and second position information to an audio engine, and causes the audio engine to determine and play the first audio data corresponding to the virtual item, thereby providing a more accurate representation of the orientation of the virtual item through flight sound, and realizing a technical effect that further improves the audio playback effect in games, thereby solving the technical problem of poor audio playback effect in games.
[0056] The above method relating to the embodiment will be further described below.
[0057] In an optional embodiment, in step S206, determining the first position information when the virtual article enters the target spatial region and the second position information when it leaves the target spatial region includes determining the initial intersection point between the movement trajectory of the virtual article and the target spatial region, and determining the position information of the initial intersection point in the target spatial region as the first position information, and determining the final intersection point between the movement trajectory of the virtual article and the target spatial region, and determining the position information of the final intersection point in the target spatial region as the second position information.
[0058] In this embodiment, when the game engine determines the initial intersection point between the movement trajectory of a virtual object and the target spatial region, the position information of the initial intersection point in the target spatial region is determined, and the first position information is obtained. When the final intersection point between the movement trajectory of the virtual object and the target spatial region is determined, the position information of the final intersection point in the target spatial region is determined, and the second position information is obtained. Here, the intersection point may be any point on the surface of the target spatial region, and each point has corresponding coordinates. For example, if the target spatial region is a sphere, each point on the surface of the sphere has a precise coordinate intersection point.
[0059] The system optionally determines a target spatial region based on the target position where a virtual game character is located in a game scene. It acquires first position information when a virtual object enters the target spatial region and second position information when the virtual object leaves the target spatial region.
[0060] Optionally, the first and second position information may be converted into real-time control parameters (RTPCs), which may be named BulletWhoosh_Left_Right, BulletWhoosh_Front_Rear, and BulletWhoosh_Up_Down. After the virtual object passes through the target spatial region, the real-time control parameters generate corresponding numerical values and transmit them to the audio engine, which receives the first position information when the virtual object enters the target spatial region and the second position information when it leaves the target spatial region.
[0061] In an optional embodiment, determining first audio data corresponding to a virtual article based on first and second location information in step S208 includes determining first audio data based on first and second location information in response to the fact that neither of the first and second location information exceeds a target threshold.
[0062] In this embodiment, if neither the first position information nor the second position information exceeds the target threshold, the game engine can determine the first audio data based on the first position information and the second position information, where the target threshold may be a value set according to the target spatial region. For example, if the target spatial region is a spherical region, the target threshold may be the audible radius of the spherical region.
[0063] Optionally, if both the first and second position information in the game engine are within the target threshold, the first audio data is determined based on the first and second position information. For example, if a bullet passes through the audible range, the first audio data (sound effect of the bullet flying) is retrieved and played between the bullet's first position information (intersection where it enters the audible range) and the second position information (intersection where it leaves the audible range).
[0064] In an optional embodiment, the target spatial region is a spherical spatial region, and the method further includes determining the radius of the spherical spatial region as the target threshold.
[0065] In this embodiment, the target spatial region may be spherical, and the game engine may determine the radius of the spherical spatial region as the target threshold, where the target threshold may be represented by MAX.
[0066] As an optional embodiment, the radius of the spherical spatial region is adjusted in response to the first adjustment command.
[0067] In this embodiment, a first adjustment command can be issued on the game engine's settings screen, and in response to the first adjustment command, the radius of the spherical spatial region can be adjusted. Here, the first adjustment command may be used to adjust the size of a parameter on the settings screen, or to enlarge or reduce the radius of the spherical spatial region. The radius of the spherical spatial region may also be called the audible radius.
[0068] Optionally, a first adjustment command is input to the audible radius input component on the settings screen, and in response to the first adjustment command, the radius of the spherical spatial region is adjusted according to the parameter input by the first adjustment command.
[0069] As an optional embodiment, in step S208, obtaining a first distance between the movement trajectory of a virtual item and a virtual game character, and determining first audio data corresponding to the virtual item based on first position information and second position information, includes determining first audio data based on first position information, second position information and first distance.
[0070] In this embodiment, the audio engine receives a first distance between the movement trajectory of a virtual object and a virtual game character, and can determine first audio data based on first position information, second position information, and the first distance.
[0071] Optionally, a real-time control parameter for a first distance is synchronously established in the audio engine component and used to receive the first distance in the game engine, and first audio data is determined based on first position information, second position information and the first distance.
[0072] In an optional embodiment, determining first audio data based on first location information, second location information and first distance in step S208 includes determining first audio parameters corresponding to the first location information, second location information and first distance, and modulating a first audio sample based on the first audio parameters to obtain first audio data.
[0073] In this embodiment, the audio engine determines first audio parameters corresponding to first position information, second position information, and first distance, modulates a first audio sample based on the first audio parameters to obtain first audio data, where the first audio parameters may be real-time control parameters, and the first audio sample may be a sound sample selected from a database according to the actual situation.
[0074] Optionally, the audio engine associates a first audio sample with a first audio parameter to achieve modulation of audio data.
[0075] Optionally, the first audio parameter may include parameters for left-right, front-back, and up-down sound.
[0076] In an optional embodiment, determining first audio parameters corresponding to first position information, second position information, and first distance includes determining a corresponding left sound image parameter or a right sound image parameter based on a first coordinate of a first type in the first position information and a second coordinate of a first type in the second position information, respectively; determining a corresponding audio filter parameter based on a third coordinate of a second type in the first position information and a fourth coordinate of a second type in the second position information, respectively; and determining a volume parameter based on a first distance.
[0077] In this embodiment, the audio engine may associate a first audio sample with a first audio parameter, determine a corresponding left sound image parameter or a right sound image parameter based on a first coordinate of a first type in first position information and a second coordinate of a first type in second position information, determine a corresponding audio filter parameter based on a third coordinate of a second type in first position information and a fourth coordinate of a second type in second position information, and determine a volume parameter based on a first distance, where the left sound image parameter or the right sound image parameter may be used to control the fading of the left and right channels of sound and may be indicated by Pan, the audio filter parameter may be used to control the cutoff frequency band of a low-pass filter and may have a filtering effect that filters high frequencies and allows only low frequencies to pass through and may be indicated by Low Pass, and the volume parameter may be used to control the volume and may be indicated by Volume.
[0078] Optionally, as the first location information, second location information, and first distance constantly change, the audio parameters corresponding to the first location information, second location information, and first distance also constantly change.
[0079] In one selectable embodiment, the audio engine adjusts a first audio parameter to a second audio parameter in response to a second adjustment command.
[0080] In this embodiment, the audio engine can flexibly adjust the first audio parameter according to the actual situation and obtain an optimized second audio parameter.
[0081] In an optional embodiment, adjusting a first audio parameter to a second audio parameter in response to a second adjustment command includes triggering a second adjustment command in response to a first audio sample being replaced with a second audio sample, adjusting the first audio parameter to the second audio parameter, and modulating the second audio sample based on the second audio parameter to obtain second audio data.
[0082] In this embodiment, when the audio engine replaces the first audio sample with the second audio sample, it triggers a second adjustment command, adjusts the first audio parameter to the second audio parameter, modulates the second audio sample based on the second audio parameter, acquires the second audio data, and plays the second audio data.
[0083] If the audio sample of the bullet's flight sound is optionally replaced, it is necessary to re-verify whether the set first audio parameters are appropriate, especially if the length of the second audio sample differs significantly from that of the first audio sample. In such cases, the second audio sample is modulated based on the second audio parameters, a second audio data that fits the second audio sample is obtained, and the second audio data is played.
[0084] In an optional embodiment, obtaining a first distance between the movement trajectory of a virtual item and a virtual game character includes the audio engine obtaining a first distance transmitted by the game engine, and determining first audio data based on first position information, second position information and the first distance includes the audio engine obtaining first and second position information transmitted by the game engine and determining first audio data based on first position information, second position information and the first distance.
[0085] In this embodiment, in order to make the sound representation more realistic, a first distance may be obtained between the movement trajectory of a virtual object and a virtual game character, the game engine may transmit first position information, second position information and the first distance to the audio engine, the audio engine may obtain the first distance transmitted by the game engine, and the audio engine may determine first audio data based on the first position information, second position information and the first distance, where the first distance may be represented by BulletWhoosh_Distance, may be the vertical distance between the movement trajectory of a virtual object and a virtual game character, the first distance may not be divided into forward and outward, may not be a negative number, and the movement trajectory of a virtual object may be the trajectory of a virtual object.
[0086] Optionally, to influence the sound effects of virtual objects with respect to the vertical distance between the movement trajectory of the virtual object and the virtual game character, a first distance is obtained between the movement trajectory of the virtual object and the virtual game character, and the first position information, second position information, and the first distance are sent to the audio engine, achieving the objective that the smaller the first distance, the louder the volume, and the larger the first distance, the quieter the volume.
[0087] For example, to make sound effects sound more realistic, the volume of the bullet's flight sound is determined by the vertical distance between the trajectory and the listener. Specifically, by referencing a first distance represented by BulletWhoosh_Distance on the screen and transmitting the first position information, second position information, and the first distance to the audio engine, the objective is achieved that the closer the trajectory is to the listener, the louder the volume becomes, and conversely, the quieter the volume becomes.
[0088] In an optional embodiment, determining first audio data corresponding to a virtual item based on first and second location information in step S208 includes the game engine transmitting the first and second location information to the audio engine according to a target interval time, and the audio engine determining first audio data based on the first and second location information.
[0089] In this embodiment, the game engine may transmit first position information and second position information to the audio engine according to a target interval time, where the target interval time may be the time difference between the first position information and the second position information, the fade time from the starting value to the ending value, may be called the fade time, or may be the magnitude of the target interval time set according to the actual situation.
[0090] The system optionally determines the first and second location information, and at the same time inputs the magnitude of the fade time, which is set according to the actual situation, into the fade time component of the game engine. This allows the system to obtain a target interval time faded from the first location information to the second location information, and the game audio then transmits the first and second location information to the audio engine according to the target interval time.
[0091] In an optional embodiment, the game engine acquires at least one third location between a first location and a second location, and transmits the first and second location to the audio engine according to a target interval time, which includes the game engine sequentially transmitting the first location, each third location, and the second location to the audio engine within the target interval time, and the audio engine determines first audio data based on the first and second location information, which includes the audio engine determining first audio data based on the first location, each third location, and the second location information, where the first audio data is used to play audio having a fade playback state.
[0092] In this embodiment, the game engine acquires at least one third position information between the first position information and the second position information, and sequentially transmits the first position information, each of the third position information and the second position information to the audio engine within the target interval time, thereby achieving the objective that the first audio data played back by the audio engine has a fade playback state and transmits the first position information and the second position information to the audio engine according to the target interval time.
[0093] In an optional embodiment, the game engine determines a target interval time and transmits it to the audio engine, and the audio engine, in response to a third adjustment command, adjusts the target interval time and transmits the adjusted target interval time to the game engine.
[0094] In this embodiment, the game engine determines a target interval time, transmits the target interval time to the audio engine, receives first and second position information according to the target interval time, combines the sample lengths corresponding to the first and second position information, and the audio engine, in response to a third adjustment command, issues a third adjustment command to the target interval time, and adjusts the target interval time in response to the third adjustment command.
[0095] Optionally, the third adjustment command may be a command to adjust the parameter of the target interval time, and the appropriate target interval time is adjusted by combining the adjustment to the second audio with repeated listening.
[0096] As an optional embodiment, determining a target spatial region in a game scene based on a target position includes: determining a target coordinate system with the target position as the origin in the game scene; determining a spherical region in the target coordinate system with the origin as the origin and a radius of a second distance, wherein playback of audio data is permitted if the distance between a virtual item and a virtual game character is less than or equal to the second distance; and determining the spherical region as the target spatial region.
[0097] In this embodiment, a target coordinate system may be determined in the game scene based on the game engine, with the target position as the origin. In the target coordinate system, a spherical region may be determined with the origin as the center and a second distance as the radius, where the target position may be the center point, the coordinates of the target position may be (0,0,0), and the second distance may be the radius of the audible range of sound.
[0098] In an optional embodiment, a first coordinate of the first type in the first position information and a second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character; a third coordinate of the second type in the first position information and a fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character; and / or a fifth coordinate of the third type in the first position information and a sixth coordinate of the third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character.
[0099] In this embodiment, the first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character, where the first coordinate of the first type may be expressed as the left or right direction relative to the virtual game character, and the first coordinate may be expressed in base X, and the second coordinate of the first type may be expressed as the left or right direction relative to the virtual game character, and the second coordinate may be expressed in base X, and the first position information and the second position information may be obtained by a game engine.
[0100] Optionally, a third coordinate of the second type in the first position information and a fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character, where the third coordinate of the second type may be expressed in Y-direction and the fourth coordinate may be expressed in Y-out.
[0101] Optionally, a fifth coordinate of a third type in the first position information and a sixth coordinate of a third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character, where the fifth coordinate may be expressed in Z-direction and the sixth coordinate may be expressed in Z-out.
[0102] Optionally, the first coordinate of the first type in the first location information and the second coordinate of the first type in the second location information are required, and other directions may be selected according to the actual situation, that is, the third coordinate of the second type in the first location information, the fourth coordinate of the second type in the second location information, the fifth coordinate of the third type in the first location information, and the sixth coordinate of the third type in the second location information may be selected according to the actual situation.
[0103] In this embodiment, the target position where a virtual game character is located in a game scene is determined, a target spatial region is determined in the game scene based on the target position, first position information when a virtual object enters the target spatial region and second position information when it leaves the target spatial region are determined, and first audio data corresponding to the virtual object is determined based on the first and second position information, where the first audio data is used to indicate the orientation change state of the virtual object during the process of moving from the first position information to the second position information. In other words, this disclosure acquires the orientation change state of the virtual object during the process of moving from the first position information to the second position information, transmits the first and second position information to an audio engine, and causes the audio engine to determine and play the first audio data corresponding to the virtual object, thereby achieving a more accurate representation of orientation in the flight sound of the virtual object, further improving the audio playback effect in games, and solving the technical problem of poor audio playback effect in games.
[0104] The following describes the technical concepts of the embodiments of this disclosure more illustratively with reference to preferred embodiments. Specifically, the virtual auxiliary attack equipment will be described as ammunition.
[0105] The sound effect of a bullet flying refers to the very short "whoosh" sound that a person hears when a firearm is fired and the fired bullet suddenly flies close to their ear. This is an essential part of the complete firing sound in first-person and third-person shooting games. A good bullet flying sound effect enhances realism and spatiality in terms of artistic expression, appeals to artistic details, assists the player in perceiving threats in terms of functional expression, and further helps in combining other sounds and presented information in a game to determine the situation the player is in.
[0106] Currently, game production is becoming increasingly detailed and high-quality, and game sound designers are making the most of every opportunity to produce sound, conveying as much useful information as possible through sound and creating more pleasing sonic effects. However, conventional methods for realizing bullet flight sound effects are lacking in terms of artistic and functional expression.
[0107] From an artistic and functional standpoint, the sound effects of bullet flight in games need to be exaggerated. However, depending on factors such as the actual speed, volume, and acoustic principles of bullet flight, the sound of a real bullet can be determined to be very fast and very quiet. Even when bullets pass each other, the audible duration of the sound is very short, and it is difficult to notice under the cover of gunfire, making it difficult for the user to perceive properly. At the same time, it is impossible to process the sound effects of bullet flight in a way that mimics "a car passing by the listener with engine noise." While this might be more realistic, the bullet's speed is too fast, making it difficult to control the sound representation within a range that suits artistic and functional expression. Moreover, such rapid movement often requires the Doppler effect to enhance realism, increasing the difficulty of the task. Furthermore, considering current computer and game engine performance, the refresh rate of the game engine cannot keep up with the bullet's movement speed, making such processing methods unrealistic.
[0108] In related technologies, the sound effect of a projectile in flight is typically realized by a "simulation" method, where a scenario of a projectile flying nearby is simulated by virtually triggering a single trigger condition according to the formation of the projectile's trajectory. Specifically, each time the trajectory intersects with the edge of an artificially defined "audible range for projectile sound effects," the game engine notifies the audio engine that: a projectile sound should be played, and this sound should be played at that location.
[0109] Figure 3 is a schematic diagram of the trigger for the bullet flight sound effect in related technology 1. As shown in Figure 3, the black circles represent the audible range of the bullet flight sound effect, the horizontal lines with arrows indicate the trajectory of the bullet fired by the shooter, and the point where the two trajectories intersect is an intersection. Each time an "intersection" occurs, the time to "play the bullet flight sound" is triggered, and at the same time, the position information of the intersection is transmitted to the audio engine, so that the bullet flight sound with fixed position information can finally be heard. This position information is fixed from the time the intersection occurs, and audibly, this "position" may be obvious or not at all, depending on the setting of the stereo sound effect mixing ratio in the audio engine.
[0110] However, according to the above method, from the functional standpoint of the sound effect of a projectile in flight, the same intersection can correspond to multiple trajectories. For example, although the two shooters in Figure 3 are facing completely different directions, the location where the sound of the projectile in flight is generated is the intersection in both cases. Therefore, the sound of the projectile in flight does not serve to assist in determining direction and can sometimes be misleading. Ultimately, the tactical information obtained from the sound of the projectile in flight is only "someone is shooting at me," and the sound effect of the projectile in flight cannot be used to further assist in determining "from which direction the projectile came." From the perspective of artistic expression of bullet flight sound effects, Figure 4 is a schematic diagram of the waveform and sound image of bullet flight sound effects in related technology 1. As shown in Figure 4, throughout the entire process of phonation from the beginning to the end of the sound, the sound is present only in the right channel, and in a few processes the left and right channels phon simultaneously at different rates, but the sound image does not change further. In the process of a bullet flying, the bullet should be moving, and simply playing the bullet flight sound effect at a fixed position is insufficient to embody the movement of the bullet. The sound lacks a sense of space, cannot be made to sound real and pleasant, and does not sufficiently create a sense of realism and tension during battles in games.
[0111] In film and television productions, achieving such sound expression through linear editing is quite easy. In a digital audio workstation, the left / right sound image parameters (Pan) of the bullet's flight sound can be controlled by drawing an automated control information line segment (Automation) based on the screen display and scenario settings. However, in games, interactivity exists, and because the line segment is non-linear, it is not possible to predetermine where the "start and dead points" of this automated control information line segment are. Therefore, the "start and dead point" information is obtained in real time from the trajectory generated in real time using several methods, and this is used to influence the bullet's flight sound in real time.
[0112] In other words, if the game engine can send "start and dead point" information to the audio engine, the desired effect can be achieved by setting the audio engine to use this information to influence the parameters of the bullet flight sound sample. The "start and dead point" information needs to be recognized and used by the audio engine as a "control source" in numerical form. Since the control information in the audio engine is very well suited to transmitting "start and dead point" information, the "start and dead point" information can be converted into real-time control parameters in the audio engine to control the left / right sound image parameters, volume, low-pass filter, or any other parameters that you want to change in real time for the bullet flight sound sample.
[0113] Figure 5 is a schematic diagram of a trigger for the sound effect of a projectile in flight according to one embodiment of the present disclosure. As shown in Figure 5, the outermost circle indicates the audible range of the sound, and the coordinates of the two intersections, "advancing" and "leading," determine the change in the direction of the projectile's flight sound. Thus, each trajectory corresponds to only the direction of the shooter, as indicated by the arrows in Figure 5.
[0114] Figure 6 is a schematic diagram of the waveform and sound image table of the projectile flight sound effect when an enemy fires from the right to the left according to one embodiment of the present disclosure. As shown in Figure 6, the volume of the left and right channels of the entire sound production process can be faded, and as can be seen from the sound image tables of the beginning, middle, and end of the sound, a sound that moves from right to left can be obtained.
[0115] The above method of the embodiment will be further described below.
[0116] Figure 7 is a flowchart of an audio processing method in a game according to one embodiment of the present disclosure, and as shown in Figure 7, the method may include the following steps.
[0117] In step S701, the audible radius parameter is set with the listener as the center, and the spherical audible range is simulated.
[0118] Optionally, in the game engine, a coordinate system is simulated with the listener at its center, and the audible radius of the projectile's flight sound is set. This audible radius parameter needs to be exposed to the game engine for debugging. Figure 8 is a schematic diagram of the adjustment parameters according to one embodiment of the present disclosure. As shown in Figure 8, the audible radius and fade time length parameters can be set. Here, left / right, front / back, and up / down correspond to the X, Y, and Z axes of the coordinate system, respectively, the coordinates of the center point are (0, 0, 0), the right, front, and up of the listener are represented by positive numbers, and the left, rear, and down are represented by negative numbers. The units of the coordinates may be the same as the units of the distance at which they are placed.
[0119] Optionally, distance units may be set according to actual needs and can be understood as a correspondence between coordinates in the game scene and real-world units. For example, 175 represents 175 cm in reality, while 175 in other items may correspond to 175 mm or 175 light-years. Theoretically, any number in the game can represent any number in reality. For example, 3 represents 5 cm in reality, but this is not often done. Since thinking and converting is relatively cumbersome, each functional module should be unified to facilitate communication. For example, (-123, 0, 0) is best used to indicate that the listener is 123 cm to the left, not 123 m or 246 mm.
[0120] Optionally, a spherical "audible range of projectile flight sound" centered on the listener is simulated. Figure 9 is a schematic diagram of a spherical audible range with coordinate information attached to its surface according to one embodiment of the present disclosure. As shown in Figure 9, each point on the spherical surface can be represented by precise coordinates.
[0121] In step S702, the bullet passes through the audible range and generates coordinates.
[0122] In this embodiment, when a bullet passes through this "sphere" in the game engine, two sets of coordinates are generated: one set is the intersection with the sphere's surface when the bullet enters the sphere, and the other set is the intersection with the sphere's surface when the bullet leaves. The coordinates of the intersection when entering the sphere are (X-axis, Y-axis, Z-axis), and the coordinates of the intersection when leaving the sphere are (X-axis exit, Y-axis exit, Z-axis exit).
[0123] For example, if the listener is at the center of the sphere and facing directly towards the screen, and the set audible range radius is 300 (equivalent to 3 meters in a game scene), then the coordinate information generated by this trajectory may be X-axis = 290, Y-axis = 12, Z-axis = -5, X-out = -290, Y-out = -13, Z-out = 10.
[0124] In step S703, the fade time length parameter affects the real-time control parameter data, causing the advance value to fade to the output value.
[0125] In this embodiment, the game engine converts the X, Y, and Z axis coordinates into three sets of real-time control parameter (RTPC) data, which may be named, for example, BulletWhoosh_Left_Right, BulletWhoosh_Front_Rear, and BulletWhoosh_Up_Down.
[0126] Optionally, each time a bullet passes through the "audible range," these three sets of real-time control parameters simultaneously generate six numerical values and send them to the audio engine, including BulletWhoosh_Left_Right: X forward, X out; BulletWhoosh_Front_Rear: Y forward, Y out; BulletWhoosh_Up_Down: Z forward, Z out.
[0127] Optionally, at this time, the input and output values are sent to the audio engine simultaneously, and a time difference is required between the input and output values. Furthermore, a fade-out occurs between the input and output values. Therefore, a "fade time" is added to the real-time control parameters, and this parameter is exposed to the game engine, allowing for debugging according to the actual situation, as shown in Figure 8.
[0128] To achieve a more realistic representation, it may be necessary to add additional real-time control parameters. This parameter is named BulletWhoosh_Distance because the volume of the bullet's flight sound is affected by the vertical distance between the trajectory and the listener; the closer the trajectory is to the listener, the louder the sound becomes, and conversely, the quieter it becomes. Therefore, we can name this parameter BulletWhoosh_Distance, without separating it into forward and outgoing values, and without negative numbers.
[0129] In step S704, the event for the bullet flight sound effect is invoked.
[0130] In this embodiment, when a bullet passes through the "audible range" in the game engine, the game engine needs to invoke an event in the audio engine that "plays the sound effect of the bullet's flight".
[0131] To summarize, the program needs to do the following: each time a bullet "passes within audible range," the game engine invokes an event to "play the sound effect of the bullet's flight," and at the same time sends a total of seven numerical values for four sets of real-time control parameters to the audio engine, three of which have a fade effect.
[0132] First, the program has created real-time control parameters for three directions: left / right, front / back, and up / down. However, not all three of these need to be used. We have prepared ample ways to further optimize the extension and adapt it to different projects. For example, if there is rarely a large difference in height between friendly and enemy units, the BulletWhoosh_Up_Down real-time control parameter may not be necessary. Similarly, in a stereo environment, if there are not many audio parameters that are effective in distinguishing up and down, the BulletWhoosh_Up_Down real-time control parameter may not be necessary. However, the left / right real-time control parameters are essential and have the most pronounced effect, so at least the left / right RTPCs should be used in any item using this proposal.
[0133] The following provides a further explanation of the related configurations using two of these real-time control parameters: left / right and front / back.
[0134] In step S705, a sample of the sound effect of a projectile's flight is selected and modulated using real-time control parameters.
[0135] In this embodiment, Figure 10 is a schematic diagram of establishing real-time control parameters and setting attributes according to one embodiment of the present disclosure. As shown in Figure 10, three real-time control parameters, BulletWhoosh_Left_Right, BulletWhoosh_Front_Rear, and BulletWhoosh_Distance (the vertical real-time control parameter is omitted here), are established in the Game Syncs of the audio engine. The range values of the real-time control parameters are set to the range corresponding to the "audible radius". For example, if the "audible radius" is set to 300cm, the left / right and front / back values can be set from -300 to 300, and the distance can be set from 0 to 300. The default value can be any number.
[0136] Optionally, the default value may be a basic attribute input to establish a real-time control parameter in the audio engine. If the audio engine has not received a numerical value for the real-time control parameter, it will execute according to the default value. If the program is running correctly, it will receive the value provided by the game engine each time it is triggered and will not trigger the default value. However, to prevent frame loss due to stutter, for example, an intermediate value can be written as the default value, as shown in Figure 10.
[0137] Optionally, the selection and basic settings of bullet flight sound effect samples in the audio engine can use monaural samples. If stereo is used, samples with significant changes in sound image or large differences between left and right channels should not be used. This is a "pseudo-three-dimensional space (3D)" method, so the sample positioning attribute must be set to two-dimensional space (2D), and the speaker panning must be set to balance-fade mode. Figure 11(a) is a schematic diagram of the selection and basic settings of bullet flight sound effect samples according to one embodiment of this disclosure. As shown in Figure 11(a), balance-fade mode is selected based on the set positioning attribute and sample waveform. If there are multiple random samples, it is necessary to ensure that the length and dynamic changes of these samples are as close as possible. In this way, the "fade time length" parameter of the same set can be commonly applied. Furthermore, the longer the sample length, the easier it is to detect changes from left to right. Figure 11(b) is a schematic diagram of the waveform of a bullet flight sound effect sample according to one embodiment of the present disclosure. As shown in Figure 11(b), by applying the above settings to a sound sample selected as the target of the bullet flight sound effect, the waveform of the bullet flight sound effect sound sample shown in Figure 11(b) can be obtained.
[0138] Only in Balance-Fade mode can samples be selectively associated with real-time control parameters, and by associating samples with real-time control parameters, the left / right sound image parameters of stereo audio can be targeted for modulation.
[0139] Figure 12 is a schematic diagram relating a sample to an embodiment of the present disclosure to real-time control parameters, and as shown in Figure 12, it is set in the real-time control parameter tab for the playback target of the bullet flight sound. The left and right sound image parameters, the cutoff frequency band of the low-pass filter, and the volume parameter of the playback target are set as modulation targets, respectively, and furthermore, the bullet sound_left_right, bullet sound_front_rear, and the vertical distance between the trajectory and the listener are set as modulation sources, respectively, and finally a curve of the degree of influence of the real-time control parameter values on the parameters is set, where the cutoff frequency band of the low-pass filter is such that the larger the value, the more pronounced the "filtering" is, bullet sound_left_right controls the left and right sound image parameters of the stereo audio, and its role is to fade the left and right channels that the listener can hear when the bullet is flying left and right, bullet sound_front_rear controls the cutoff frequency band of the low-pass filter effect, and the vertical distance between the trajectory and the listener controls the volume, increasing the volume as the trajectory gets closer to the listener.
[0140] Optionally, the above settings have the effect of having no effect in front of the listener, being relatively clear in the background, but with relatively little influence from changes in distance. When the bullet flies from front to back, the sound becomes "loud and muffled," and when the bullet flies from back to front, the sound becomes "muffled and loud." Here, it is not necessary to represent the front and back using the effect of a low-pass filter; other effects can be substituted or combined, allowing for flexible processing. These parameter curves change as shown in Figure 12, and specifically, they can be flexibly adjusted according to actual needs and tuned to suit auditory perception.
[0141] If you choose to fire at an angle, the two real-time control parameters mentioned above will operate simultaneously.
[0142] In step S706, the parameters are checked again.
[0143] Two parameters are exposed in the game engine by default: "Audible Radius" and "Fade Time Length." The Audible Radius is debugged in conjunction with the real-time control parameter, and the Fade Time Length parameter needs to be repeatedly debugged to the optimal balance point in accordance with the curve of the real-time control parameter for sample length and the measured auditory perception. If the audio sample for the bullet flight sound is replaced, especially if the length of the new audio sample differs relatively significantly from the previous one, it is necessary to re-verify whether this parameter is appropriate.
[0144] In step S707, the game is executed.
[0145] You can run the game and feel the effects, and during this period, you can continue to fine-tune the sound parameters in the audio engine until the sound effects in the game engine reach their optimal level.
[0146] To improve both the artistic and functional representation of bullet flight sound effects, this disclosure provides a method for making "bullet flight sound as if it were moving along the path the bullet is flying," that is, giving the bullet flight sound accurate directional representation, for example, each time a bullet flies from directly to my right to directly to my left, what I hear is that the first half of the sound sample time is in the right channel and the second half is in the left channel, and this process changes gradually, thus matching the bullet's trajectory.
[0147] The above steps provide the fundamental information and data necessary to achieve the final effect, and this fundamental data is converted into real-time control parameters that can be directly used by the audio engine. The method of acquiring and using this real-time control parameter data is the most important and ingenious part of this embodiment, which allows the audio engine to closely correlate sound parameters with the in-game scenario, and further enables the target effect to be achieved through debugging and optimization of the parameters, allowing the player to intuitively feel the trajectory of the bullet flight through the sound effects of the bullet flight. This embodiment retains the basic functions of the bullet flight sound effects in the original technical proposal, namely the "threat of perception" and "enhancing the sense of presence," while further improving the auditory experience. It also adds a function to the bullet flight sound effects that assists in determining the direction of the shooter who is not in front of the player in any game item, ultimately improving the artistic and functional expression in an overall sense.
[0148] In this embodiment, a single coordinate system is simulated with the listener at the center, and the audible radius of the bullet's flight sound is set to obtain the audible range of the bullet's flight sound in a spherical shape centered on the listener. When the bullet passes through this sphere, two sets of coordinates are generated. Simultaneously, the game engine calls an audio command to "play the bullet's flight sound effect," converts the coordinate information into RTPC parameters, and sends it to the audio engine for recognition and use. In the game engine, the two sets of coordinate information and the audio information are associated, enabling debugging of audio samples based on the coordinate information, solving the technical problem of poor game sound effect effectiveness and achieving a technical effect of improving the effectiveness of game sound effects.
[0149] This embodiment also lays the foundation for real-time modulation of other sound parameters in an audio engine that are expected to be affected by the trajectory of a projectile, and has strong scalability and potential for evolution. For example, this approach is actually very suitable for multi-channel sound systems, and when applied to Dolby Atmos in the future, the value of this approach will be further enhanced and the advantages of multi-channel game sound systems will be fully realized by controlling the front-to-back sound image with front-to-back real-time control parameters and the up-to-down sound image with up-to-down real-time control parameters.
[0150] The embodiments of this disclosure further provide audio processing devices for games, which are for implementing the above embodiments and preferred embodiments, and omit what has already been described. As described below, the term "unit" can implement a combination of software and / or hardware with a predetermined function. The devices described in the following embodiments are preferably implemented in software, but hardware implementation or a combination of software and hardware implementation is also possible.
[0151] Figure 13 is a structural block diagram of an audio processing device in a game according to one embodiment of the present disclosure. As shown in Figure 13, the rendering time length determination device 1300 may include a first determination unit 1301, a second determination unit 1302, a third determination unit 1303, and a transmission unit 1304.
[0152] The first decision unit 1301 is configured to determine the target position in which a virtual game character is located in the game scene.
[0153] The second decision unit 1302 is configured to determine the target spatial region in the game scene based on the target position.
[0154] The third decision unit 1303 determines the first position information when the virtual item enters the target spatial region and the second position information when it leaves the target spatial region.
[0155] A fourth determination unit 1304 is configured to determine first audio data corresponding to a virtual item based on first and second location information, where the first audio data is used to indicate the orientation change state of the virtual item during its movement from the first location information to the second location information.
[0156] The third decision unit 1303 is configured to determine the initial intersection point between the movement trajectory of the virtual item and the target spatial region, and to determine the position information of the initial intersection point in the target spatial region as the first position information, and to determine the final intersection point between the movement trajectory of the virtual item and the target spatial region, and to determine the position information of the final intersection point in the target spatial region as the second position information.
[0157] The third decision unit 1303 is configured to determine first audio data based on the first and second location information in response to the fact that neither the first nor the second location information exceeds a target threshold.
[0158] The third decision unit 1303 is configured to determine that the target spatial region is a spherical spatial region and that the radius of the spherical spatial region is the target threshold.
[0159] The third decision unit 1303 is configured to adjust the radius of the spherical spatial region in response to the first adjustment command.
[0160] The fourth decision unit 1304 is configured to obtain a first distance between the movement trajectory of a virtual item and a virtual game character, and to determine first audio data based on the first position information, the second position information, and the first distance.
[0161] The fourth decision unit 1304 is configured to determine first audio parameters corresponding to first location information, second location information, and first distance, and to modulate a first audio sample based on the first audio parameters to obtain first audio data.
[0162] The fourth determination unit 1304 is configured to determine a corresponding left sound image parameter or a right sound image parameter based on a first coordinate of a first type in the first position information and a second coordinate of a first type in the second position information, respectively, to determine a corresponding audio filter parameter based on a third coordinate of a second type in the first position information and a fourth coordinate of a second type in the second position information, respectively, and to determine a volume parameter based on a first distance.
[0163] The fourth decision unit 1304 is configured to adjust the first audio parameter to the second audio parameter in response to the second adjustment command.
[0164] The fourth decision unit 1304 is configured to trigger a second adjustment command in response to the first audio sample being replaced with a second audio sample, adjust the first audio parameter to the second audio parameter, modulate the second audio sample based on the second audio parameter, and obtain second audio data.
[0165] Optionally, the audio engine obtains a first distance transmitted by the game engine, obtains a first position and a second position transmitted by the game engine, and determines first audio data based on the first position, the second position and the first distance.
[0166] Optionally, the game engine transmits first and second location information to the audio engine according to a target interval time, and the audio engine determines first audio data based on the first and second location information.
[0167] Optionally, the game engine acquires at least one third location between a first location and a second location, and within a target interval time, the game engine sequentially transmits the first location, each third location, and the second location to the audio engine, which determines first audio data based on the first location, each third location, and the second location, where the first audio data is used to play audio having a fade playback state.
[0168] Optionally, the game engine determines a target interval time and sends it to the audio engine. The audio engine, in response to a third adjustment command, adjusts the target interval time and sends the adjusted target interval time to the game engine.
[0169] The second decision unit 1302 is configured to determine a target coordinate system in the game scene with the target position as the origin, and to determine a spherical region in the target coordinate system with the origin as the center and a second distance as the radius. If the distance between the virtual object and the virtual game character is less than or equal to the second distance, it allows playback of audio data and determines the spherical region as the target spatial region.
[0170] Optionally, the first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character; the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character; and / or the fifth coordinate of the third type in the first position information and the sixth coordinate of the third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character.
[0171] In this embodiment, a first determination unit determines the target position where a virtual game character is located in a game scene, a second determination unit determines the target spatial region in the game scene based on the target position, a third determination unit determines first position information when a virtual object enters the target spatial region and second position information when it leaves the target spatial region, and a fourth determination unit determines first audio data corresponding to the virtual object based on the first and second position information, where the first audio data is used to indicate the orientation change state of the virtual object during the process of moving from the first position information to the second position information. In other words, this disclosure acquires the orientation change state of a virtual object during the process of moving from the first position information to the second position information, transmits the first and second position information to an audio engine, and causes the audio engine to determine and play the first audio data corresponding to the virtual object, thereby achieving a more accurate representation of orientation with the flight sound of the virtual object and further improving the audio playback effect in games, thereby solving the technical problem of poor audio playback effect in games.
[0172] Each of the above units may be implemented by software or hardware, and the latter can be implemented in the following ways, but is not limited to these, and each of the above units may be located on the same processor, or each of the above units may be located on different processors in any combination.
[0173] Embodiments of the present disclosure further provide a computer-readable storage medium that stores a computer program configured, when executed by a processor, to perform an audio processing method in a game of the embodiment of the present disclosure.
[0174] Optionally, in this embodiment, the computer-readable storage medium may be configured to store a computer program for performing the following steps.
[0175] In S1, the target position where the virtual game character is located in the game scene is determined.
[0176] In S2, the target spatial area in the game scene is determined based on the target position.
[0177] In S3, the first position information of the virtual item when it enters the target spatial region and the second position information when it leaves the target spatial region are determined.
[0178] In S4, first audio data corresponding to the virtual item is determined based on the first and second location information, and the first audio data is used to indicate the change in orientation of the virtual item during the process of moving from the first location information to the second location information.
[0179] The above computer-readable storage medium may be further configured to store a computer program for performing the following steps.
[0180] The initial intersection point between the virtual object's movement trajectory and the target spatial region is determined, and the position information of the initial intersection point in the target spatial region is determined as the first position information. The final intersection point between the virtual object's movement trajectory and the target spatial region is determined, and the position information of the final intersection point in the target spatial region is determined as the second position information.
[0181] In response to the fact that neither the first nor the second location information exceeds the target threshold, the first audio data is determined based on the first and second location information.
[0182] The target spatial region is a spherical spatial region, and the radius of the spherical spatial region is determined as the target threshold.
[0183] In response to the first adjustment command, the radius of the spherical spatial region is adjusted.
[0184] The system obtains a first distance between the movement trajectory of a virtual object and a virtual game character, and determines first audio data based on the first position information, the second position information, and the first distance.
[0185] A first audio parameter is determined corresponding to the first location information, the second location information, and the first distance. A first audio sample is modulated based on the first audio parameter, and first audio data is obtained.
[0186] Based on the first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information, the corresponding left sound image parameter or right sound image parameter is determined; based on the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information, the corresponding audio filter parameter is determined; and based on the first distance, the volume parameter is determined.
[0187] In response to the second adjustment command, the first audio parameter is adjusted to the second audio parameter.
[0188] In response to the first audio sample being replaced with the second audio sample, a second adjustment command is triggered, adjusting the first audio parameter to the second audio parameter, modulating the second audio sample based on the second audio parameter, and obtaining the second audio data.
[0189] The audio engine obtains a first distance transmitted by the game engine, obtains a first position and a second position transmitted by the game engine, and determines the first audio data based on the first position, the second position and the first distance.
[0190] The game engine transmits first and second location information to the audio engine according to the target interval time, and the audio engine determines first audio data based on the first and second location information.
[0191] The game engine acquires at least one third location between the first and second location information, and within a target interval time, the game engine sequentially transmits the first location information, each of the third location information and the second location information to the audio engine, and the audio engine determines first audio data based on the first location information, each of the third location information and the second location information, where the first audio data is used to play audio having a fade playback state.
[0192] The game engine determines the target interval time and sends it to the audio engine. The audio engine, in response to a third adjustment command, adjusts the target interval time and sends the adjusted target interval time back to the game engine.
[0193] In the game scene, a target coordinate system is determined with the target position as the origin. Within this target coordinate system, a spherical region is determined with the origin as the center and a radius equal to a second distance. If the distance between the virtual object and the virtual game character is less than or equal to the second distance, audio data playback is permitted, and the spherical region is determined as the target spatial region.
[0194] The first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character; the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character; and / or the fifth coordinate of the third type in the first position information and the sixth coordinate of the third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character.
[0195] This disclosure acquires the orientation change state of a virtual object during the process of moving from a first location to a second location, transmits the first and second location information to an audio engine, and causes the audio engine to determine and play first audio data corresponding to the virtual object. This results in a more accurate representation of the orientation of the flight sound of the virtual object, improving the audio playback effect in games and solving the technical problem of poor audio playback in games.
[0196] Optionally, in this embodiment, the computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory (ROM), random access memory (RAM), removable hard disks, disks, or CD-ROMs.
[0197] According to one embodiment of the present disclosure, a processor is further provided, which is configured to execute a program, which, when executed by the processor, executes an audio processing method in a game according to an embodiment of the present disclosure.
[0198] Embodiments of the present disclosure further provide electronic devices, and Figure 14 is a structural block diagram of an electronic device according to an embodiment of the present disclosure, as shown in Figure 14, the electronic device includes memory and a processor, the memory storing a computer program, and the processor is configured to execute the computer program and perform the steps in any of the embodiments of the above method.
[0199] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.
[0200] Optionally, in this embodiment, the processor may be configured to perform the following steps by a computer program.
[0201] In S1, the target position where the virtual game character is located in the game scene is determined.
[0202] In S2, the target spatial area in the game scene is determined based on the target position.
[0203] In S3, the first position information of the virtual item when it enters the target spatial region and the second position information when it leaves the target spatial region are determined.
[0204] In S4, first audio data corresponding to the virtual item is determined based on the first and second location information, and the first audio data is used to indicate the change in orientation of the virtual item during the process of moving from the first location information to the second location information.
[0205] The above processor may be configured to perform the following steps by a computer program.
[0206] The initial intersection point between the virtual object's movement trajectory and the target spatial region is determined, and the position information of the initial intersection point in the target spatial region is determined as the first position information. The final intersection point between the virtual object's movement trajectory and the target spatial region is determined, and the position information of the final intersection point in the target spatial region is determined as the second position information.
[0207] In response to the fact that neither the first nor the second location information exceeds the target threshold, the first audio data is determined based on the first and second location information.
[0208] The target spatial region is a spherical spatial region, and the radius of the spherical spatial region is determined as the target threshold.
[0209] In response to the first adjustment command, the radius of the spherical spatial region is adjusted.
[0210] The first distance between the movement trajectory of a virtual object and a virtual game character is obtained. Based on the first position information, the second position information, and the first distance, first audio data is determined.
[0211] A first audio parameter is determined corresponding to the first location information, the second location information, and the first distance. A first audio sample is modulated based on the first audio parameter, and the first audio data is obtained.
[0212] Based on the first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information, the corresponding left sound image parameter or right sound image parameter is determined, and based on the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information, the corresponding audio filter parameter is determined. The volume parameter is determined based on the first distance.
[0213] In response to the second adjustment command, the first audio parameter is adjusted to the second audio parameter.
[0214] In response to the first audio sample being replaced with the second audio sample, a second adjustment command is triggered, adjusting the first audio parameter to the second audio parameter, modulating the second audio sample based on the second audio parameter, and obtaining the second audio data.
[0215] The audio engine obtains a first distance transmitted by the game engine, obtains a first position and a second position transmitted by the game engine, and determines the first audio data based on the first position, the second position and the first distance.
[0216] The game engine transmits first and second location information to the audio engine according to the target interval time, and the audio engine determines first audio data based on the first and second location information.
[0217] The game engine acquires at least one third location between the first and second location information, and within a target interval time, the game engine sequentially transmits the first location information, each of the third location information and the second location information to the audio engine, and the audio engine determines first audio data based on the first location information, each of the third location information and the second location information, where the first audio data is used to play audio having a fade playback state.
[0218] The game engine determines the target interval time and sends it to the audio engine. The audio engine, in response to a third adjustment command, adjusts the target interval time and sends the adjusted target interval time back to the game engine.
[0219] In the game scene, a target coordinate system is determined with the target position as the origin. Within this target coordinate system, a spherical region is determined with the origin as the center and a radius equal to a second distance. If the distance between the virtual object and the virtual game character is less than or equal to the second distance, audio data playback is permitted, and the spherical region is determined as the target spatial region.
[0220] The first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character; the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character; and / or the fifth coordinate of the third type in the first position information and the sixth coordinate of the third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character.
[0221] This disclosure acquires the orientation change state of a virtual object during the process of moving from a first location to a second location, transmits the first and second location information to an audio engine, and causes the audio engine to determine and play first audio data corresponding to the virtual object. This results in a more accurate representation of orientation in the flight sound of the virtual object, and further improves the audio playback effect in games, thereby solving the technical problem of poor audio playback effect in games.
[0222] Optionally, specific examples in this embodiment can refer to examples described in the above embodiment and in selectable embodiments, and in this embodiment, such descriptions are omitted here.
[0223] The above numbering of the embodiments in this disclosure is for illustrative purposes only and does not represent the advantages or disadvantages of the embodiments.
[0224] In the embodiments of this disclosure described above, each embodiment is described in detail, and any part not described in detail in one embodiment can be found in the relevant description of another embodiment.
[0225] Furthermore, in some embodiments provided by this disclosure, the disclosed technical content should be considered as being implementable in other ways. Herein, the embodiments of the apparatus described above are merely schematic, and for example, the division of units described, which can be a logical functional division, can actually be implemented in other ways, for example, by combining multiple units or components, or by incorporating them into another system, or by ignoring or not implementing some functions. In other words, the mutual coupling, direct coupling or communication connection illustrated or discussed can be via some interface, indirect coupling or communication connection of the units or modules, which may be electrical or otherwise.
[0226] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed among multiple units. Some or all of these units may be selected according to practical needs to achieve the objectives of this embodiment solution.
[0227] Furthermore, each functional unit in the various embodiments of this disclosure may be integrated into a single processing unit, the individual units may exist physically separately, or two or more units may be integrated into a single unit. The integrated unit may be implemented in hardware form or in the form of a software functional unit.
[0228] The integrated unit may be implemented as a software functional unit and, if sold or used as a standalone product, may be stored on a computer-readable storage medium. It is understood that some or all or part of the technical solutions of this disclosure, or technical solutions that are essentially contributing to related technologies, may be embodied in the form of a software product stored on a storage medium containing a number of instructions that enable a computer device (which may be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in various embodiments of this disclosure. Examples of such storage mediums include USB flash drives, read-only memory (ROM), random access memory (RAM), removable hard disks, disks, or CD-ROMs, which are media capable of storing program code.
[0229] The foregoing are merely preferred embodiments of the present disclosure, and those skilled in the art can make several improvements and modifications without departing from the principles of the present disclosure, and these improvements and modifications should also be considered within the scope of the present disclosure.
Claims
1. In a game scene, this involves determining the target position where a virtual game character is located, Based on the aforementioned target position, the target spatial region in the game scene is determined, To determine the first position information of the virtual item when it enters the target spatial area and the second position information when it leaves the target spatial area, The method includes determining first audio data corresponding to the virtual item based on the first location information and the second location information, wherein the first audio data is used to indicate the change in orientation of the virtual item during the process of moving from the first location information to the second location information. A method for processing audio in games, characterized by the following features.
2. Determining the first position information of the virtual item when it enters the target spatial region and the second position information when it leaves the target spatial region is: The initial intersection point between the movement trajectory of the virtual object and the target spatial region is determined, and the positional information of the initial intersection point in the target spatial region is determined as the first positional information. This includes determining the endpoint intersection point between the movement trajectory of the virtual item and the target spatial region, and determining the positional information of the endpoint intersection point in the target spatial region as the second positional information. The audio processing method in a game according to feature 1.
3. Determining the first audio data corresponding to the virtual item based on the first and second location information is: The process includes determining the first audio data based on the first and second location information in response to the fact that neither the first nor the second location information exceeds a target threshold. The audio processing method in a game according to feature 1.
4. The aforementioned target spatial region is a spherical spatial region, and the method is The further includes determining the radius of the spherical spatial region as the target threshold. The audio processing method in a game according to feature 3.
5. Further includes adjusting the radius of the spherical spatial region in response to a first adjustment command. The audio processing method in a game according to feature 4.
6. The method further includes obtaining a first distance between the movement trajectory of the virtual item and the virtual game character, Determining first audio data corresponding to the virtual article based on the first location information and the second location information includes determining the first audio data based on the first location information, the second location information and the first distance. The audio processing method in a game according to feature 1.
7. Determining the first audio data based on the first location information, the second location information, and the first distance is: Determining a first audio parameter corresponding to the first position information, the second position information, and the first distance, This includes modulating a first audio sample based on the first audio parameter to obtain the first audio data. The audio processing method in a game according to feature 6.
8. Determining the first audio parameter corresponding to the first position information, the second position information, and the first distance is: Based on the first coordinates of the first type in the first position information and the second coordinates of the first type in the second position information, the corresponding left sound image parameter or right sound image parameter is determined. Each of the following is determined based on the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information, and This includes determining volume parameters based on the first distance. The audio processing method in a game according to feature 7.
9. The process further includes adjusting the first audio parameter to the second audio parameter in response to a second adjustment command. The audio processing method in a game according to feature 7.
10. Adjusting the first audio parameter to the second audio parameter in response to a second adjustment command is: The process includes triggering the second adjustment command in response to the first audio sample being replaced with the second audio sample, and adjusting the first audio parameter to the second audio parameter. The method further includes modulating the second audio sample based on the second audio parameter to obtain second audio data. The audio processing method in a game according to feature 9.
11. Obtaining a first distance between the movement trajectory of the virtual item and the virtual game character includes the audio engine obtaining the first distance transmitted by the game engine, Determining the first audio data based on the first location information, the second location information, and the first distance includes the audio engine acquiring the first location information and the second location information transmitted by the game engine, and determining the first audio data based on the first location information, the second location information, and the first distance. The audio processing method in a game according to feature 6.
12. Determining the first audio data corresponding to the virtual item based on the first and second location information is: The game engine transmits the first position information and the second position information to the audio engine according to the target interval time. The audio engine includes determining the first audio data based on the first location information and the second location information. The audio processing method in a game according to feature 1.
13. The game engine further includes obtaining at least one third location between the first location and the second location, The game engine transmitting the first location information and the second location information to the audio engine according to the target interval time includes the game engine sequentially transmitting the first location information, each of the third location information and the second location information to the audio engine within the target interval time. The audio engine determining the first audio data based on the first and second location information includes the audio engine determining the first audio data based on the first location information, each of the third and second location information, wherein the first audio data is used to play audio having a fade playback state. The audio processing method in a game according to feature 12.
14. The game engine determines the target interval time and transmits the target interval time to the audio engine. The audio engine further includes adjusting the target interval time in response to a third adjustment command and transmitting the adjusted target interval time to the game engine. The audio processing method in a game according to feature 12.
15. Determining the target spatial region in the game scene based on the aforementioned target position means that In the aforementioned game scene, the objective coordinate system is determined with the objective position as the origin, In the aforementioned target coordinate system, a spherical region is determined with the origin as the center and a second distance as the radius, and if the distance between the virtual item and the virtual game character is less than or equal to the second distance, playback of audio data is permitted. This includes determining the aforementioned spherical region as the target spatial region. The audio processing method for a game according to any one of claims 1 to 14.
16. The first coordinate of the first type in the first position information and the second coordinate of the first type in the second position information are used to indicate the left or right direction relative to the virtual game character; the third coordinate of the second type in the first position information and the fourth coordinate of the second type in the second position information are used to indicate the forward or backward direction relative to the virtual game character; and / or the fifth coordinate of the third type in the first position information and the sixth coordinate of the third type in the second position information are used to indicate the upward or downward direction relative to the virtual game character. The audio processing method for a game according to any one of claims 1 to 14.
17. An audio processing device for a game comprising a first decision unit, a second decision unit, a third decision unit, and a fourth decision unit, The first determination unit is configured to determine the target position in which a virtual game character is located in a game scene. The second decision unit is configured to determine the target spatial region in the game scene based on the target position, The third decision unit is configured to determine a first position information when the virtual item enters the target spatial region and a second position information when it leaves the target spatial region. The fourth determination unit is configured to determine first audio data corresponding to the virtual item based on the first and second location information, and the first audio data is used to indicate the orientation change state of the virtual item during the process of moving from the first location information to the second location information. An audio processing device for games, characterized by the following features.
18. A computer program configured to perform the method described in any one of claims 1 to 14 is stored when executed by the processor. A computer-readable storage medium characterized by the following features.
19. An electronic device comprising memory and a processor, A computer program is stored in the memory, and the processor executes the computer program to perform the method according to any one of claims 1 to 14. An electronic device characterized by the following features.