Interaction method and device, equipment and storage medium
By identifying the movement information of key points of the user's body, determining audio files and generating multimedia files, it solves the problem of high cost and poor performance for amateur users playing physical instruments, realizes diversified interactions with smart terminals, and improves user experience.
Patent Information
- Application Number
- CN202310215027.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-28
- Publication Date
- 2024-08-30
AI Technical Summary
It is costly and ineffective for amateur users to experience playing physical instruments, and smart terminals cannot effectively meet the diverse interaction needs of users.
By identifying the motion information of key points of the user's body, determining audio files and generating multimedia files, joint control of sound and images is achieved, and the diversity of interactions between users and smart terminals is improved.
It realizes diversified interactions between users and smart terminals, reduces performance costs, and enhances experience.
Smart Images

Figure CN118567468A
Abstract
Description
Technical Field
[0001] The embodiments of the present disclosure relate to the field of intelligent terminal technology, and in particular to an interaction method, device, equipment and storage medium. Background Art
[0002] Music performance is usually performed by playing a physical instrument, and a person can usually only play one instrument at a time. For amateur users, the cost of experiencing playing a physical instrument is high, and the effect desired by the user cannot be achieved.
[0003] Smart terminals have become one of the indispensable entertainment tools in users' lives, such as listening to music, watching short videos, generating special effects pictures, etc. Among them, playing various musical instruments through smart terminals is favored by the majority of users. Summary of the invention
[0004] The embodiments of the present disclosure provide an interaction method, apparatus, device and storage medium, which can control the playback of audio and the transformation of images through the movement of key points of the user's body, thereby improving the diversity of the interaction between the user and the smart terminal.
[0005] In a first aspect, an embodiment of the present disclosure provides an interaction method, including:
[0006] Identify the motion information of at least one key point of the body of the target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen;
[0007] Determine an audio file according to the key points of the body and the motion information;
[0008] Acquire a target image, and generate a multimedia file according to the target image and the audio file;
[0009] Control the multimedia file to play.
[0010] In a second aspect, the present disclosure also provides an interactive device, including:
[0011] A motion information recognition module, used to recognize motion information of at least one key point of the target user's body; wherein the motion information includes motion speed and / or coordinates of the key point of the body on the screen;
[0012] An audio file determination module, used to determine an audio file according to the key points of the body and the motion information;
[0013] A multimedia file generation module, used for acquiring a target image and generating a multimedia file according to the target image and the audio file;
[0014] The control module is used to control the multimedia file to be played.
[0015] In a third aspect, an embodiment of the present disclosure further provides an electronic device, the electronic device comprising:
[0016] one or more processors;
[0017] a storage device for storing one or more programs,
[0018] When the one or more programs are executed by the one or more processors, the one or more processors implement the interaction method as described in the embodiment of the present disclosure.
[0019] In a fourth aspect, an embodiment of the present disclosure further provides a storage medium comprising computer executable instructions, which, when executed by a computer processor, are used to execute the interaction method as described in the embodiment of the present disclosure.
[0020] The disclosed embodiments disclose an interactive method, device, equipment and storage medium, which can identify the motion information of at least one key point of the body of a target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen; determine the audio file according to the key point of the body and the motion information; obtain the target image, generate a multimedia file according to the target image and the audio file; and control the multimedia file to play. The interactive method provided by the disclosed embodiments determines the audio file through the key point of the body and the motion information, and generates the multimedia file according to the target image and the audio file, so as to realize the joint control of sound and image and improve the diversity of the interaction between the user and the smart terminal. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.
[0022] Figure 1 is a flowchart of an interactive method provided by an embodiment of the present disclosure;
[0023] Figure 2 is an example diagram of dividing a screen into multiple areas provided by an embodiment of the present disclosure;
[0024] Figure 3 is an example diagram of a processed image provided by an embodiment of the present disclosure;
[0025] Figure 4 is a schematic diagram of an interactive method provided by an embodiment of the present disclosure;
[0026] Figure 5is a structural schematic diagram of an interactive device provided by an embodiment of the present disclosure;
[0027] Figure 6 It is a structural schematic diagram of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION
[0028] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0029] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0030] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.
[0031] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0032] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0033] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0034] It is understandable that before using the technical solutions disclosed in the embodiments of the present disclosure, the types, scope of use, usage scenarios, etc. of the personal information involved in the present disclosure should be informed to the user and the user's authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.
[0035] For example, in response to receiving an active request from a user, a prompt message is sent to the user to clearly prompt the user that the operation requested to be performed will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as an electronic device, application, server, or storage medium that performs the operation of the technical solution of the present disclosure according to the prompt message.
[0036] As an optional but non-limiting implementation, in response to receiving an active request from the user, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the electronic device.
[0037] It is understandable that the above notification and the process of obtaining user authorization are merely illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet the relevant laws and regulations may also be applied to the implementation of the present disclosure.
[0038] It is understandable that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.
[0039] Figure 1 This is a flow chart of an interactive method provided in an embodiment of the present disclosure. The embodiment of the present disclosure is applicable to the situation of interactive control of a smart terminal. The method can be executed by an interactive device, which can be implemented in the form of software and / or hardware. Optionally, it can be implemented by an electronic device, which can be a mobile terminal, a PC or a server, etc.
[0040] like Figure 1 As shown, the method includes:
[0041] S110, identifying motion information of at least one key point of the target user's body.
[0042] Wherein, the motion information may include motion speed and / or coordinates of body key points in the screen, and the coordinates of body key points in the screen may be understood as 2D coordinates of body key points in the terminal screen. Body key points may include facial key points and limb key points. At least one body key point may be one or more body key points that are pre-set, and exemplary, taking three body key points as an example, may be set to nose tip key points, left hand key points and right hand key points. The present embodiment does not limit the number and category of body key points.
[0043] Specifically, the process of identifying the motion information of at least one body key point of the target user can be: obtaining the 3D coordinates of at least one body key point of the target user in the previous frame and the 3D coordinates of the current frame; determining the motion speed of the body key point according to the 3D coordinates of the previous frame and the 3D coordinates of the current frame; and converting the 3D coordinates of the current frame into 2D coordinates on the screen.
[0044] Among them, 3D coordinates can be understood as the three-dimensional coordinates of the key points of the body in the world coordinate system. In this embodiment, any existing posture estimation algorithm can be used to obtain the 3D coordinates of at least one key point of the body in the world coordinate system in real time. For each key point of the at least one key point of the body, the 3D coordinates of the key point of the body in the previous frame and the 3D coordinates of the current frame are obtained, and then the movement distance of the key point of the body in the two adjacent frames is calculated, and the movement distance is divided by the time interval of the two adjacent frames to obtain the movement speed of the key point of the body. Specifically, the process of converting the 3D coordinates of the current frame into the 2D coordinates in the screen can be: first determine the conversion relationship between the world coordinate system and the screen coordinate system, and then convert the 3D coordinates of the current frame into the 2D coordinates in the screen according to the conversion relationship, that is, obtain the position information of the key point of the body in the screen. In this embodiment, the movement speed and the 2D coordinates in the screen are determined by the 3D coordinates of the key points of the body, which can improve the accuracy of the movement information determination to ensure the accuracy of the subsequent interactive control.
[0045] S120, determining an audio file according to the key points of the body and the motion information.
[0046] The audio file may be a pre-stored sound file. In this embodiment, the audio file may be a file composed of music elements included in the sound type, and the music element may be understood as a specific sound that can be produced by simulating the pronunciation of a musical instrument or by recording the sound produced when playing a musical device.
[0047] Specifically, the method of determining the audio file based on the body key points and motion information can be: obtaining the sound type corresponding to the body key points; determining the regional position of the body key points on the screen based on the coordinates of the body key points on the screen; and determining the audio file based on the regional position and the sound type.
[0048] Among them, the sound type includes multiple music elements, and the audio file is composed of music elements. The sound type can correspond to the sound emitted by a musical device. Exemplarily, assuming that the musical device is a piano, the audio file can be a file composed of the notes emitted by each key of the piano; if the musical device is a string instrument, the audio file can be a file composed of the notes emitted by each string position of the string instrument. Reference can be made to the pronunciation rules and principles of each musical device. In this embodiment, it is necessary to establish a correspondence between body key points and sound types in advance. For example, assuming that there are three body key points, namely the nose tip key point, the left hand key point and the right hand key point, and the three sound types set are piano sound, drum sound and guitar sound, respectively, then the established correspondence can be: the nose tip key point corresponds to the piano sound, the left hand key point corresponds to the drum sound, and the right hand key point corresponds to the guitar sound.
[0049] In this embodiment, the corresponding relationship between each audio file of a certain sound type and each area in the terminal screen can be pre-established. The process of determining the audio file according to the area position and the sound type can be: first obtain multiple audio files corresponding to the sound type, and then determine the audio file corresponding to the sound type at the area position. In this embodiment, the corresponding audio file can be accurately determined by the coordinates of the key points of the body on the screen.
[0050] Optionally, before determining the audio file based on the body key points and movement information, the following steps are also included: constructing a correspondence between the body key points and the sound type; dividing the screen into multiple areas; and constructing a correspondence between multiple audio files corresponding to the multiple areas and the body key points.
[0051] Among them, constructing the correspondence between body key points and sounds can be understood as associating body key points with sound types, which can be achieved by: establishing a correspondence table between body key points and sound types, or adding identification information of body key points in the audio file corresponding to the sound type.
[0052] Among them, an area contains multiple pixels, and the number of divided areas corresponds to the number of musical elements contained in the sound type. For example: a piano contains 88 keys, so the screen can be divided into 88 areas, and one area corresponds to an audio file of one key. For a certain sound type, the audio file of the sound type can be in a one-to-one correspondence with the area. For example, Figure 2 is an example diagram of dividing the screen into multiple areas in this embodiment, such as Figure 2As shown, the screen is divided into 4*8=32 different areas, and a serial number is set for each area, and then the audio files of the sound types corresponding to the key points of the body are mapped one by one to the different areas. Specifically, the way to construct the correspondence between multiple areas and multiple audio files of sound can be: establish a correspondence table of the audio files corresponding to the areas and the key points of the body; or, add the identification of the corresponding area to the audio file, and the identification of the area can be represented by the serial number. In this embodiment, the correspondence between multiple areas and multiple audio files corresponding to the key points of the body is constructed. When the key points of the body are detected, the corresponding audio files can be quickly determined, thereby improving the response speed of the interaction.
[0053] Optionally, the method of constructing the correspondence between multiple regions and multiple audio files corresponding to body key points can be: sorting the multiple regions according to position information; sorting the multiple audio files corresponding to the body key points according to the scale; and constructing the correspondence between the sorted multiple regions and the sorted audio files.
[0054] Among them, the method of sorting multiple areas according to position information can be: sorting in the direction of up and down, left and right. The direction of up and down includes from top to bottom or from bottom to top; the direction of left and right includes from left to right or from right to left. For example: sorting in the order from top to bottom, from left to right; or, sorting in the order from bottom to top, from right to left, etc. And set serial numbers for the sorted areas. The method of sorting multiple audio files according to the scale can be: sorting in the order from high to low or from low to high according to the scale, and setting serial numbers for the sorted audio files. The method of constructing the correspondence between the sorted multiple areas and the sorted audio files can be: establishing a correspondence between the areas with the same sorting and the audio files. In this embodiment, the correspondence between the sorted multiple areas and the sorted audio files is constructed to prevent the user from controlling the sound to be chaotic, making the sound more regular and improving the auditory experience.
[0055] S130, acquiring a target image, and generating a multimedia file according to the target image and the audio file.
[0056] The target image may be an original image, or an image further processed from the original image. The original image may be an image collected by the terminal in real time, or a video image or a static image obtained from a database.
[0057] Specifically, the target image may be obtained by: determining the adjustment amount of the image parameter according to the motion information; and processing the original image according to the adjustment amount to obtain the target image.
[0058] The image parameters include at least one of the following: transparency, hue, brightness, contrast, saturation and color distortion. In this embodiment, the adjustment amount of the image parameters can be determined according to the movement speed in the movement information. The movement speed and the adjustment amount can be in direct proportion, that is, the greater the movement speed, the greater the adjustment amount; the smaller the movement, the smaller the adjustment amount. The transformation of the image is associated with the movement of the key points of the body, that is, the faster the movement of the key points of the body, the more drastic the image transformation.
[0059] Optionally, the adjustment amount of the image parameter may be determined according to the motion speed in the motion information by converting the motion speed mapping into a set interval to obtain the adjustment amount of the image parameter.
[0060] Optionally, the method of determining the adjustment amount of the image parameter according to the motion information may be: if there are multiple body key points, statistical parameters of the motion speeds of the multiple body key points are obtained, and the adjustment amount of the image parameter is determined according to the statistical parameters.
[0061] The statistical parameter of the motion speed may be a maximum motion speed, a minimum motion speed or an average motion speed. After obtaining the statistical parameters of the motion speeds of multiple key points of the body, the statistical parameters are mapped and converted to a set interval to obtain the adjustment amount of the image parameter.
[0062] In this embodiment, the adjustment amount can be passed into the shader, so that the shader adjusts the original image parameters, and the shader renders the image according to the adjusted image parameters, so that the image is displayed with the adjusted parameters. Figure 3 is an example of a processed image in this embodiment, such as Figure 3 As shown (the original image is a color image), the color distortion degree and hue of the current frame image are adjusted by detecting the key points of the hand and the tip of the nose. In this embodiment, the adjustment amount of the image parameter is determined based on the motion speed, so that the image is processed based on the adjustment amount, thereby improving the diversity of image display.
[0063] Optionally, the target image may be obtained by: determining special effect information according to motion information; calling a corresponding special effect package based on the special effect information; and performing special effect processing on the original image based on the special effect package to obtain the target image.
[0064] Among them, the special effect information can be pre-set. The special effect information can be adding virtual objects to the image or stylizing the image, etc., and the form of the special effect is not limited here. Exemplary: adding virtual objects can be: adding "virtual raindrops", "virtual fallen leaves", "virtual snowflakes", etc. to the image. Stylizing the image can be: converting the image into a "stick drawing" style, "animation" style, and "oil painting" style, etc. In this embodiment, the correspondence between the motion speed and the special effect information can be established in advance, so as to determine the special effect information based on the correspondence. Exemplary, Table 1 is a table of the correspondence between motion speed and special effect information.
[0065] As shown in Table 1, after the movement speed of the key points of the body is obtained, the speed interval in which the movement speed is located is determined, and the special effect information corresponding to the speed interval is determined as the special effect information corresponding to the current frame image. For example, assuming that the movement speed of the key points of the body of the current frame falls into interval 2, the special effect information of the current frame image is special effect 2.
[0066] Table 1
[0067] Movement speed range Special Effects Information Speed range 1 Effect 1 Speed range 2 Effect 1 …… …… Speed range N Special Effects
[0068] Among them, the special effects package encapsulates the relevant logic for image special effects processing, and the image can be quickly processed with special effects by calling the special effects package.
[0069] In this embodiment, the special effect information is determined by the motion speed, so as to perform corresponding special effect processing on the current frame image, thereby improving the diversity of image display.
[0070] The multimedia file may be understood as an audio and video file, and a method of generating the multimedia file according to the target image and the audio file may be: performing audio and video encoding on the target image and the audio file to obtain the audio and video file.
[0071] Optionally, the process of generating a multimedia file based on a target image and an audio file may be: obtaining the area position of the body key points on the screen in the previous frame; if the area position of the screen in the previous frame is different from the area position of the screen in the current frame, generating multimedia based on the target image and the audio file.
[0072] Wherein, if the regional position of the previous frame on the screen is the same as the regional position of the current frame on the screen, it indicates that the movement amplitude of the key points of the body is small at this time, and the audio file is suspended to display only the original image. If the regional position of the previous frame on the screen is different from the regional position of the current frame on the screen, it indicates that the movement amplitude of the key points of the body is large, and multimedia is generated according to the target image and the audio file. In this embodiment, when the movement amplitude of the key points of the body is large, multimedia is generated according to the target image and the audio file, which can ensure that the audio playback and the image transformation are triggered by the user's movement, thereby improving the accuracy of interaction.
[0073] Specifically, when generating a multimedia file, the frame rate of the multimedia file can also be determined according to the motion information of the key points of the body. The frame rate can be determined by the motion speed, and the frame rate is proportional to the motion speed, that is, the greater the motion speed, the greater the frame rate, and the smaller the motion speed, the longer the frame rate, so that the priority of multimedia playback is related to the speed of the key points of the body, thereby improving the accuracy of the interaction between the user and the smart terminal.
[0074] S140, controlling the multimedia file to play.
[0075] In this embodiment, after the multimedia file is generated, at least one audio file is controlled to be played.
[0076] Based on the above embodiments, Figure 4 is a schematic diagram of an interaction method in this embodiment, such as Figure 4 As shown, the method includes the following steps: first, obtaining the 2D coordinates of the hand key points, the head key points and the nose tip key points; then determining the regional position of each body key point on the screen according to the 2D coordinates; then determining the corresponding audio file according to the regional position; judging whether the regional position of the current frame is the same as the regional position of the previous frame, if different, generating a multimedia file according to the audio file and the target image, playing the multimedia file, and processing the current frame image.
[0077] The technical solution of the disclosed embodiment is to identify the motion information of at least one key point of the body of the target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen; determine the audio file according to the key point of the body and the motion information; obtain the target image, generate a multimedia file according to the target image and the audio file; and control the multimedia file to play. The interactive method provided by the disclosed embodiment determines the audio file through the key point of the body and the motion information, and generates the multimedia file according to the target image and the audio file, so as to realize the joint control of sound and image and improve the diversity of the interaction between the user and the smart terminal.
[0078] Figure 5 A schematic diagram of the structure of an interactive device provided by an embodiment of the present disclosure is shown in FIG. Figure 5 As shown, the device comprises:
[0079] The motion information identification module 510 is used to identify the motion information of at least one key point of the body of the target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen;
[0080] An audio file determination module 520, configured to determine an audio file according to the key points of the body and the motion information;
[0081] A multimedia file generating module 530, configured to obtain a target image and generate a multimedia file according to the target image and the audio file;
[0082] The control module 540 is used to control the multimedia file to be played.
[0083] Optionally, the motion information identification module 510 is further configured to:
[0084] Obtain the 3D coordinates of at least one key point of the target user's body in the previous frame and the 3D coordinates of the current frame;
[0085] Determine the movement speed of the key points of the body according to the 3D coordinates of the previous frame and the 3D coordinates of the current frame;
[0086] The 3D coordinates of the current frame are converted into 2D coordinates in the screen.
[0087] Optionally, the audio file determination module 520 is further configured to:
[0088] Acquire the sound type corresponding to the key point of the body; wherein the sound type includes a plurality of music elements, and the audio file is composed of the music elements;
[0089] Determine the area position of the key point of the body on the screen according to the coordinates of the key point of the body on the screen;
[0090] An audio file is determined according to the area position and the sound type.
[0091] Optionally, it further includes: a corresponding relationship building module, used for:
[0092] Constructing a correspondence between the key points of the body and the sound type;
[0093] Divide the screen into multiple areas;
[0094] A correspondence relationship between the multiple regions and the multiple audio files corresponding to the key points of the body is established.
[0095] Optionally, the corresponding relationship building module is also used to:
[0096] sorting the multiple areas according to the location information;
[0097] Sorting the multiple audio files corresponding to the key points of the body according to the musical scale;
[0098] A correspondence between the sorted multiple regions and the sorted multiple audio files is established.
[0099] Optionally, the multimedia file generating module 530 is further used to:
[0100] Determining an adjustment amount of an image parameter according to the motion information; wherein the image parameter includes at least one of the following: transparency, hue, brightness, contrast and saturation;
[0101] The original image is processed according to the adjustment amount to obtain a target image.
[0102] Optionally, the multimedia file generating module 530 is further used to:
[0103] If the body key points include multiple ones, then obtain the statistical parameters of the movement speed of the multiple body key points.
[0104] The adjustment amount of the image parameter is determined according to the statistical parameter.
[0105] Optionally, the multimedia file generating module 530 is further used to:
[0106] Determining special effect information according to the motion information;
[0107] Calling a corresponding special effect package based on the special effect information;
[0108] The original image is processed with special effects based on the special effects package to obtain a target image.
[0109] Optionally, the multimedia file generating module 530 is further used to:
[0110] Obtaining the area position of the body key point on the screen in the previous frame;
[0111] If the area position of the previous frame on the screen is different from the area position of the current frame on the screen, multimedia is generated according to the target image and the audio file.
[0112] The interactive device provided in the embodiments of the present disclosure can execute the interactive method provided in any embodiment of the present disclosure, and has the corresponding functional modules and beneficial effects of the execution method.
[0113] It is worth noting that the various units and modules included in the above-mentioned device are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the embodiments of the present disclosure.
[0114] Figure 6 This is a schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Figure 6 , which shows an electronic device (eg, Figure 6 The terminal device in the embodiment of the present disclosure may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0115] like Figure 6 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An edit / output (I / O) interface 505 is also connected to the bus 504.
[0116] Typically, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 509. The communication device 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 6 The electronic device 500 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0117] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 509, or installed from a storage device 508, or installed from a ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
[0118] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0119] The electronic device provided by the embodiment of the present disclosure and the interaction method provided by the above embodiment belong to the same inventive concept. The technical details not fully described in this embodiment can be referred to the above embodiment, and this embodiment has the same beneficial effects as the above embodiment.
[0120] The embodiments of the present disclosure provide a computer storage medium on which a computer program is stored. When the program is executed by a processor, the interactive method provided by the above embodiments is implemented.
[0121] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0122] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0123] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0124] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device:
[0125] The above-mentioned computer-readable medium carries one or more programs. When the above-mentioned one or more programs are executed by the electronic device, the electronic device: identifies the motion information of at least one body key point of the target user; wherein the motion information includes the motion speed and / or the coordinates of the body key point on the screen; determines an audio file based on the body key point and the motion information; obtains a target image, and generates a multimedia file based on the target image and the audio file; and controls the multimedia file to play.
[0126] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or a combination thereof, including, but not limited to, object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., through the Internet using an Internet service provider).
[0127] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0128] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, the first acquisition unit may also be described as a "unit for acquiring at least two Internet Protocol addresses".
[0129] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0130] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0131] According to one or more embodiments of the present disclosure, there is provided an interaction method, comprising:
[0132] Identify the motion information of at least one key point of the body of the target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen;
[0133] Determine an audio file according to the key points of the body and the motion information;
[0134] Acquire a target image, and generate a multimedia file according to the target image and the audio file;
[0135] Control the multimedia file to play.
[0136] Further, identifying the motion information of at least one key point of the target user's body includes:
[0137] Obtain the 3D coordinates of at least one key point of the target user's body in the previous frame and the 3D coordinates of the current frame;
[0138] Determine the movement speed of the key points of the body according to the 3D coordinates of the previous frame and the 3D coordinates of the current frame;
[0139] The 3D coordinates of the current frame are converted into 2D coordinates in the screen.
[0140] Further, determining an audio file according to the key points of the body and the motion information includes:
[0141] Acquire the sound type corresponding to the key point of the body; wherein the sound type includes a plurality of music elements, and the audio file is composed of the music elements;
[0142] Determine the area position of the key point of the body on the screen according to the coordinates of the key point of the body on the screen;
[0143] An audio file is determined according to the area position and the sound type.
[0144] Furthermore, before determining the audio file according to the body key points and the motion information, the method further includes:
[0145] Constructing a correspondence between the key points of the body and the sound type;
[0146] Divide the screen into multiple areas;
[0147] A correspondence relationship between the multiple regions and the multiple audio files corresponding to the key points of the body is established.
[0148] Furthermore, constructing a correspondence between the multiple regions and the multiple audio files corresponding to the key points of the body includes:
[0149] sorting the multiple areas according to the location information;
[0150] Sorting the multiple audio files corresponding to the key points of the body according to the musical scale;
[0151] A correspondence between the sorted multiple regions and the sorted multiple audio files is established.
[0152] Further, obtaining a target image includes:
[0153] Determining an adjustment amount of an image parameter according to the motion information; wherein the image parameter includes at least one of the following: transparency, hue, brightness, contrast and saturation;
[0154] The original image is processed according to the adjustment amount to obtain a target image.
[0155] Further, determining the adjustment amount of the image parameter according to the motion information includes:
[0156] If the body key points include multiple ones, then obtain the statistical parameters of the movement speed of the multiple body key points.
[0157] The adjustment amount of the image parameter is determined according to the statistical parameter.
[0158] Further, obtaining a target image includes:
[0159] Determining special effect information according to the motion information;
[0160] Calling a corresponding special effect package based on the special effect information;
[0161] The original image is processed with special effects based on the special effects package to obtain a target image.
[0162] Further, generating a multimedia file according to the target image and the audio file includes:
[0163] Obtaining the area position of the body key point on the screen in the previous frame;
[0164] If the area position of the previous frame on the screen is different from the area position of the current frame on the screen, multimedia is generated according to the target image and the audio file.
[0165] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0166] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0167] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.
Claims
1. An interactive method, characterized in that: include: Identify the motion information of at least one key point of the body of the target user; wherein the motion information includes the motion speed and / or the coordinates of the key point of the body on the screen; Determine an audio file according to the key points of the body and the motion information; Acquire a target image, and generate a multimedia file according to the target image and the audio file; Control the multimedia file to play.
2. The method according to claim 1, characterized in that Identify the motion information of at least one key point of the target user's body, including: Obtain the 3D coordinates of at least one key point of the target user's body in the previous frame and the 3D coordinates of the current frame; Determine the movement speed of the key points of the body according to the 3D coordinates of the previous frame and the 3D coordinates of the current frame; The 3D coordinates of the current frame are converted into 2D coordinates in the screen.
3. The method according to claim 1, characterized in that Determining an audio file according to the key points of the body and the motion information includes: Acquire the sound type corresponding to the key point of the body; wherein the sound type includes a plurality of music elements, and the audio file is composed of the music elements; Determine the area position of the key point of the body on the screen according to the coordinates of the key point of the body on the screen; An audio file is determined according to the area position and the sound type.
4. The method according to claim 3, characterized in that: Before determining the audio file according to the body key points and the motion information, the method further includes: Constructing a correspondence between the key points of the body and the sound type; Divide the screen into multiple areas; A correspondence relationship between the multiple regions and the multiple audio files corresponding to the key points of the body is established.
5. The method according to claim 4, characterized in that Constructing a correspondence between the multiple regions and the multiple audio files corresponding to the key points of the body, comprising: sorting the multiple areas according to the location information; Sorting the multiple audio files corresponding to the key points of the body according to the musical scale; A correspondence between the sorted multiple regions and the sorted multiple audio files is established.
6. The method according to claim 1, characterized in that Get the target image, including: Determining an adjustment amount of an image parameter according to the motion information; wherein the image parameter includes at least one of the following: transparency, hue, brightness, contrast and saturation; The original image is processed according to the adjustment amount to obtain a target image.
7. The method according to claim 6, characterized in that Determining the adjustment amount of the image parameter according to the motion information includes: If the body key points include multiple ones, then obtain the statistical parameters of the movement speed of the multiple body key points. The adjustment amount of the image parameter is determined according to the statistical parameter.
8. The method according to claim 1, characterized in that Get the target image, including: Determining special effect information according to the motion information; Calling a corresponding special effect package based on the special effect information; The original image is processed with special effects based on the special effects package to obtain a target image.
9. The method according to claim 3, characterized in that: Generating a multimedia file according to the target image and the audio file includes: Obtaining the area position of the body key point on the screen in the previous frame; If the area position of the previous frame on the screen is different from the area position of the current frame on the screen, multimedia is generated according to the target image and the audio file.
10. An interactive device, characterized in that: include: A motion information recognition module, used to recognize motion information of at least one key point of the target user's body; wherein the motion information includes motion speed and / or coordinates of the key point of the body on the screen; An audio file determination module, used to determine an audio file according to the key points of the body and the motion information; A multimedia file generation module, used for acquiring a target image and generating a multimedia file according to the target image and the audio file; The control module is used to control the multimedia file to be played.
11. An electronic device, characterized in that: The electronic device comprises: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the interaction method as described in any one of claims 1-9.
12. A storage medium comprising computer executable instructions, wherein the computer executable instructions are used to perform the interaction method according to any one of claims 1 to 9 when executed by a computer processor.
