Generation method and device of motion data sharing template and storage medium
The dynamic combination of stickers on the server side generates a motion data sharing template, which solves the problems of frequent template updates and insufficient user experience in the existing technology, and achieves more flexible and efficient template generation and updates.
Patent Information
- Application Number
- CN202411996212.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2044-12-31
AI Technical Summary
The existing sports data sharing template system is limited by the client's native development model, resulting in the changes in templates and the addition of new templates that require updates of client applications, increasing development and maintenance costs, and reducing the timeliness and diversity of user experience.
The target motion type of the target user is extracted from the template generation request sent by the client through the server, query the associated sticker from the database according to this type, and combine it into the target data layer according to the preset position and layer of the sticker, and finally send the data layer to the client to generate a data sharing template.
It realizes flexible generation of motion data sharing templates, no longer limited to fixed templates preset by clients, improves the adaptability and scalability of templates, reduces the frequency of client updates, and improves development efficiency and user experience.
Smart Images

Figure CN119762617A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of software technology, and in particular to a method, device and storage medium for generating a motion data sharing template. Background Art
[0002] In the current era of mobile Internet, sports social applications have become an important tool for promoting a healthy lifestyle. Users use these applications to record detailed data such as exercise trajectory, calories consumed, exercise duration, etc., and can share these achievements on social media to interact with friends and communities and motivate each other. However, the existing sports sharing template system is limited by the client-native development model, which means that any template changes and the addition of new templates need to be implemented through the update of the client application. This practice not only increases the cost of development and maintenance, but also reduces the timeliness and diversity of user experience, because users must wait for the application version to be updated to enjoy new sharing templates or more flexible template editing functions.
[0003] Specifically, sports data sharing templates are usually composed of multiple fixed components, including borders, backgrounds, masks, data layers, and stickers. Among them, the data layer is the core of the template, which is used to display the user's sports data, such as exercise distance, speed, calories consumed, etc., and the display form of these data (such as pie charts, bar charts, sports calendars, etc.) Once hardcoded on the client, it cannot be dynamically adjusted or expanded. For example, if the user wants to move the display of exercise distance from the top to the bottom of the template, or replace the original line chart with a bar chart, such a demand is difficult to meet immediately under the existing technical framework, and it is necessary to go through a series of cumbersome processes such as client development, testing, and release. In addition, with the increasing number of sports, specific sports such as dog walking and climbing stairs may require customized data layer display methods. The rapid growth of this demand further highlights the shortcomings of existing technologies in flexibility and responsiveness.
[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0005] The main purpose of the present application is to provide a method, device and storage medium for generating a motion data sharing template, so as to at least solve the technical problem that the traditional motion data sharing template cannot flexibly add template styles according to dynamic needs.
[0006] In order to achieve the above-mentioned purpose, according to one aspect of an embodiment of the present application, a method for generating a motion data sharing template is provided, comprising: extracting, through a server, a target motion type of a target user from a template generation request sent by a client, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates; obtaining, through the server, L stickers associated with the target motion type from a database according to the target motion type, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; when L is an integer greater than 1, combining the L stickers into a target data layer according to a preset position and a preset layer of each sticker, wherein the target data layer is used to display the motion data and motion trajectory of the target user; sending the target data layer to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer.
[0007] Optionally, before obtaining L stickers associated with the target motion type from a database according to the target motion type, N stickers are generated, wherein N is an integer greater than 1, and the types of stickers include at least a first type and a second type, stickers of the first type are used to represent data elements, and stickers of the second type are used to represent pattern elements; sticker attributes are set for each sticker, wherein the sticker attributes are used to determine whether the sticker can be rotated, dragged, and scaled; and the N stickers and the sticker attributes of the stickers are stored in a database.
[0008] Optionally, after storing N stickers and sticker attributes of the stickers in a database, a configuration file is generated, wherein the configuration file is used to establish an association relationship between any type of sport and at least one sticker; a style file corresponding to any type of sport is generated in the client based on the configuration file, wherein the style file includes sticker attributes of the stickers associated with the sport type.
[0009] Optionally, when L is an integer greater than 1, L stickers are combined into a target data layer according to a preset position and a preset layer of each sticker, including: obtaining the interface size of the display interface of the client; determining the size of each of the L stickers according to the interface size; and combining the L stickers into a target data layer according to the preset position and the preset layer of each sticker through the server based on the size of each sticker.
[0010] Optionally, sending the target data layer to the client includes: sending the target data layer and at least one template element to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer and the at least one template element, and the at least one template element includes: a first element, used to represent the border of the data sharing template corresponding to the target user; a second element, used to represent the background image of the data sharing template corresponding to the target user; a third element, used to represent the mask of the data sharing template corresponding to the target user; and a fourth element, used to represent an image sticker in the data sharing template corresponding to the target user that is used in conjunction with the target data layer.
[0011] Optionally, after obtaining L stickers associated with the target motion type from the database according to the target motion type, when L is equal to 1, a sticker obtained from the database is used as the target data layer.
[0012] In order to achieve the above-mentioned purpose, according to another aspect of an embodiment of the present application, a method for displaying a motion data sharing template is also provided, including: sending a template generation request to a server through a client, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates; receiving a target data layer generated by the server according to the target motion type, wherein the target data layer is used to display the motion data and motion trajectory of the target user, and the target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker according to the query, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; generating a data sharing template corresponding to the target user according to the target data layer through the client and displaying it.
[0013] Optionally, a data sharing template corresponding to the target user is generated and displayed through the client based on the target data layer, including: through the client, based on a style file corresponding to the target sport type built into the client, each sticker in the target data layer is parsed, wherein the style file includes sticker attributes of stickers associated with the target sport type; according to the sticker attributes of each sticker recorded in the style file, each sticker in the target data layer is rendered in the display interface of the client, and the data sharing template corresponding to the target user is obtained and displayed.
[0014] In order to achieve the above-mentioned purpose, according to another aspect of an embodiment of the present application, a device for generating a motion data sharing template is also provided, including: an extraction unit, which extracts the target motion type of the target user from the template generation request sent by the client through the server, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates; a query unit, which obtains L stickers associated with the target motion type from the database through the server according to the target motion type, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; a combination unit, which combines the L stickers into a target data layer according to the preset position and preset layer of each sticker when L is an integer greater than 1, wherein the target data layer is used to display the motion data and motion trajectory of the target user; a sending unit, which sends the target data layer to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer.
[0015] In order to achieve the above-mentioned purpose, according to another aspect of an embodiment of the present application, a display device for a motion data sharing template is also provided, including: a request sending unit, sending a template generation request to a server through a client, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates; a receiving unit, receiving a target data layer generated by the server according to the target motion type, wherein the target data layer is used to display the motion data and motion trajectory of the target user, and the target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker according to the query, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; a display unit, generating a data sharing template corresponding to the target user according to the target data layer through the client and displaying it.
[0016] According to another aspect of an embodiment of the present application, an electronic device is also provided, including one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by one or more processors, the one or more processors execute the above-mentioned method for generating a motion data sharing template and the method for displaying a motion data sharing template.
[0017] According to another aspect of an embodiment of the present application, a computer-readable storage medium is also provided, in which a computer program is stored. When the computer program is running, the device where the computer-readable storage medium is located executes the above-mentioned method for generating a motion data sharing template and the method for displaying a motion data sharing template.
[0018] In the present application, first, the target motion type of the target user is extracted from the template generation request sent by the client through the server, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates. Then, through the server, according to the target motion type, L stickers associated with the target motion type are queried from the database, wherein L is an integer greater than or equal to 1, and each sticker represents a template element. When L is an integer greater than 1, the L stickers are combined into a target data layer according to the preset position and preset layer of each sticker, wherein the target data layer is used to display the motion data and motion trajectory of the target user. Finally, the target data layer is sent to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer.
[0019] From the above content, it can be seen that the server can generate a request for a template sent by the client and identify the target sport type of the target user, so that the generation of sharing templates is no longer limited to the fixed templates preset by the client, but can dynamically generate corresponding templates according to different sport types, which greatly enhances the adaptability and extensibility of sharing templates. For example, indoor running and outdoor cycling require different types and formats of data to be displayed. The server can select the most appropriate sticker combination according to the sport type and generate the data sharing template that best fits the sport.
[0020] Secondly, the server queries L stickers related to the target sport type, and combines them according to the preset position and preset layer of each sticker to form the target data layer. This process realizes the flexible combination of template elements, so that the data sharing template can be customized according to the characteristics of the sport data and the user's preferences, improving the personalization and practicality of the template. For example, users can choose to put the sport distance at the top, the sport time at the bottom, or integrate the sport track into the background, instead of using a fixed layout.
[0021] It should be noted that in traditional technologies, adding new template styles or adjusting existing templates requires the client to re-release the version, which is not only time-consuming, but may also affect the user experience due to compatibility issues caused by version updates. In the present application scheme, the adjustment of template styles and element layouts is mainly completed on the server side. The client only needs to receive the target data layer sent by the server and generate a data sharing template based on it. This avoids frequent client updates and improves development efficiency and user satisfaction. In addition, the dynamically generated data sharing template can more accurately reflect the user's motion data and motion trajectory, while allowing users to make customized choices based on motion types and personal preferences. This not only provides a richer visual experience, but also increases the fun and attractiveness of sharing, thereby stimulating users' willingness to share motion data and promoting community interaction and user stickiness.
[0022] It can be seen that the mechanism of dynamically generating templates on the server side facilitates content innovation and template iteration. Product teams can try and launch new template designs more quickly without waiting for the client version update cycle, which helps to maintain the vitality and competitiveness of the application and meet the ever-changing needs of users. In addition, the client no longer needs to be updated frequently to adapt to new template styles or sports types, reducing development workload and version maintenance costs. At the same time, centralized configuration and generation on the server side also simplifies template management and reduces the complexity and cost of long-term operations.
[0023] In summary, the present application scheme effectively solves the limitations of the static design of traditional sports data sharing templates through the technical feature of dynamically generating data sharing templates on the server side, significantly improves the flexibility and efficiency of template generation, optimizes the user experience, and reduces the burden of development and maintenance. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0025] Figure 1 A hardware structure block diagram of a computer terminal for implementing a method for generating a sports data sharing template and a method for displaying a sports data sharing template is shown;
[0026] Figure 2 is a flow chart of an optional method for generating a sports data sharing template according to an embodiment of the present application;
[0027] Figure 3 is a schematic diagram of an optional data sharing template according to an embodiment of the present application;
[0028] Figure 4 is a flow chart of an optional method for processing a sports data sharing template according to an embodiment of the present application;
[0029] Figure 5 is a flow chart of an optional method for displaying a sports data sharing template according to an embodiment of the present application;
[0030] Figure 6 is a schematic diagram of an optional device for generating a sports data sharing template according to an embodiment of the present application;
[0031] Figure 7 is a schematic diagram of a display device of an optional sports data sharing template according to an embodiment of the present application;
[0032] Figure 8It is a structural block diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0033] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0034] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application 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 interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0035] It should also be noted that the collected information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for display, data for analysis, etc.) involved in this application are information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of relevant data are in compliance with relevant laws, regulations and standards, necessary confidentiality measures are taken, and public order and good customs are not violated, and corresponding operation entrances are provided for users to choose to authorize or refuse. For example, an interface is set up between this system and relevant users or institutions to provide users with corresponding operation entrances for users to choose to agree or refuse the results of automated decision-making; if the user chooses to refuse, the expert decision-making process will be entered.
[0036] The method embodiments provided in the embodiments of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Figure 1 The hardware structure block diagram of a computer terminal (or mobile device) for implementing a method for generating a sports data sharing template and a method for displaying a sports data sharing template is shown. Figure 1As shown, the computer terminal 10 (or mobile device) may include one or more (102a, 102b, ..., 102n are used to illustrate) processors 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA), a memory 104 for storing data, and a transmission device 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of the BUS bus), a network interface, a power supply and / or a camera. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.
[0037] It should be noted that the above-mentioned one or more processors 102 and / or other data processing circuits may generally be referred to as "data processing circuits" in this article. The data processing circuit may be embodied in whole or in part as software, hardware, firmware or any other combination. In addition, the data processing circuit may be a single independent processing module, or may be fully or partially integrated into any one of the other components in the computer terminal 10 (or mobile device). As in the method for generating a motion data sharing template and the method for displaying a motion data sharing template involved in the embodiments of the present application, the data processing circuit acts as a processor control (e.g., selection of a variable resistor terminal path connected to an interface).
[0038] The memory 104 can be used to store software programs and modules of application software, such as the program instructions / data storage device corresponding to the method for generating the motion data sharing template and the method for displaying the motion data sharing template in the embodiment of the present application. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, that is, the method for generating the motion data sharing template and the method for displaying the motion data sharing template are realized. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the computer terminal 10 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof.
[0039] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the computer terminal 10. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0040] The display may be, for example, a touch screen liquid crystal display (LCD) that enables a user to interact with a user interface of the computer terminal 10 (or mobile device).
[0041] Under the above operating environment, this application provides Figure 2 The method for generating the sports data sharing template is shown. Figure 2 FIG. 1 is a flow chart of a method for generating an optional motion data sharing template according to an embodiment of the present application. Figure 2 As shown, the method comprises the following steps:
[0042] Step S201: extracting the target sport type of the target user from the template generation request sent by the client through the server.
[0043] In step S201 , the template generation request is used to indicate that the target user desires to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates.
[0044] Optionally, the execution subject of the method for generating a motion data sharing template can be a server, wherein the server refers to a system or program that provides functions such as data processing, logical operations, and resource management in the Internet architecture, and is usually run on a remote server. In this application, the server plays the role of a dynamic template generation center, responsible for receiving requests from the client, processing data, generating data sharing templates corresponding to specific motion types, and sending these templates back to the client for display. The client is a software application that the user directly operates, such as a mobile phone application or desktop software. In the context of this application, users can record and view motion data in the client, request and display data sharing templates generated by the server. The client is responsible for sending a template generation request to the server, and displaying the template content returned by the server in a user-friendly manner.
[0045] Optionally, a template generation request is an instruction initiated by a user through a client to request the generation of a data sharing template. The request usually contains key information such as the type of exercise and exercise data to characterize the style and content of the template that the user expects to generate. The server generates a template based on this information to ensure that the template matches the type of exercise the user is doing and can accurately display the relevant exercise data. The target user refers to a specific user who uses the client application and requests a data sharing template. In actual application scenarios, each user may participate in different types of exercise and have personalized sharing needs. Therefore, the system needs to identify and meet the specific needs of each target user and generate a unique data sharing template.
[0046] Optionally, the target sport type refers to the type of sport that the user is doing or wants to record, such as indoor running, outdoor cycling, swimming, fitness, etc. Different sport types may involve different data types and display requirements. For example, indoor running may need to display distance, time, speed, and calorie consumption, while swimming may focus more on displaying distance, time, swimming style, and calorie consumption. The server needs to select and configure appropriate stickers based on the target sport type to generate the associated data sharing template.
[0047] Optionally, a data sharing template is an interface design for displaying user sports data, which usually contains elements such as graphics, text, charts, and background images, and is used to present the user's sports results in an attractive way. The template can be requested and displayed by the client, and its content and style are dynamically generated by the server based on the user's sports data and sports type. Dynamic data sharing templates can better adapt to users' diverse sports scenarios and sharing needs, and provide more personalized display effects.
[0048] Step S202: Through the server, according to the target sport type, L stickers associated with the target sport type are obtained from the database.
[0049] Wherein, L is an integer greater than or equal to 1, and each sticker represents a template element.
[0050] Optionally, in this application, "stickers" refer to the various visual elements or components that make up the data sharing template, which can be pictures, icons, data charts, text boxes, etc. Each sticker represents a specific template element used to display a certain type of sports data or visual effects. For example, in a running sharing template, there may be a sticker for displaying the exercise distance, another sticker for displaying a line graph of exercise speed, and the third sticker may be a decorative pattern or logo to enhance the visual appeal of the template.
[0051] Optionally, the database stores sticker information related to various sports types, including sticker type, style, size, position, and hierarchical relationship. When the server receives a template generation request, it queries the database to obtain L corresponding stickers and their configuration information according to the sports type for dynamic template generation.
[0052] Optionally, the preset position of stickers refers to the default coordinates or layout of each sticker in the template, and the preset layer describes the front and back hierarchical relationship of stickers in visual effects. The server will combine L stickers into an ordered data layer based on these preset information to ensure the correct display of data and the coordination of visual effects. For example, sticker A may be preset in the upper left corner of the template, and sticker B may be preset below sticker A. In this way, when dynamically generating the template, the server will layout and overlay the stickers according to the preset position and layer relationship.
[0053] Optionally, when a user completes a sport in a sports application and chooses to share it, the client sends a template generation request to the server, which contains information about the target sport type. After receiving the request, the server queries the database for L stickers associated with the target sport type. For example, if the target sport type is indoor running, the server will look for stickers containing elements such as distance, time, speed charts, and calories burned, and combine these stickers in a specific order and layout into a data layer based on the preset position and preset layer information of each sticker to display running sports data. Finally, the server sends the combined data layer back to the client, and the client combines the data layer with other elements such as background images, borders, masks, etc. to generate a complete data sharing template for users to preview, edit, and share.
[0054] Step S203, when L is an integer greater than 1, L stickers are combined into a target data layer according to the preset position and preset layer of each sticker, wherein the target data layer is used to display the motion data and motion trajectory of the target user.
[0055] Optionally, the target data layer is a data combination layer generated on the server side and containing all L stickers. The server side lays out and stacks each independent sticker according to the preset position and layer relationship, and finally forms a complete display layer containing the target user's motion data and motion trajectory. The target data layer is the basis for the client to generate the final sharing template, which ensures that all motion data is displayed to the user in the correct format and layout. When L is greater than 1, the server will obtain multiple stickers matching the target motion type from the database. Then, the server places the stickers at the specified position of the template according to the preset position information of each sticker; at the same time, according to the preset layer information, the display order and visual hierarchy of the stickers are determined to ensure the consistency and clarity of the data display. This combination process is completed dynamically on the server side, without the need for additional development and configuration on the client side, which greatly improves the efficiency and flexibility of template generation.
[0056] For example, for the sport type of indoor running, the server may need to extract L = 4 stickers from the database, which are used to display the user's exercise distance, exercise time, exercise speed line graph, and calorie consumption circular chart. The server will combine these stickers into a target data layer according to their preset positions and layer relationships. Distance and time may be placed at the top of the template, the speed line graph in the middle, and the calorie consumption circular chart at the bottom, forming a top-down data display flow. At the same time, the server will ensure that the speed line graph is not covered by the distance and time numbers, and the calorie consumption chart will not block the line graph. By adjusting the layer relationship, all data is ensured to be clear, readable and visually harmonious.
[0057] Step S204: sending the target data layer to the client, wherein the client generates a data sharing template corresponding to the target user according to the target data layer.
[0058] Optionally, the server will send the combined target data layer to the client. After receiving the data layer, the client only needs to combine it with static elements such as background and border to generate a complete data sharing template for the target user to preview, edit and share to social media or save locally. This dynamic combination process not only improves the diversity of templates, but also optimizes the performance of the client, reduces the update frequency of the client, and improves the user experience.
[0059] Optionally, Figure 3 is a schematic diagram of an optional data sharing template according to an embodiment of the present application, such as Figure 3 As shown, the data sharing template can be a sharing card, including the data element "3.25 kilometers of indoor running" and a pattern element similar to a chrysanthemum. The data sharing template also includes control pattern elements such as "save to local".
[0060] Based on the contents of the above steps S201 to S204, it can be known that in the technical solution of the present application, the server can identify the target sport type of the target user according to the template generation request sent by the client, so that the generation of the sharing template is no longer limited to the fixed template preset by the client, but can dynamically generate corresponding templates according to different sport types, which greatly enhances the adaptability and extensibility of the sharing template. For example, the data types and formats required to be displayed for indoor running and outdoor cycling are different. The server can select the most suitable sticker combination according to the sport type and generate the data sharing template that best fits the sport. Secondly, L stickers related to the target sport type are obtained through the server query, and are combined according to the preset position and preset layer of each sticker to form a target data layer. This process realizes the flexible combination of template elements, so that the data sharing template can be customized according to the characteristics of the sports data and the user's preferences, which improves the personalization and practicality of the template. For example, users can choose to put the exercise distance at the top, the exercise time at the bottom, or integrate the exercise trajectory into the background instead of adopting a fixed layout.
[0061] In an optional embodiment, before querying the database to obtain L stickers associated with the target motion type according to the target motion type, the server may generate N stickers, where N is an integer greater than 1, and the types of stickers include at least a first type and a second type, where the first type of stickers are used to represent data elements, and the second type of stickers are used to represent pattern elements. Then, sticker attributes are set for each sticker, where the sticker attributes are used to determine whether the sticker can be rotated, dragged, and scaled. Finally, the N stickers and the sticker attributes of the stickers are stored in the database.
[0062] Optionally, the first type of stickers is specifically used to represent data elements, such as exercise distance, speed, calories burned, etc. This type of sticker can be dynamically filled with content based on the user's exercise data, and is the core part of displaying exercise results in the sharing template. The second type of stickers is used to represent pattern elements, such as decorative icons, dynamic images, background images, etc. This type of sticker adds visual appeal to the template, helping users personalize their shared content to make it more vivid and interesting.
[0063] Optionally, for each generated sticker, the server sets sticker attributes, which define the interactive capabilities of the sticker on the client, including but not limited to: whether it can be rotated, dragged, and scaled. After setting the sticker attributes, the server stores N stickers and their attributes in the database. The role of the database is to centrally manage the metadata of these stickers, including type, style, size, attributes, etc., to ensure that when a template needs to be dynamically generated according to a certain target sport type, the corresponding sticker can be quickly retrieved and called.
[0064] For example, the server may have generated N stickers for indoor running in advance, including a circular chart sticker (type 1, used to show calories burned), a line chart sticker (type 1, used to show changes in exercise speed), a running shoe icon sticker (type 2, used for decoration), a motion track sticker (type 1, used to show the running route), etc. Each sticker has its own specific property settings, such as the line chart sticker can be rotated and scaled, and the running shoe icon sticker can be dragged to adjust the position but cannot be rotated.
[0065] In an optional embodiment, after storing the N stickers and the sticker attributes of the stickers in the database, the server may also generate a configuration file, wherein the configuration file is used to establish an association relationship between any sport type and at least one sticker. Then, the server generates a style file corresponding to any sport type in the client according to the configuration file, wherein the style file includes the sticker attributes of the stickers associated with the sport type.
[0066] Optionally, the role of the configuration file is to establish an association between different types of sports and stickers. The configuration file records which stickers are needed for each type of sports, as well as the preset positions and layer relationships of these stickers in the sharing template. It should be noted that in the configuration file, the establishment of the association is achieved by associating a specific type of sports with at least one sticker. For example, indoor running may be associated with stickers that display distance, time, speed line graphs, and calorie consumption pie charts; while outdoor cycling may be associated with stickers that display distance, average speed, altitude change graphs, and pictures of scenery along the way. This kind of association setting enables the server to call and combine data stickers and pattern stickers suitable for the sport according to the different types of sports, providing users with sharing templates that accurately match their sports results.
[0067] Optionally, the server can generate a style file for the client based on the association relationship generated by the configuration file. The style file contains the sticker attributes corresponding to the sport type, such as the sticker's ability to rotate, drag, and scale, as well as the sticker's preset position and display level in the template. After receiving the style file, the client can combine the sticker elements in the database into a data sharing template according to the preset rules and sport type requirements based on the attributes and layout information in the file, without the need for additional version updates.
[0068] In an optional embodiment, when L is an integer greater than 1, according to the preset position and preset layer of each sticker, L stickers are combined into a target data layer, including: obtaining the interface size of the display interface of the client through the server, and then determining the size of each sticker in the L stickers according to the interface size. Finally, according to the preset position and preset layer of each sticker, the server combines the L stickers into the target data layer according to the size of each sticker.
[0069] Optionally, when the server receives the template generation request from the client, it first obtains the specific size of the client display interface, that is, the screen resolution or device size information. This is because different client devices, such as smartphones, tablets or PCs, may have different screen sizes and resolutions, and the display effect of the shared template should be as consistent as possible on various devices to avoid layout problems or reading inconvenience caused by size mismatch. Once the server obtains the interface size of the client, the server can dynamically calculate the size of each sticker based on this information. This calculation is based on the preset size and proportion of the sticker and the actual size of the client screen. Through appropriate scaling and adjustment, it ensures that the sticker is fully displayed on the client interface and is in harmony with the overall layout. For example, if a circular chart sticker is preset to a diameter of 10cm, the server will adjust this size according to the client's screen size to ensure that it does not look too crowded on a small-screen device or appear empty on a large-screen device.
[0070] Finally, the server will combine L stickers into the target data layer according to the preset position and preset layer of each sticker, combined with the calculated size. The preset position ensures the fixed coordinates of the sticker in the template, while the preset layer defines the display order of the stickers, determining which elements are in front and which elements are in the back to avoid visual occlusion. Through this process, the data layer dynamically generated by the server can perfectly adapt to the interface size of the client, whether it is a small-screen mobile phone or a large-screen display, it can present a beautiful and clear data sharing template.
[0071] For example, assuming that the screen width of the client device is 360px, the server adjusts the diameter of the circular chart sticker (used to show calorie consumption) to fit the screen size based on this information, while ensuring that the sticker is located in the preset upper left corner and is not blocked by other stickers. For the line chart sticker (used to show speed changes), the server may adjust its height to one-third of the screen height, and the width is automatically scaled according to the screen width to ensure that the entire line chart can be fully displayed while maintaining an appropriate proportion to the interface size.
[0072] Finally, the server sends the L resized stickers to the client according to the preset positions and layer relationships. After receiving the target data layer, the client combines it with other static elements such as the background and border to generate the final data sharing template. This dynamic size adjustment mechanism ensures the adaptability and aesthetics of the sharing template on different client devices, allowing users to obtain a consistent and high-quality sharing experience regardless of the device they use. At the same time, the technical solution of the present application also provides greater flexibility for the server, and can quickly respond to size differences between different devices. There is no need to frequently update client applications, which reduces maintenance costs and improves user experience and application compatibility.
[0073] In an optional embodiment, sending the target data layer to the client includes: sending the target data layer and at least one template element to the client, wherein the client generates a data sharing template corresponding to the target user according to the target data layer and the at least one template element, and the at least one template element includes:
[0074] The first element is used to represent the border of the data sharing template corresponding to the target user;
[0075] The second element is used to represent the background image of the data sharing template corresponding to the target user;
[0076] The third element is a mask used to represent the data sharing template corresponding to the target user;
[0077] The fourth element is used to represent the image sticker used in conjunction with the target data layer in the data sharing template corresponding to the target user.
[0078] Optionally, after receiving the target data layer and at least one template element sent by the server, the client will combine the border, background image, mask and image sticker with the target data layer according to the attribute information of the template element. For example, first, the client applies the border element to create the outer frame of the template around the target data layer; then, load the background image element as the background of the template; then, adjust the transparency and shape of the mask according to the mask element and add it to the template; finally, place the image sticker in a preset position to coordinate the layout with the data sticker. Through this sequence of steps, the client finally generates a data sharing template corresponding to the target user.
[0079] Optionally, a border is a decorative element around the data sharing template, used to highlight the template content and enhance the visual effect. The background image, as the visual base of the sharing template, provides a rich background environment for the data sharing content. A mask is an overlay with adjustable transparency, used to create specific visual effects in the template, such as gradients, blurs, or highlighting focal areas. Image stickers are image elements used in templates to decorate or assist in data display. Unlike data stickers in the data layer, image stickers are mainly used to increase the fun and aesthetics of the template.
[0080] In an optional embodiment, when L is equal to 1, a sticker obtained by querying the database is used as the target data layer.
[0081] Optionally, if the server only obtains a sticker from the database, the sticker can be directly used as the target data layer.
[0082] In an optional embodiment, Figure 4 is a flow chart of an optional processing method of a motion data sharing template according to an embodiment of the present application, such as Figure 4 As shown, the following steps are included:
[0083] First, data sticker data is generated in the preparation stage by configuring the background, including: creating data stickers, wherein the data items (sticker attributes) of the data stickers also need to be set during the creation process, such as whether they can be rotated, dragged, etc. Then, the generated data stickers are stored in the database.
[0084] It should be noted that, during the preparation stage, the client can also generate a style file according to the sticker template type and place the style file in the source code, wherein the style file includes at least specific data items of the data sticker, such as whether it can be rotated, dragged, and other attribute information.
[0085] Alternatively, if Figure 4 As shown, when creating an interface template (i.e., a data sharing template), the user first initiates a request to start generating the template creation (i.e., a template generation request) in the client, which is used to request the server to obtain dynamic data. After receiving the client request, the server obtains data stickers and required dynamic images (e.g., L stickers) from the database according to the requested category (i.e., the target motion type in the template generation request). The server then assembles the acquired data (L stickers) into a target data layer and returns the target data layer to the client. It should be noted that the server can also store the acquired dynamic stickers in a dynamic sticker production center (which can be understood as a program with storage function), and then send the dynamic stickers to the client through the dynamic sticker production center.
[0086] Alternatively, if Figure 4As shown, when the client loads the interface, the client can parse the target data layer sent by the server, obtain each sticker and the corresponding sticker attributes that make up the target data layer, and then render each sticker obtained by parsing according to the client's built-in style file, so that the target data layer can be displayed in the client. It should be noted that the client can also load the picture sent by the dynamic sticker production center and display the picture together with the rendered target data layer.
[0087] It should be noted that in traditional technologies, adding new template styles or adjusting existing templates requires the client to re-release the version, which is not only time-consuming, but may also affect the user experience due to compatibility issues caused by version updates. In the present application scheme, the adjustment of template styles and element layouts is mainly completed on the server side. The client only needs to receive the target data layer sent by the server and generate a data sharing template based on it. This avoids frequent client updates and improves development efficiency and user satisfaction. In addition, the dynamically generated data sharing template can more accurately reflect the user's motion data and motion trajectory, while allowing users to make customized choices based on motion types and personal preferences. This not only provides a richer visual experience, but also increases the fun and attractiveness of sharing, thereby stimulating users' willingness to share motion data and promoting community interaction and user stickiness.
[0088] It can be seen that the mechanism of dynamically generating templates on the server side facilitates content innovation and template iteration. Product teams can try and launch new template designs more quickly without waiting for the client version update cycle, which helps to maintain the vitality and competitiveness of the application and meet the ever-changing needs of users. In addition, the client no longer needs to be updated frequently to adapt to new template styles or sports types, reducing development workload and version maintenance costs. At the same time, centralized configuration and generation on the server side also simplifies template management and reduces the complexity and cost of long-term operations.
[0089] According to another aspect of the embodiment of the present application, a method for displaying a sports data sharing template is also provided, wherein: Figure 5 It is a flowchart of an optional method for displaying a sports data sharing template according to an embodiment of the present application.
[0090] like Figure 5 As shown, the following steps are included:
[0091] Step S501: Send a template generation request to the server through the client.
[0092] In step S501 , the template generation request is used to indicate that the target user desires to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates.
[0093] Optionally, the execution subject of the display method of the motion data sharing template can be a client, wherein the client is a software application directly operated by the user, such as a mobile phone application or desktop software. In the context of this application, the user can record and view motion data in the client, request and display the data sharing template generated by the server. The client is responsible for sending a template generation request to the server, and displaying the template content returned by the server in a user-friendly manner.
[0094] In addition, the server mentioned above refers to a system or program that provides data processing, logical operations, and resource management functions in the Internet architecture, usually running on a remote server. In this application, the server plays the role of a dynamic template generation center, responsible for receiving client requests, processing data, generating data sharing templates corresponding to specific sports types, and sending these templates back to the client for display.
[0095] Step S502: receiving a target data layer generated by the server according to the target motion type.
[0096] In step S502, the target data layer is used to display the motion data and motion trajectory of the target user. The target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker based on the query, where L is an integer greater than or equal to 1, and each sticker represents a template element.
[0097] Optionally, the target data layer is a data combination layer generated on the server side and containing all L stickers. The server side lays out and stacks each independent sticker according to the preset position and layer relationship, and finally forms a complete display layer containing the target user's motion data and motion trajectory. The target data layer is the basis for the client to generate the final sharing template, which ensures that all motion data is displayed to the user in the correct format and layout. When L is greater than 1, the server will obtain multiple stickers matching the target motion type from the database. Then, the server places the stickers at the specified position of the template according to the preset position information of each sticker; at the same time, according to the preset layer information, the display order and visual hierarchy of the stickers are determined to ensure the consistency and clarity of the data display. This combination process is completed dynamically on the server side, without the need for additional development and configuration on the client side, which greatly improves the efficiency and flexibility of template generation.
[0098] For example, for the sport type of indoor running, the server may need to extract L = 4 stickers from the database, which are used to display the user's exercise distance, exercise time, exercise speed line graph, and calorie consumption circular chart. The server will combine these stickers into a target data layer according to their preset positions and layer relationships. Distance and time may be placed at the top of the template, the speed line graph in the middle, and the calorie consumption circular chart at the bottom, forming a top-down data display flow. At the same time, the server will ensure that the speed line graph is not covered by the distance and time numbers, and the calorie consumption chart will not block the line graph. By adjusting the layer relationship, all data is ensured to be clear, readable and visually harmonious.
[0099] Optionally, in this application, "stickers" refer to the various visual elements or components that make up the data sharing template, which can be pictures, icons, data charts, text boxes, etc. Each sticker represents a specific template element used to display a certain type of sports data or visual effects. For example, in a running sharing template, there may be a sticker for displaying the exercise distance, another sticker for displaying a line graph of exercise speed, and the third sticker may be a decorative pattern or logo to enhance the visual appeal of the template.
[0100] Optionally, the database stores sticker information related to various sports types, including sticker type, style, size, position, and hierarchical relationship. When the server receives a template generation request, it queries the database to obtain L corresponding stickers and their configuration information according to the sports type for dynamic template generation.
[0101] Optionally, the preset position of stickers refers to the default coordinates or layout of each sticker in the template, and the preset layer describes the front and back hierarchical relationship of stickers in visual effects. The server will combine L stickers into an ordered data layer based on these preset information to ensure the correct display of data and the coordination of visual effects. For example, sticker A may be preset in the upper left corner of the template, and sticker B may be preset below sticker A. In this way, when dynamically generating the template, the server will layout and overlay the stickers according to the preset position and layer relationship.
[0102] Optionally, when a user completes a sport in a sports application and chooses to share it, the client sends a template generation request to the server, which contains information about the target sport type. After receiving the request, the server queries the database for L stickers associated with the target sport type. For example, if the target sport type is indoor running, the server will look for stickers containing elements such as distance, time, speed charts, and calories burned, and combine these stickers in a specific order and layout into a data layer based on the preset position and preset layer information of each sticker to display running sports data. Finally, the server sends the combined data layer back to the client, and the client combines the data layer with other elements such as background images, borders, masks, etc. to generate a complete data sharing template for users to preview, edit, and share.
[0103] Step S503: The client generates a data sharing template corresponding to the target user according to the target data layer and displays it.
[0104] Optionally, the server will send the combined target data layer to the client. After receiving the data layer, the client only needs to combine it with static elements such as background and border to generate a complete data sharing template for the target user to preview, edit and share to social media or save locally. This dynamic combination process not only improves the diversity of templates, but also optimizes the performance of the client, reduces the update frequency of the client, and improves the user experience.
[0105] In an optional embodiment, the client generates and displays a data sharing template corresponding to the target user based on the target data layer, including: the client parses each sticker in the target data layer based on a style file corresponding to the target sport type built into the client, wherein the style file includes sticker attributes of stickers associated with the target sport type. Then, the client renders each sticker in the target data layer in the display interface of the client according to the sticker attributes of each sticker recorded in the style file, obtains and displays the data sharing template corresponding to the target user.
[0106] Optionally, the server can generate a style file for the client based on the association relationship generated by the configuration file. The style file contains the sticker attributes corresponding to the sport type, such as the ability of stickers to be rotated, dragged, and scaled, as well as the preset position and display level of stickers in the template. After receiving the style file, the client can combine the sticker elements in the database into a data sharing template according to the preset rules and sport type requirements based on the attributes and layout information in the file, without the need for additional version updates. When the client loads the interface, the client can parse the target data layer sent by the server, obtain each sticker and the corresponding sticker attributes that make up the target data layer, and then render each sticker obtained by parsing according to the client's built-in style file, so that the target data layer can be displayed in the client.
[0107] As can be seen from the above content, in the technical solution of the present application, the server can generate a request for a template sent by the client to identify the target sport type of the target user, so that the generation of the sharing template is no longer limited to the fixed template preset by the client, but can dynamically generate corresponding templates according to different sport types, which greatly enhances the adaptability and extensibility of the sharing template. For example, the data types and formats required to be displayed for indoor running and outdoor cycling are different. The server can select the most suitable sticker combination according to the sport type and generate the data sharing template that best fits the sport. Secondly, L stickers related to the target sport type are obtained through the server query, and are combined according to the preset position and preset layer of each sticker to form a target data layer. This process realizes the flexible combination of template elements, so that the data sharing template can be customized according to the characteristics of the sports data and the user's preferences, which improves the personalization and practicality of the template. For example, users can choose to put the exercise distance at the top, the exercise time at the bottom, or integrate the exercise trajectory into the background, instead of adopting a fixed layout.
[0108] According to another aspect of the embodiment of the present application, a device for generating a motion data sharing template is also provided, wherein: Figure 6 is a schematic diagram of an optional device for generating a motion data sharing template according to an embodiment of the present application, such as Figure 6 As shown, the device for generating a motion data sharing template includes: an extracting unit 601 , a querying unit 602 , a combining unit 603 , and a sending unit 604 .
[0109] An extraction unit 601 is used to extract the target motion type of the target user from a template generation request sent by a client through a server, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target motion type on the client, and different motion types correspond to different data sharing templates; a query unit 602 is used to query from a database through a server according to the target motion type to obtain L stickers associated with the target motion type, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; a combination unit 603 is used to combine the L stickers into a target data layer according to a preset position and a preset layer of each sticker when L is an integer greater than 1, wherein the target data layer is used to display the motion data and motion trajectory of the target user; a sending unit 604 is used to send the target data layer to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer.
[0110] Optionally, the motion data sharing template generation device further includes: a second generation unit, a first processing unit, and a second processing unit. The second generation unit is used to generate N stickers, wherein N is an integer greater than 1, and the types of stickers include at least a first type and a second type, the first type of stickers are used to represent data elements, and the second type of stickers are used to represent pattern elements; the first processing unit is used to set sticker attributes for each sticker, wherein the sticker attributes are used to determine whether the sticker can be rotated, dragged, and scaled; the second processing unit is used to store the N stickers and the sticker attributes of the stickers in a database.
[0111] Optionally, the device for generating a sports data sharing template further includes: a third generating unit and a fourth generating unit. The third generating unit is used to generate a configuration file, wherein the configuration file is used to establish an association relationship between any sports type and at least one sticker; the fourth generating unit is used to generate a style file corresponding to any sports type in the client according to the configuration file, wherein the style file includes sticker attributes of stickers associated with the sports type.
[0112] Optionally, the combination unit 603 includes: a first acquisition subunit, a first determination subunit, and a first combination subunit. The first acquisition subunit is used to acquire the interface size of the display interface of the client; the first determination subunit is used to determine the size of each sticker in the L stickers according to the interface size; the first combination subunit is used to combine the L stickers into a target data layer according to the preset position and preset layer of each sticker and the size of each sticker through the server.
[0113] Optionally, the sending unit 604 includes: a first sending sub-unit, used to send the target data layer and at least one template element to the client, wherein the client generates a data sharing template corresponding to the target user based on the target data layer and the at least one template element, and the at least one template element includes: a first element, used to represent the border of the data sharing template corresponding to the target user; a second element, used to represent the background image of the data sharing template corresponding to the target user; a third element, used to represent the mask of the data sharing template corresponding to the target user; and a fourth element, used to represent the image sticker in the data sharing template corresponding to the target user that is used in conjunction with the target data layer.
[0114] Optionally, the device for generating a sports data sharing template further includes: a third processing unit, configured to, when L is equal to 1, use a sticker obtained by querying from the database as a target data layer.
[0115] According to another aspect of the embodiment of the present application, a display device for a sports data sharing template is also provided, wherein: Figure 7 is a schematic diagram of a display device of an optional sports data sharing template according to an embodiment of the present application, such as Figure 7 As shown, the display device of the sports data sharing template includes: a request sending unit 701, a receiving unit 702, and a display unit 703.
[0116] A request sending unit 701 is used to send a template generation request to a server through a client, wherein the template generation request is used to represent that the target user expects to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates; a receiving unit 702 is used to receive a target data layer generated by the server according to the target sport type, wherein the target data layer is used to display the sport data and sport trajectory of the target user, and the target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker according to the query, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; a display unit 703 is used to generate a data sharing template corresponding to the target user through the client according to the target data layer and display it.
[0117] Optionally, the display unit 703 includes: a first processing subunit and a second processing subunit. The first processing subunit is used to parse each sticker in the target data layer through the client according to a style file corresponding to the target sport type built in the client, wherein the style file includes sticker attributes of stickers associated with the target sport type; the second processing subunit is used to render each sticker in the target data layer in the display interface of the client according to the sticker attributes of each sticker recorded in the style file, obtain the data sharing template corresponding to the target user and display it.
[0118] An embodiment of the present application may provide an electronic device, Figure 8 is a structural block diagram of an electronic device according to an embodiment of the present application. Figure 8 As shown, the electronic device may include: one or more ( Figure 8 Only one is shown) a processor, a memory, a storage controller, and a peripheral interface, wherein the peripheral interface is connected to a radio frequency module, an audio module, and a display.
[0119] Among them, the memory can be used to store software programs and modules, such as program instructions / modules corresponding to the methods and devices in the embodiments of the present application, and the processor executes various functional applications and data processing by running the software programs and modules stored in the memory, that is, realizing the display method of the above-mentioned motion data sharing template and / or the generation method of the motion data sharing template. The memory may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0120] It can be understood by those skilled in the art that Figure 8 The structure shown is for illustration only, and the electronic device may also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (Mobile Internet Devices, MID), a PAD, or other terminal devices. Figure 8 The structure of the electronic device is not limited. Figure 8 More or fewer components (such as network interfaces, display devices, etc.) shown in, or having Figure 8 Different configurations are shown.
[0121] A person of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing the hardware related to the terminal device through a program, and the program can 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 magnetic disk or an optical disk, etc.
[0122] According to another aspect of the present application, a computer-readable storage medium is also provided, wherein a computer program is stored in the computer-readable storage medium, wherein when the computer program is executed, the device where the computer-readable storage medium is located executes the above-mentioned method for generating a motion data sharing template and the method for displaying a motion data sharing template.
[0123] The above-mentioned embodiments or examples disclosed in the present application are not exhaustive, but are only illustrative of some embodiments or examples, and are not intended to be specific limitations on the scope of protection disclosed in the present application. In the absence of contradiction, each step in a certain embodiment or example in the present application can be implemented as an independent example, and the steps can be combined arbitrarily. For example, the scheme after removing some steps in a certain embodiment or example can also be implemented as an independent example, and the order of the steps in a certain embodiment or example can be arbitrarily exchanged. In addition, the optional methods or optional examples in a certain embodiment or example can be combined arbitrarily; in addition, the various embodiments or examples can be combined arbitrarily, for example, some or all steps of different embodiments or examples can be combined arbitrarily, and a certain embodiment or example can be combined arbitrarily with the optional methods or optional examples of other embodiments or examples.
[0124] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0125] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0126] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of units can be 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.
[0127] 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 over multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0128] In addition, each functional unit in each embodiment of the present application 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.
[0129] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, 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 a computer device (which can be a personal computer, server or network device, etc.) to perform all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk, etc. Various media that can store program codes.
[0130] The above are only preferred implementations of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A method for generating a sports data sharing template, characterized in that: include: Extracting, by the server, a target sport type of a target user from a template generation request sent by a client, wherein the template generation request is used to indicate that the target user desires to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates; Through the server, according to the target sport type, query from a database to obtain L stickers associated with the target sport type, where L is an integer greater than or equal to 1, and each sticker represents a template element; When L is an integer greater than 1, the L stickers are combined into a target data layer according to the preset position and preset layer of each sticker, wherein the target data layer is used to display the motion data and motion trajectory of the target user; The target data layer is sent to the client, wherein the client generates a data sharing template corresponding to the target user according to the target data layer.
2. The method for generating a sports data sharing template according to claim 1, characterized in that: Before obtaining L stickers associated with the target sport type from a database according to the target sport type, the method for generating the sport data sharing template further includes: Generate N stickers, where N is an integer greater than 1, and the types of the stickers include at least a first type and a second type, the first type of stickers are used to represent data elements, and the second type of stickers are used to represent pattern elements; Setting sticker attributes for each of the stickers, wherein the sticker attributes are used to determine whether the sticker can be rotated, dragged, and scaled; The N stickers and the sticker attributes of the stickers are stored in the database.
3. The method for generating a sports data sharing template according to claim 2, characterized in that: After storing the N stickers and the sticker attributes of the stickers in the database, the method for generating the sports data sharing template further includes: Generate a configuration file, wherein the configuration file is used to establish an association relationship between any type of sport and at least one sticker; A style file corresponding to any one type of sport is generated in the client according to the configuration file, wherein the style file includes sticker attributes of stickers associated with the sport type.
4. The method for generating a sports data sharing template according to claim 1, characterized in that: When L is an integer greater than 1, the L stickers are combined into a target data layer according to the preset position and preset layer of each sticker, including: Obtaining the interface size of the display interface of the client; Determine the size of each of the L stickers according to the interface size; According to the preset position and preset layer of each sticker, the server combines the L stickers into the target data layer according to the size of each sticker.
5. The method for generating a sports data sharing template according to claim 1, characterized in that: Sending the target data layer to the client includes: The target data layer and at least one template element are sent to the client, wherein the client generates a data sharing template corresponding to the target user according to the target data layer and the at least one template element, wherein the at least one template element includes: The first element is used to represent the border of the data sharing template corresponding to the target user; The second element is used to represent the background image of the data sharing template corresponding to the target user; The third element is used to represent the mask of the data sharing template corresponding to the target user; The fourth element is used to represent the image sticker used in conjunction with the target data layer in the data sharing template corresponding to the target user.
6. The method for generating a sports data sharing template according to claim 1, characterized in that: After obtaining L stickers associated with the target sport type from a database according to the target sport type, the method for generating the sport data sharing template further includes: When L is equal to 1, a sticker obtained from the database is used as the target data layer.
7. A method for displaying a sports data sharing template, characterized in that: include: Sending a template generation request to the server through the client, wherein the template generation request is used to indicate that the target user desires to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates; Receive a target data layer generated by the server according to the target motion type, wherein the target data layer is used to display the motion data and motion trajectory of the target user, and the target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker according to the query, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; The client generates a data sharing template corresponding to the target user according to the target data layer and displays it.
8. The method for displaying a sports data sharing template according to claim 7, characterized in that: Generating, by the client according to the target data layer, a data sharing template corresponding to the target user and displaying the template, including: By means of the client, according to a style file corresponding to the target sport type built in the client, each sticker in the target data layer is parsed, wherein the style file includes sticker attributes of the sticker associated with the target sport type; According to the sticker attributes of each sticker recorded in the style file, each sticker in the target data layer is rendered in the display interface of the client, and the data sharing template corresponding to the target user is obtained and displayed.
9. A device for generating a sports data sharing template, characterized in that: include: An extraction unit, through a server, extracts a target sport type of a target user from a template generation request sent by a client, wherein the template generation request is used to indicate that the target user desires to generate a data sharing template corresponding to the target sport type on the client, and different sport types correspond to different data sharing templates; A query unit, through a server, queries a database according to the target sport type to obtain L stickers associated with the target sport type, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; a combining unit, when L is an integer greater than 1, combining the L stickers into a target data layer according to a preset position and a preset layer of each sticker, wherein the target data layer is used to display the motion data and motion trajectory of the target user; A sending unit sends the target data layer to the client, wherein the client generates a data sharing template corresponding to the target user according to the target data layer.
10. A display device for a sports data sharing template, characterized in that: include: A request sending unit, sending a template generation request to a server through a client, wherein the template generation request is used to indicate that a target user desires to generate a data sharing template corresponding to a target sport type on the client, and different sport types correspond to different data sharing templates; A receiving unit receives a target data layer generated by the server according to the target motion type, wherein the target data layer is used to display the motion data and motion trajectory of the target user, and the target data layer is composed of L stickers obtained by the server according to the preset position and preset layer of each sticker according to the query, wherein L is an integer greater than or equal to 1, and each sticker represents a template element; The display unit generates a data sharing template corresponding to the target user according to the target data layer through the client and displays it.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located executes the method for generating a motion data sharing template as described in any one of claims 1 to 6 and the method for displaying a motion data sharing template as described in any one of claims 7 to 8.
12. An electronic device, characterized in that: It includes one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the method for generating a motion data sharing template as described in any one of claims 1 to 6 and the method for displaying a motion data sharing template as described in any one of claims 7 to 8.
Citation Information
Patent Citations
Moving target pose tracking method and device
CN111192293A
Sticker processing method, device, electronic equipment and storage medium
CN112084750A
Data sticker generation for sports
CN117915992A
Semiconductor memory device maintaining verification data during program suspend, and method for operating thereof
KR1020230136482A
Method and system for creating stickers from user-generated content
US20240104808A1