Hand gesture trajectory recognition method and device, storage medium and electronic device
By acquiring and scaling the inner and outer contours of the hand trajectory and determining the overlapping lines as gesture trajectories, the problem of poor accuracy in gesture recognition is solved and the accuracy of identifying gesture trajectories is improved.
Patent Information
- Application Number
- CN202110545143.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-05-19
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2041-05-19
AI Technical Summary
In the existing technology, during the gesture recognition process, the sensitivity of the camera to the light source and the stability of the hand are unstable, resulting in non-standard gesture trajectories and poor accuracy in recognizing gesture trajectories.
By obtaining the hand movement trajectory of the target object, obtain its inner contour and outer contour, and perform a scaling operation on them to make the two coincide, and determine the overlapping line as the gesture trajectory.
It improves the recognition accuracy of gesture trajectories and solves the problem of poor accuracy in the process of gesture trajectory recognition.
Smart Images

Figure CN113269075B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computers, and in particular to a gesture trajectory recognition method and device, a storage medium and an electronic device. Background Art
[0002] In the prior art, during gesture recognition, the camera's sensitivity to the light source, the hand's steadiness, and the hand speed are not stable values. It is even more common to draw more or less, such as a circle that is off by a section or an extended line that is extended out, resulting in the gesture trajectory not being very standard, which further results in poor accuracy in identifying the gesture trajectory.
[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0004] Embodiments of the present invention provide a method and device for identifying a gesture trajectory, a storage medium, and an electronic device, so as to at least solve the technical problem of poor accuracy in identifying a gesture trajectory.
[0005] According to one aspect of an embodiment of the present invention, a method for gesture trajectory recognition is provided, including: obtaining a movement trajectory of a hand of a target object; obtaining an inner contour line and an outer contour line of the movement trajectory; performing a scaling operation on the inner contour line or the outer contour line so that the inner contour line and the outer contour line overlap; and determining the overlapping line of the inner contour line and the outer contour line as the gesture trajectory of the target object.
[0006] According to another aspect of an embodiment of the present invention, a gesture trajectory recognition device is also provided, including: a first acquisition unit, used to acquire the movement trajectory of the hand of the target object; a second acquisition unit, used to acquire the inner contour line and the outer contour line of the above-mentioned movement trajectory; a processing unit, used to perform a scaling operation on the above-mentioned inner contour line or the above-mentioned outer contour line so that the above-mentioned inner contour line and the above-mentioned outer contour line overlap; a determination unit, used to determine the overlapping line of the above-mentioned inner contour line and the above-mentioned outer contour line as the above-mentioned gesture trajectory of the above-mentioned target object.
[0007] As an optional example, the processing unit includes: a first adjustment module, used to adjust a point at the same position of the inner contour line and the outer contour line to overlap; a second adjustment module, used to adjust the direction of the inner contour line to be consistent with the direction of the outer contour line; a third adjustment module, used to enlarge the inner contour line or reduce the outer contour line; a calculation module, used to calculate the length of the overlapping line of the inner contour line and the outer contour line during the process of enlarging the inner contour line or reducing the outer contour line; a processing module, used to stop enlarging the inner contour line or reducing the outer contour line when the length of the overlapping line is the largest.
[0008] As an optional example, the second acquisition unit includes: a first determination module, which is used to start from a first area within the moving trajectory, expand the boundary of the first area, and when the boundary of the first area contacts the moving trajectory, keep the contacted boundary unchanged, and continue to expand the uncontacted boundary until all boundaries of the first area contact the moving trajectory, and determine the boundary of the first area contacting the moving trajectory as the inner contour line; a second determination module, which is used to acquire a second area surrounding the moving trajectory, shrink the boundary of the second area, and when the boundary of the second area contacts the moving trajectory, keep the contacted boundary unchanged, and continue to shrink the uncontacted boundary until all boundaries of the second area contact the moving trajectory, and determine the boundary of the second area contacting the moving trajectory as the outer contour line.
[0009] As an optional example, the above-mentioned first acquisition unit includes: a capture module, used to capture the position of the hand of the above-mentioned target object in the three-dimensional space at different time points through a camera; a third determination module, used to determine the intersection of the above-mentioned hand position and the first plane as the trajectory point of the above-mentioned hand, wherein the above-mentioned first plane is a plane perpendicular to the ray emitted by the above-mentioned camera; a connection module, used to connect the above-mentioned trajectory points in the order of the above-mentioned different time points to obtain a first trajectory; a fourth determination module, used to determine the above-mentioned first trajectory as the above-mentioned moving trajectory.
[0010] As an optional example, when the target object is a person in the picture captured by a camera, the device further includes: a search unit for searching for a target special effect matching the gesture trajectory in a gesture trajectory and special effect correspondence table after determining the overlapping line of the inner contour line and the outer contour line as the gesture trajectory of the target object; and a display unit for displaying the target special effect in a live broadcast room for broadcasting the picture.
[0011] As an optional example, the above-mentioned search unit includes: a fifth determination module, used to determine the current scene that generates the above-mentioned gesture trajectory; an acquisition module, used to obtain the above-mentioned gesture trajectory and special effect correspondence table matching the above-mentioned current scene; a search module, used to search for the above-mentioned target special effect matching the above-mentioned gesture trajectory in the above-mentioned gesture trajectory and special effect correspondence table matching the above-mentioned current scene, wherein the above-mentioned gesture trajectory corresponds to different above-mentioned target special effects in different gesture trajectory and special effect correspondence tables.
[0012] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned gesture trajectory recognition method when running.
[0013] According to another aspect of an embodiment of the present invention, there is provided an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the gesture trajectory recognition method through the computer program.
[0014] In an embodiment of the present invention, a method is adopted for obtaining the movement trajectory of the hand of the target object; obtaining the inner contour line and the outer contour line of the above movement trajectory; performing a scaling operation on the above inner contour line or the above outer contour line to make the above inner contour line and the above outer contour line overlap; and determining the overlapping line of the above inner contour line and the above outer contour line as the above gesture trajectory of the above target object. In the above method, in the process of identifying the gesture trajectory, when the movement trajectory of the hand is obtained, the inner contour line and the outer contour line of the movement trajectory are obtained, and the inner contour line or the outer contour line is scaled to obtain the overlapping part of the two, and the overlapping line is determined as the gesture trajectory, thereby achieving the effect of obtaining an accurate gesture trajectory based on the overlapping line of the inner contour line and the outer contour line, thereby solving the technical problem of poor accuracy in identifying the gesture trajectory. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0016] Figure 1 is a schematic diagram of an application environment of an optional gesture trajectory recognition method according to an embodiment of the present invention;
[0017] Figure 2 is a schematic diagram of a process of an optional gesture trajectory recognition method according to an embodiment of the present invention;
[0018] Figure 3 is a schematic diagram of inner contour lines and outer contour lines of an optional gesture trajectory recognition method according to an embodiment of the present invention;
[0019] Figure 4 is a schematic diagram of the overlap of the inner contour line and the outer contour line of an optional gesture trajectory recognition method according to an embodiment of the present invention;
[0020] Figure 5 is a schematic diagram of scaling an inner contour line or an outer contour line of an optional gesture trajectory recognition method according to an embodiment of the present invention;
[0021] Figure 6 is a schematic diagram of obtaining a moving trajectory on a two-dimensional plane according to an optional method for gesture trajectory recognition according to an embodiment of the present invention;
[0022] Figure 7 It is a schematic structural diagram of an optional gesture trajectory recognition device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0025] According to one aspect of an embodiment of the present invention, a method for identifying a gesture trajectory is provided. Optionally, as an optional implementation, the method for identifying a gesture trajectory may be applied to, but is not limited to, Figure 1 in the environment shown.
[0026] like Figure 1 As shown, the terminal device 102 includes a memory 104 for storing various data generated during the operation of the terminal device 102, a processor 106 for processing and calculating the above data, and a display 108 for displaying a message prompting to collect the movement trajectory. The terminal device 102 can exchange data with the server 112 through the network 110. The server 112 includes a database 114 for storing various data and a processing engine 116 for processing the above data. Through steps S102 to S104, the terminal device 102 can upload the gesture trajectory to the server 112 after identifying the gesture trajectory, and the server 112 returns the interaction result.
[0027] Optionally, in this embodiment, the terminal device may be a terminal device configured with a target client, which may include but is not limited to at least one of the following: a mobile phone (such as an Android phone, an iOS phone, etc.), a laptop, a tablet computer, a PDA, a MID (Mobile Internet Devices), a PAD, a desktop computer, a smart TV, etc. The target client may be a video client, an instant messaging client, a browser client, an education client, etc. The network may include but is not limited to: a wired network, a wireless network, wherein the wired network includes: a local area network, a metropolitan area network and a wide area network, and the wireless network includes: Bluetooth, WIFI and other networks that realize wireless communication. The server may be a single server, or a server cluster consisting of multiple servers, or a cloud server. The above is only an example, and this embodiment does not impose any limitation on this.
[0028] Optionally, as an optional implementation, as Figure 2 As shown, the above-mentioned gesture trajectory recognition method includes:
[0029] S202, obtaining the movement trajectory of the hand of the target object;
[0030] S204, obtaining the inner contour line and the outer contour line of the moving trajectory;
[0031] S206, performing a scaling operation on the inner contour line or the outer contour line so that the inner contour line and the outer contour line overlap;
[0032] S208: Determine the overlapping line of the inner contour line and the outer contour line as the gesture trajectory of the target object.
[0033] Optionally, the above-mentioned gesture trajectory determination method can be, but is not limited to, in the process of using gesture trajectories to generate control instructions. For example, in the process of using a target application, a control instruction is generated using a gesture trajectory to log in to the target application, execute any function of the target application, or exit the target application. The target application can be any type of application, such as a learning application, a live broadcast application, a video application, a music application, a shopping application, etc. For example, taking a live broadcast application as an example, when the user's hand moves, the movement trajectory of the user's hand is obtained, and a circular gesture trajectory is determined, the live broadcast application can be controlled to exit the current live broadcast.
[0034] In this embodiment, when determining the gesture trajectory, when the movement trajectory of the hand is obtained, the inner contour line and the outer contour line of the movement trajectory can be obtained first, and then the inner contour line and / or the outer contour line can be scaled so that the two include overlapping lines, and the overlapping lines are determined as the gesture trajectory, thereby improving the accuracy of determining the gesture trajectory.
[0035] For example, Figure 3 As shown, Figure 3 A quasi-circular shape 302, and a quasi-circular outer contour line 304 and an inner contour line 306, Figure 4 The schematic diagram is to scale the inner contour line and / or the outer contour line so that the two overlap, and the overlapping lines are determined as the gesture trajectory.
[0036] As an optional example, performing a scaling operation on the inner contour line or the outer contour line so that the inner contour line and the outer contour line overlap includes:
[0037] Adjust a point at the same position of the inner contour line and the outer contour line to coincide with each other;
[0038] Adjust the direction of the inner contour line to be consistent with the direction of the outer contour line;
[0039] Enlarge the inner contour or reduce the outer contour;
[0040] In the process of enlarging the inner contour line or reducing the outer contour line, the length of the overlapping line between the inner contour line and the outer contour line is calculated;
[0041] When the length of the overlapping lines is the maximum, stop enlarging the inner contour line or reducing the outer contour line.
[0042] Optionally, in this embodiment, when scaling the inner contour line or the outer contour line, it can be ensured that the corresponding points on the inner contour line and the outer contour line are coincident, and then the directions of the inner contour line and the outer contour line are set to be consistent. Figure 5 As shown, point 504 on the inner contour line and point 502 on the outer contour line are corresponding points, and the two points are overlapped. Taking the overlapped point as a reference, the inner contour line and the outer contour line have the same direction, and the inner contour line is enlarged or the outer contour line is reduced to increase the number of overlapping lines between the two. The overlapping lines with the most overlapping lines are determined as the gesture trajectory. That is, when the two overlap, the overlapping lines are the most, and the overlapping lines are determined as the gesture trajectory.
[0043] In this embodiment, the outer contour line can be first reduced, and the inner contour line is kept unchanged. If the outer contour line is reduced to below the first threshold and there is still no overlapping line with the inner contour line, the inner contour line and the outer contour line are re-acquired, the outer contour line is kept unchanged, and the inner contour line is expanded until the overlapping lines are obtained. In this embodiment, when the ratio of the overlapping lines of the inner contour line and the outer contour line to the inner contour line or the outer contour line exceeds the second threshold, the overlapping lines can be determined as the gesture trajectory.
[0044] As an optional example, obtaining the inner contour line and the outer contour line of the moving trajectory includes:
[0045] Starting from a first area within the moving track, the boundary of the first area is expanded, and when the boundary of the first area contacts the moving track, the contacted boundary is kept unchanged, and the uncontacted boundary is continued to be expanded until all boundaries of the first area contact the moving track, and the boundary of the first area contacting the moving track is determined as the inner contour line;
[0046] A second area surrounding the moving track is obtained, and the boundary of the second area is reduced. When the boundary of the second area contacts the moving track, the contacted boundary is kept unchanged, and the uncontacted boundary is further reduced until all boundaries of the second area contact the moving track, and the boundary of the second area contacting the moving track is determined as an outer contour line.
[0047] As an optional example, obtaining the movement trajectory of the hand of the target object includes:
[0048] The position of the target object's hand in three-dimensional space at different time points is captured by a camera;
[0049] Determine the intersection of the position of the hand and the first plane as the trajectory point of the hand, wherein the first plane is a plane perpendicular to the ray emitted by the camera;
[0050] Connect the trajectory points according to the sequence of different time points to obtain the first trajectory;
[0051] The first trajectory is determined as a moving trajectory.
[0052] Optionally, the movement trajectory of the hand in this embodiment may be a movement trajectory captured by a camera. When the camera captures the movement trajectory, it may capture the trajectory of the hand moving in three-dimensional space projected onto a plane. Figure 6 As shown, the camera 602 captures the movement trajectory 604 of the hand, and the movement trajectory 604 is a trajectory in three-dimensional space. It is mapped onto the plane 606 to obtain the movement trajectory of the two-dimensional plane. Then, the gesture trajectory is determined according to the movement trajectory of the two-dimensional plane.
[0053] As an optional example, when the target object is a person in a picture captured by a camera, after determining the overlapping line of the inner contour line and the outer contour line as the gesture trajectory of the target object, the method further includes:
[0054] In the gesture trajectory and special effect correspondence table, search for the target special effect that matches the gesture trajectory;
[0055] The target special effect is displayed in the live broadcast room used for the live broadcast screen.
[0056] Optionally, in this embodiment, the gesture trajectory can be bound to the operation of the application. For example, when applied to the live broadcast scene, the gesture trajectory can be bound to the operation of the live broadcast room. For example, the triangular gesture trajectory is for the live broadcast room to release virtual fireworks, and the square gesture trajectory is for the live broadcast room to open a lottery. For example, when the square virtual fireworks are displayed, the number of virtual fireworks can be determined by the number of executions of the gesture trajectory, or after executing the triangular gesture trajectory, the number can be input by voice, such as saying "3" after executing the triangular gesture trajectory, and then 3 virtual fireworks will be released in the live broadcast room. Optionally, in this embodiment, the gesture trajectory can also be operated by gestures. For example, after obtaining the triangular gesture trajectory, if you lift your finger upward, you can release the virtual fireworks, and if you press your finger downward, although it is a triangular gesture trajectory, it can correspond to opening the lottery. In other words, for the same gesture trajectory, different gestures performed on the gesture trajectory can correspond to different behaviors or target special effects.
[0057] As an optional example, in the gesture track and special effect correspondence table, searching for a target special effect matching the gesture track includes:
[0058] Determine the current scene that generates the gesture trajectory;
[0059] Get the gesture trajectory and special effect correspondence table matching the current scene;
[0060] In the gesture trajectory and special effect correspondence table matching the current scene, the target special effect matching the gesture trajectory is searched, wherein the gesture trajectory corresponds to different target special effects in different gesture trajectory and special effect correspondence tables.
[0061] In this embodiment, different target special effects can be set for different scenes of the same application. For example, in the live broadcast application, in the scene of live broadcast interaction, the triangular gesture trajectory can be set to release virtual fireworks, and in the scene of live broadcast competition, the triangular gesture trajectory can be set to release bombs to the competition opponent, etc.
[0062] Taking the live broadcast scene as an example, during the user's live broadcast, the camera collects the three-dimensional coordinates of the user's fingertips moving in space, and projects the three-dimensional coordinates onto a plane perpendicular to the rays emitted by the camera to obtain two-dimensional coordinates (there are disturbance points when the hand is started and when it is closed, and changes in hand speed and hand stability will produce interference points).
[0063] The outline of the drawn figure is extracted according to the drawing order, and at least the inner outline and the outer outline are extracted.
[0064] Adjust the size so that all contours overlap, extract the overlapping contours, and obtain the overlapping lines. By obtaining the overlapping lines, you can exclude the redundant lines and the locations where there are more than the lines.
[0065] The overlapping contours, that is, the overlapping lines without interference from other lines, can be used to identify the shape. The shape of the gesture trajectory can be known by calculating the curvature change and the position of the corner points of the contour.
[0066] According to the known shape and corner position of the figure, the anchor's figure is converted into the clean figure drawn by the anchor. (If the rectangle, triangle, five-pointed star, etc. are known, just connect the corresponding corner points, and if the circle is known, draw it through a curve). Different gestures can correspond to different special effects. Flying upward with the gesture trajectory can switch scenes, for example, the circle is a virtual firework explosion, the triangle is a virtual scene of rain, etc. Flying to another anchor is a virtual special effect, such as the circle will become a bomb to produce black smoke effects, the triangle is a rose, etc.
[0067] It should be noted that, for the above-mentioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence, because according to the present invention, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0068] According to another aspect of the embodiments of the present invention, a gesture trajectory recognition device for implementing the above-mentioned gesture trajectory recognition method is also provided. Figure 7 As shown, the device comprises:
[0069] Optionally, the above-mentioned gesture trajectory determination device can be, but is not limited to, in the process of using gesture trajectories to generate control instructions. For example, in the process of using a target application, a control instruction is generated using a gesture trajectory to log in to the target application, execute any function of the target application, or exit the target application. The target application can be any type of application, such as a learning application, a live broadcast application, a video application, a music application, a shopping application, etc. For example, taking a live broadcast application as an example, when the user's hand moves, the movement trajectory of the user's hand is obtained, and a circular gesture trajectory is determined, the live broadcast application can be controlled to exit the current live broadcast.
[0070] In this embodiment, when determining the gesture trajectory, when the movement trajectory of the hand is obtained, the inner contour line and the outer contour line of the movement trajectory can be obtained first, and then the inner contour line and / or the outer contour line can be scaled so that the two include overlapping lines, and the overlapping lines are determined as the gesture trajectory, thereby improving the accuracy of determining the gesture trajectory.
[0071] For other examples of this embodiment, please refer to the above examples and will not be described in detail here.
[0072] According to another aspect of an embodiment of the present invention, an electronic device for implementing the above-mentioned gesture trajectory recognition method is also provided, the electronic device includes a memory and a processor, the memory stores a computer program, and the processor is configured to execute the steps in any of the above-mentioned method embodiments through the computer program.
[0073] Optionally, in this embodiment, the electronic device may be located in at least one network device among a plurality of network devices of a computer network.
[0074] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0075] Obtain the movement trajectory of the target object's hand;
[0076] Get the inner and outer contours of the moving trajectory;
[0077] Performing a scaling operation on the inner contour or the outer contour so that the inner contour and the outer contour coincide with each other;
[0078] The coincident line of the inner contour line and the outer contour line is determined as the gesture trajectory of the target object.
[0079] According to another aspect of the embodiments of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when run.
[0080] Optionally, in this embodiment, the computer-readable storage medium may be configured to store a computer program for performing the following steps:
[0081] Obtain the movement trajectory of the target object's hand;
[0082] Get the inner and outer contours of the moving trajectory;
[0083] Performing a scaling operation on the inner contour or the outer contour so that the inner contour and the outer contour coincide with each other;
[0084] The coincident line of the inner contour line and the outer contour line is determined as the gesture trajectory of the target object.
[0085] Optionally, in this embodiment, a person of ordinary skill in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing hardware related to the terminal device through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.
[0086] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0087] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which can be personal computers, servers or network devices, etc.) to perform all or part of the steps of the methods of various embodiments of the present invention.
[0088] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0089] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0090] 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 on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0091] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0092] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A method for identifying a hand gesture trajectory, characterized in that: include: Obtain the movement trajectory of the target object's hand; Acquiring the inner contour line and the outer contour line of the moving trajectory, comprising: starting from a first area within the moving trajectory, expanding the boundary of the first area, and when the boundary of the first area contacts the moving trajectory, keeping the contacted boundary unchanged, and continuing to expand the uncontacted boundary until all boundaries of the first area contact the moving trajectory, and determining the boundary of the first area contacting the moving trajectory as the inner contour line; acquiring a second area surrounding the moving trajectory, shrinking the boundary of the second area, and when the boundary of the second area contacts the moving trajectory, keeping the contacted boundary unchanged, and continuing to shrink the uncontacted boundary until all boundaries of the second area contact the moving trajectory, and determining the boundary of the second area contacting the moving trajectory as the outer contour line; Performing a zoom-in operation on the inner contour line or a zoom-out operation on the outer contour line so that the inner contour line and the outer contour line overlap, including: adjusting a point at the same position of the inner contour line and the outer contour line to overlap; adjusting the direction of the inner contour line to be consistent with the direction of the outer contour line; zooming in the inner contour line or zooming out the outer contour line; in the process of zooming in the inner contour line or zooming out the outer contour line, calculating the length of the overlapping line between the inner contour line and the outer contour line; when the length of the overlapping line is the largest, stopping zooming in the inner contour line or zooming out the outer contour line; The overlapping line with the longest length between the inner contour line and the outer contour line is determined as the gesture trajectory of the target object.
2. The method according to claim 1, characterized in that The step of obtaining the movement trajectory of the hand of the target object comprises: Capturing the position of the hand of the target object in three-dimensional space at different time points by a camera; Determine an intersection point of the position of the hand and a first plane as a trajectory point of the hand, wherein the first plane is a plane perpendicular to the ray emitted by the camera; Connect the trajectory points according to the sequence of the different time points to obtain a first trajectory; The first trajectory is determined as the movement trajectory.
3. The method according to any one of claims 1 to 2, characterized in that: After determining the coincident line of the inner contour line and the outer contour line as the gesture trajectory of the target object, the method further includes: When the target object is a person in the picture captured by the camera, searching for a target special effect matching the gesture trajectory in a table of gesture trajectory and special effects correspondence; The target special effect is displayed in a live broadcast room used for broadcasting the image.
4. The method according to claim 3, characterized in that: The step of searching the gesture trajectory and special effect correspondence table for a target special effect that matches the gesture trajectory includes: Determining a current scene that generates the gesture trajectory; Obtaining a table of gesture trajectories and special effects that matches the current scene; In the gesture trajectory and special effect correspondence table matching the current scene, the target special effect matching the gesture trajectory is searched, wherein the gesture trajectory corresponds to different target special effects in different gesture trajectory and special effect correspondence tables.
5. A gesture trajectory recognition device, characterized in that: include: A first acquisition unit, used to acquire a movement trajectory of a hand of a target object; A second acquisition unit is used to acquire the inner contour line and the outer contour line of the moving trajectory, including: starting from a first area within the moving trajectory, expanding the boundary of the first area, and when the boundary of the first area contacts the moving trajectory, keeping the contacted boundary unchanged, and continuing to expand the uncontacted boundary until all the boundaries of the first area contact the moving trajectory, and determining the boundary of the first area contacting the moving trajectory as the inner contour line; acquiring a second area surrounding the moving trajectory, shrinking the boundary of the second area, and when the boundary of the second area contacts the moving trajectory, keeping the contacted boundary unchanged, and continuing to shrink the uncontacted boundary until all the boundaries of the second area contact the moving trajectory, and determining the boundary of the second area contacting the moving trajectory as the outer contour line; A processing unit, configured to perform a zoom-in operation on the inner contour line or a zoom-out operation on the outer contour line so that the inner contour line and the outer contour line overlap, comprising: adjusting a point at the same position of the inner contour line and the outer contour line to overlap; adjusting the direction of the inner contour line to be consistent with the direction of the outer contour line; zooming in the inner contour line or zooming out the outer contour line; in the process of zooming in the inner contour line or zooming out the outer contour line, calculating the length of the overlapping line between the inner contour line and the outer contour line; when the length of the overlapping line is the largest, stopping zooming in the inner contour line or zooming out the outer contour line; A determination unit is used to determine the overlapping line with the longest length between the inner contour line and the outer contour line as the gesture trajectory of the target object.
6. A computer-readable storage medium storing a computer program, characterized in that: The computer program executes the method according to any one of claims 1 to 4 when executed.
7. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 4 through the computer program.
