Trajectory playback method, device, electronic device, storage medium and program product
By segmenting the tracks and dynamically configuring the playback speed, the problem that track playback cannot feedback the change in the point residence time and speed in the prior art is solved, and a more dynamic track playback experience is achieved.
Patent Information
- Application Number
- CN202210556639.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-19
- Publication Date
- 2025-07-25
- Estimated Expiration
- 2042-05-19
AI Technical Summary
In the prior art, the trajectory playback method cannot feedback the changes in the time and travel speed of the object staying at the point under dense acquisition, making it difficult to view the travel trajectory of the object.
By segmenting the target track into several segmented tracks, and determining its playback speed based on any two positioning points in each segmented track, dynamically configure the playback speed of each segmented track to achieve dynamic track playback.
It realizes the time and travel speed of the object staying at the point during the trajectory playback, and improves the experience of trajectory playback.
Smart Images

Figure CN114969230B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of map technology. Specifically, this application relates to a trajectory playback method, apparatus, electronic device, storage medium, and program product. Background Art
[0002] Trajectory playback plays an important role in aspects such as data traceability, data rectification, and analysis and decision-making. In the prior art, trajectory playback generally adopts a static marking method. Among them, the static marking method marks each collected point in sequence and connects the points in sequence to achieve the effect of viewing the trajectory.
[0003] However, although the static marking method can display the trajectory points and trajectory routes of an object, in the case of dense collection, the points are dense, making it difficult to view the moving trajectory of the object, and it is also impossible to feedback the time the object stays at the points and the change in the moving speed, that is, only static trajectory playback can be achieved in the prior art. Summary of the Invention
[0004] The purpose of this application is to provide a trajectory playback method, apparatus, electronic device, and storage medium to achieve dynamic trajectory playback. To achieve this purpose, the technical solutions provided in the embodiments of this application are as follows:
[0005] In a first aspect, an embodiment of this application provides a trajectory playback method, which includes:
[0006] In response to a playback operation for a target trajectory, take the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory;
[0007] When the travel data of the current segmented trajectory is played out, play the travel data of the next segmented trajectory until the target trajectory playback ends;
[0008] Wherein, each segmented trajectory is obtained by splitting a number of positioning points included in the target trajectory, the playback speed of each segmented trajectory is determined based on any two positioning points in this segmented trajectory, and the end point of the current segmented trajectory is the starting point of the next segmented trajectory.
[0009] In a second aspect, an embodiment of this application further provides a trajectory playback apparatus, which includes:
[0010] A playback module, configured to, in response to a playback operation for a target trajectory, take the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory; when the travel data of the current segmented trajectory is played out, play the travel data of the next segmented trajectory until the target trajectory playback ends;
[0011] Among them, each segmented trajectory is obtained by dividing a number of positioning points included in the target trajectory. The playback speed of each segmented trajectory is determined based on any two positioning points in the segmented trajectory, and the end point of the current segmented trajectory is the start point of the next segmented trajectory.
[0012] In a third aspect, the present application further provides an electronic device, which includes a memory and a processor. Among them, a computer program is stored in the memory; when the processor runs the computer program, it is used to execute the method provided in any optional embodiment of the present application.
[0013] In a fourth aspect, the present application further provides a computer-readable storage medium, in which a computer program is stored. When the computer program runs in a processor, the processor is used to execute the method provided in any optional embodiment of the present application.
[0014] In a fifth aspect, the present application provides a computer program product, which includes a computer program. When the computer program is executed by a processor, it implements the method provided in any optional embodiment of the present application.
[0015] The beneficial effects brought by the technical solution provided by the present application are as follows:
[0016] The trajectory playback method provided by the embodiment of the present application. Specifically, when responding to a playback operation for a target trajectory, the first segmented trajectory of the target trajectory is used as the current segmented trajectory, and the travel data of this segmented trajectory is played starting from the start point of the current segmented trajectory; when the travel data of the current segmented trajectory is played out, the start point of the next segmented trajectory can be determined based on the end point of the current segmented trajectory, and then the travel data of the next segmented trajectory is played. At this time, the next segmented trajectory replaces the current segmented trajectory until the target trajectory playback ends; among them, since each segmented trajectory is obtained by dividing a number of positioning points included in the target trajectory, that is, a target trajectory can be divided into several segmented trajectories based on positioning points, and each segmented trajectory has its own corresponding start point and end point. On this basis, the playback speed of each segmented trajectory is determined based on any two positioning points in the segmented trajectory; that is, the playback speeds of each segmented trajectory are different. The implementation of the present application realizes dynamic trajectory playback by dynamically configuring the playback speed of each segmented trajectory. Dynamic trajectory playback can reflect the time the object stays at a point, the speed change during the travel process, etc., and improve the experience of trajectory playback.
[0017] The additional aspects and advantages of the present application will be partially given in the following description, and these will become obvious from the following description, or will be understood through the practice of the present application. Description of the Drawings
[0018] To more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the accompanying drawings required for the description of the embodiments of the present application.
[0019] Figure 1 Schematic flowchart of a trajectory playback method provided by an embodiment of the present application;
[0020] Figure 2 Schematic diagram of an operating environment provided by an embodiment of the present application;
[0021] Figure 3 Schematic diagram of an interface corresponding to the initial state of trajectory playback provided by an embodiment of the present application;
[0022] Figure 4 Schematic diagram of an interface for trajectory playback with the original trajectory as the target trajectory provided by an embodiment of the present application;
[0023] Figure 5 Schematic diagram of an interface with a selection window displayed provided by an embodiment of the present application;
[0024] Figure 6 Schematic diagram of an interface with the positioning points included in the original trajectory displayed provided by an embodiment of the present application;
[0025] Figure 7 Schematic diagram of an interface for trajectory playback by intercepting the target trajectory from the original trajectory provided by an embodiment of the present application;
[0026] Figure 8 Another schematic diagram of an interface for trajectory playback by intercepting the target trajectory from the original trajectory provided by an embodiment of the present application;
[0027] Figure 9 Schematic diagram of the structure of a trajectory playback device provided by an embodiment of the present application;
[0028] Figure 10 Schematic diagram of the structure of an electronic device provided by an embodiment of the present application. Detailed implementation manners
[0029] The following will describe in detail the embodiments of the present application. The examples of the embodiments are shown in the accompanying drawings, where the same or similar reference numerals represent the same or similar elements or elements with the same or similar functions from beginning to end. The embodiments described below by referring to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be construed as a limitation of the present invention.
[0030] Those skilled in the art can understand that, unless specifically stated otherwise, the singular forms "a", "an", "the" and "said" used herein may also include the plural forms. It should be further understood that the term "comprising" used in the specification of this application means the presence of the described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or their groups. It should be understood that when we say an element is "connected" or "coupled" to another element, it can be directly connected or coupled to other elements, or there may also be intermediate elements. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The term "and / or" used herein includes all or any unit and all combinations of one or more of the associated listed items.
[0031] This application is directed to the problem that in the existing solutions, during the application of the trajectory playback function, generally only each collected point can be marked in sequence and connected in sequence to achieve the effect of viewing the trajectory. In the case of dense collection, the points are dense, making it difficult to view the travel trajectory of the object, and it is also impossible to feedback the time the object stays at the points and the change in the travel speed. A trajectory playback method, device, equipment, storage medium and program product are proposed. Based on the implementation of this solution, dynamic trajectory playback can be achieved.
[0032] The solution of the embodiment of this application relates to an intelligent transportation system and can be applied to scenarios such as outdoor navigation (such as driving / cycling / walking navigation), indoor navigation, food delivery, online car-hailing, etc. Based on the solution of the embodiment of this application, dynamic trajectory playback can be achieved. For example, in the food delivery scenario, through the trajectory playback function, the stay time of the delivery person at each point in the travel trajectory of food delivery and the change in speed during the travel process can be understood.
[0033] The following will specifically describe the technical solution of this application and how the technical solution of this application solves the above technical problems with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of this application will be described below with reference to the accompanying drawings.
[0034] Figure 1 The flowchart of a trajectory playback method provided by the embodiment of this application is shown. This method can be executed by any electronic device, such as a terminal. The terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a vehicle-mounted device, a detector, etc., but is not limited thereto.
[0035] Such as Figure 2As shown in the figure, the implementation of the embodiments of the present application may involve a terminal 20, a server 10, a network 30, and a database 40. Among them, the terminal 20 and the server 10 may be connected through the network 30. When the terminal 20 requests data from the server 10 (such as obtaining the travel data of the target trajectory), the server 10 may call the data stored in the database 40 and feedback it to the terminal 20.
[0036] The embodiments of the present application provide a possible implementation manner. As Figure 1 shown in the figure, a flowchart of a trajectory playback method is provided. This solution can be executed by any electronic device. Optionally, it can be executed on the server side or the terminal device. As Figure 1 shown in the figure, the method may include the following steps S101-S102:
[0037] Step S101: In response to a playback operation for the target trajectory, take the first segment trajectory of the target trajectory as the current segment trajectory, and start playing the travel data of this segment trajectory from the starting point of the current segment trajectory.
[0038] Specifically, the target trajectory may be a travel trajectory determined based on a complete trajectory of the end of travel. For example, in the food delivery scenario, when the food delivery task is completed, the complete trajectory corresponding to the food delivery can be determined. As Figure 3 shown in the figure, assuming that A is the rider's pick-up location (i.e., the location of the merchant, the starting point of the complete trajectory), and B is the goods delivery location (i.e., the location where the goods are received, the end point of the complete trajectory), then Figure 3 the path from point A to point B shown by the dotted line in the figure is the complete trajectory corresponding to the food delivery. The target trajectory may be the whole of this complete trajectory or a part of this complete trajectory. Among them, the complete trajectory may also be referred to as the original trajectory or the current trajectory in the embodiments of the present application.
[0039] Specifically, the playback operation is an operation in which an object using the client triggers a corresponding control to control the playback of the target trajectory. Optionally, after the target trajectory is determined, a playback control for controlling the playback may be displayed on the trajectory playback interface. When an object using the client triggers this playback control, the client responds to the playback operation.
[0040] Among them, each segment trajectory is obtained by splitting a number of positioning points included in the target trajectory, and the playback speed of each segment trajectory is determined based on any two positioning points in this segment trajectory.
[0041] Specifically, after determining the target trajectory, several positioning points included in the target trajectory (which can be points determined based on longitude and latitude) can be used to segment the target trajectory, obtaining several segmented trajectories; that is, the positioning points can be used as segmentation points to segment the target trajectory. Among them, each segmented trajectory has its corresponding start point and end point. Among them, the playback speed of each segmented trajectory can be determined based on the start point and end point of the segmented trajectory, such as determined based on the movement speed corresponding to the start point and end point; it can also be determined by selecting the movement speed corresponding to any two positioning points in the segmented trajectory.
[0042] For example: Example 1, after segmenting the target trajectory, three segmented trajectories are obtained (when sorted according to the traveling direction, corresponding to the first segmented trajectory, the second segmented trajectory, and the third segmented trajectory). When responding to the playback operation, the first segmented trajectory of the target trajectory is used as the current segmented trajectory, and the traveling data of this segmented trajectory is played starting from the start point of the current segmented trajectory; among them, the traveling data can include the traveling path.
[0043] Step S102: When the traveling data of the current segmented trajectory is played out, play the traveling data of the next segmented trajectory until the playback of the target trajectory ends.
[0044] Specifically, since the segmented trajectory is obtained by segmenting the target trajectory based on the positioning points in the target trajectory, the end point of the previous segmented trajectory is equivalent to the start point of the next segmented trajectory, that is, the end point of the current segmented trajectory is the start point of the next segmented trajectory.
[0045] Taking the above Example 1 as an example: When the traveling data of the first segmented trajectory is played out, the next segmented trajectory can be determined based on the end point of the current segmented trajectory, and then the traveling data of the next segmented trajectory (the second segmented trajectory) is played. At this time, the second segmented trajectory is the current segmented trajectory; when the traveling data of the second segmented trajectory is played out, the next segmented trajectory can be determined based on the end point of the current segmented trajectory, and then the traveling data of the next segmented trajectory (the third segmented trajectory) is played. At this time, the third segmented trajectory is the current segmented trajectory; when the traveling data of the third segmented trajectory is played out, that is, the playback of the target trajectory ends.
[0046] Next, the triggering of the playback operation and the specific process of responding to the playback operation in the embodiments of the present application will be described.
[0047] In a feasible embodiment, in step S101, in response to the playback operation on the target trajectory, taking the first segmented trajectory of the target trajectory as the current segmented trajectory and playing the traveling data of this segmented trajectory starting from the start point of the current segmented trajectory includes one of the following steps A1 - A2:
[0048] Step A1: In response to a first playback operation triggered by using the original trajectory as the target trajectory, set the original trajectory as the target trajectory, and set the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory.
[0049] Specifically, as Figure 3 shown, when there is an original trajectory (the path between the starting point A and the ending point B, represented by a dotted line), the application interface displays a control for triggering the first playback operation, such as the "Full Playback" operation control shown in a dotted box. An object using the client can control using the original trajectory as the target trajectory for trajectory playback by triggering this control. Specifically, as Figure 4 shown, the path between the starting point A and the ending point B changes to be represented by a solid line (indicating that the original trajectory is used as the target trajectory), and then the travel data is played starting from the starting point of the first segmented trajectory of the target trajectory (corresponding to point A).
[0050] Step A2: In response to an intercepting operation for intercepting a target trajectory from the original trajectory, intercept the original trajectory with a target starting point and a target ending point corresponding to this intercepting operation to obtain the target trajectory; in response to a second playback operation triggered for the target trajectory, set the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory.
[0051] Specifically, the application interface also displays a control for triggering the intercepting of a target trajectory from the original trajectory. An object using the client can control intercepting a target trajectory from the original trajectory for trajectory playback by triggering this control. Among them, the intercepting operation carries information about the target starting point and the target ending point (such as longitude and latitude coordinate information). Specifically, the application interface also displays a control for triggering the second playback operation. An object using the client can control using the intercepted target trajectory for trajectory playback by triggering this control. Specifically, as Figure 7 shown, the path between point A and point B is represented by a dotted line for the original trajectory, and the path between point C and point D is represented by a thin solid line for the target trajectory, and then the travel data is played starting from the starting point of the first segmented trajectory of the target trajectory (corresponding to point C).
[0052] In a feasible embodiment, in step A2, in response to an intercepting operation for intercepting a target trajectory from the original trajectory, intercepting the original trajectory with a target starting point and a target ending point corresponding to this intercepting operation to obtain the target trajectory includes one of the following steps A21 - step A22:
[0053] Step A21: In response to a selection operation of selecting a target trajectory from an original trajectory, a selection window is displayed. The selection window includes a start point input box, an end point input box, and a confirmation control for triggering a clipping operation, and the number of positioning points included in the original trajectory is displayed in the selection window; the first positioning point value entered in the start point input box and the second positioning point value entered in the end point input box are received; in response to a triggering operation on the confirmation control, the original trajectory is clipped with the positioning point corresponding to the first positioning point value as the target start point and the positioning point corresponding to the second positioning point value as the target end point to obtain the target trajectory.
[0054] Specifically, as Figure 3 shown, when there is an original trajectory (the path between the start point A and the end point B, represented by a dotted line), a control for triggering a selection operation is displayed on the application interface, such as the "Select Playback" operation control displayed in a dotted box. An object using the client can enter the selection stage of the target trajectory by triggering this control. As Figure 5 shown, in response to the selection operation, a selection window (such as the small window of "Select Playback Start and End Points" shown in the upper right corner of the interface) can be displayed on the application interface. The following contents are displayed in the selection window:
[0055] Start point input box: An object using the client can enter a number in this input box, or can select the number of the positioning point from the corresponding drop-down options by triggering the input box.
[0056] End point input box: An object using the client can enter a number in this input box, or can select the number of the positioning point from the corresponding drop-down options by triggering the input box.
[0057] Confirmation control for triggering the clipping operation: Such as Figure 5 the "Confirm" control shown in a dotted box in the small window.
[0058] The number of positioning points included in the original trajectory, such as Figure 5 shown as "The current trajectory has a total of 20 points".
[0059] Optionally, the selection window may further include a trigger control for restoring the original scale. Since it may be necessary to reduce the display scale of the map to completely display the original trajectory in the visible area of the application interface, however, after reducing the display scale, it is difficult for an object using the client to determine the corresponding relationship between the selected target trajectory and the original trajectory. Therefore, an object using the client can enlarge the display scale of the map by triggering the trigger control for restoring the original scale. Among them, the original scale can be the default scale or a scale preset by an object using the client.
[0060] Specifically, when an object using the client triggers the determination control, the positioning point corresponding to the first positioning point value entered in the start input box is determined as the target start point, and the positioning point corresponding to the second positioning point value entered in the end input box is determined as the target end point. Among them, as Figure 5 shown, when the original trajectory includes 20 positioning points, each positioning point has a corresponding sorting value according to the traveling direction. When the first positioning point value entered in the start input box is 1, the 1st positioning point in the original trajectory is used as the target start point of the target trajectory; when the second positioning point value entered in the end input box is 18, the 18th positioning point in the original trajectory is used as the target end point of the target trajectory; then the trajectory between the 1st positioning point and the 18th positioning point in the original trajectory is intercepted as the target trajectory.
[0061] Step A22: In response to the selection operation of selecting the target trajectory from the original trajectory, display several positioning points included in the original trajectory; in response to the selection operation of the first positioning point and the second positioning point in the original trajectory, determine the target start point and the target end point based on the traveling direction, the first positioning point, and the second positioning point of the original trajectory; in response to the interception operation of intercepting the target trajectory from the original trajectory, intercept the original trajectory with the target start point and the target end point to obtain the target trajectory.
[0062] Specifically, as Figure 3 shown, when there is an original trajectory (the path between the start point A and the end point B, represented by a dotted line), the application interface displays a control for triggering the selection operation, such as the "Select Playback" operation control displayed in a dotted box. An object using the client can enter the selection stage of the target trajectory by triggering this control. As Figure 6 shown, in response to the selection operation, the positioning points included in the original trajectory are displayed on the original trajectory of the application interface. The positioning points include point A (start point) and point B (end point) represented by circles, and six points represented by diamonds.
[0063] Specifically, after the positioning points are displayed in the original trajectory, an object using the client can select two of these positioning points according to requirements. As Figure 6 shown, an object using the client can select point D as the first positioning point and point C as the second positioning point. Since there is no limitation on the selected start point and end point when selecting the positioning points, the traveling direction of the original trajectory (from point A to point B) can be combined to determine that point C is the target start point and point D is the target end point.
[0064] Specifically, as Figure 6 shown, the target trajectory is intercepted from the original trajectory with the selected target start point and target end point. The start point of this target trajectory is point C and the end point is point D.
[0065] The following describes the specific process of dividing the target trajectory into several segmented trajectories in the embodiments of the present application.
[0066] In a feasible embodiment, dividing the several positioning points included in the target trajectory to obtain each segmented trajectory includes the following steps B1 - B3:
[0067] Step B1: Obtain the travel data corresponding to the target trajectory, where the travel data includes several positioning points and the moving speed corresponding to each positioning point.
[0068] Specifically, the travel data may be data generated when an object is traveling in real time. For example, in the food delivery scenario, it is the data generated when a rider picks up goods from a merchant and travels along the navigation route to the order delivery location. Optionally, the travel data may include several positioning points included in the trajectory and the moving speed of the object passing through each positioning point.
[0069] Step B2: Divide the target trajectory based on a preset segmentation method to obtain several segmented trajectories; each segmented trajectory has a corresponding starting point and ending point; wherein, the preset segmentation method includes at least one of the method of segmenting one by one based on positioning points, the method of segmenting based on landmarks, and the method of segmenting based on moving speed.
[0070] Specifically, the preset segmentation method includes the following possible methods:
[0071] (1) The method of segmenting one by one based on positioning points: As Figure 6 shown, the target trajectory includes four positioning points (covering the starting point and the ending point). When it is from positioning point C - positioning point 1 - positioning point 2 - positioning point D, it can be segmented into three segmented trajectories. The first segmented trajectory is formed by positioning point C and positioning point 1, the second segmented trajectory is formed by positioning point 1 and positioning point 2, and the third segmented trajectory is formed by positioning point 2 and positioning point D.
[0072] (2) The method of segmenting based on landmarks: During the process of traveling along the path corresponding to the target trajectory, various landmarks may be passed, such as tourist attractions, shopping centers, office buildings, etc. Optionally, the setting of landmarks can be based on the application scenario. For example, in the food delivery scenario, landmarks can be set as office buildings, residential areas, etc. On this basis, when the target trajectory includes 5 positioning points (starting point - positioning point 1 - positioning point 2 - positioning point 3 - ending point), and positioning point 1 and the ending point involve landmark areas, the target trajectory can be segmented into two segmented trajectories. The first segmented trajectory is formed by the starting point and positioning point 1, and the second segmented trajectory is formed by positioning point 1 and the ending point.
[0073] (3) In the way of dividing by moving speed: The moving speed difference between positioning points can be preset as V1. When the moving speed difference between a latter positioning point and a former positioning point is greater than or equal to V1, the latter positioning point is regarded as a dividing point to divide the target trajectory.
[0074] Step B3: For each segmented trajectory, determine the playing speed of the segmented trajectory based on the average moving speed of any two positioning points in the segmented trajectory.
[0075] Specifically, the playing speed of each segmented trajectory can be expressed by the following formula (1):
[0076] Vi = (V1 + V2) / 2
[0077] ...... Formula (1)
[0078] Wherein, in formula (1), Vi is the playing speed of the i-th segmented trajectory, V1 is the moving speed of a positioning point in the i-th segmented trajectory, and V2 is the moving speed of another positioning point in the i-th segmented trajectory. Assuming that the target trajectory is segmented in the above way of segmenting by positioning points one by one, then the i-th segmented trajectory only includes two positioning points, the starting point i and the ending point i + 1. At this time, V1 is the moving speed corresponding to the starting point i, and V2 is the moving speed corresponding to the ending point i + 1.
[0079] Optionally, two positioning points with the largest moving speed difference in the segmented trajectory can be selected for calculating the playing speed, or the starting point and the ending point in the segmented trajectory can be selected for calculating the playing speed.
[0080] Optionally, the above steps B1 - B3 can be executed by the terminal. For example, after the target trajectory is determined, the corresponding steps are executed. Optionally, the above steps B1 - B3 can also be executed by the server. After the terminal determines the target trajectory, it transmits the data related to the target trajectory to the server, and the server performs the segmentation process of the target trajectory and feeds back the results of each operation step to the terminal.
[0081] Next, the specific process of the front-end layout for segmenting the target trajectory into several segmented trajectories in the embodiments of the present application will be described.
[0082] In a feasible embodiment, when dividing the several positioning points included in the target trajectory to obtain each segmented trajectory, the following steps B4 - B5 are further included:
[0083] Step B4: For each segmented trajectory, determine the playing time of the segmented trajectory based on the distance between the starting point and the ending point of the segmented trajectory and the playing speed.
[0084] Specifically, the track length of each segmented track is equal to the distance between the starting point and the ending point of the segmented track. When determining the playing time of the segmented track, it can be determined based on the track length and playing speed of the segmented track. For example, if the track length of the first segmented track is S1 and the playing speed is V1, then its playing time T1 = S1 / V1.
[0085] Step B5: Determine the total playing time of the target track as the sum of the playing times of each segmented track.
[0086] Specifically, assuming that the target track includes N segmented tracks, the total playing time of the target track can be expressed by the following formula (2):
[0087] t = s1 / v1 + s2 / v2 + … + sn / vn
[0088] ......Formula (2)
[0089] Where, t is the total playing time of the target track, s1 is the track length of the first segmented track, v1 is the playing speed of the first segmented track, and so on.
[0090] Optionally, the above steps B4 - B5 can be executed by the terminal. For example, after determining the playing speeds of each segmented track, the corresponding steps are executed. Optionally, the above steps B4 - B5 can also be executed by the server. After the terminal determines the target track, it transmits the data related to the target track to the server. After the server performs the segmentation process on the target track, it determines the total playing time of the target track and feeds back the results of each operation step to the terminal.
[0091] Through the operation and processing of the above steps B1 - B5, the travel data S - new of the target track can be obtained: [{path: [latitude and longitude of the starting point of s1, latitude and longitude of the ending point of s1], speed: v1}…].
[0092] Playing the travel data of the segmented track starting from the starting point of the current segmented track in step S101 includes the following steps C1:
[0093] Step C1: Play the travel data of the segmented track starting from the starting point of the current segmented track on the track playback interface, and display a playback bar based on the total playing time; the playback bar is used to identify the playback progress of the target track.
[0094] Specifically, as Figure 4 、 Figure 7 and Figure 8 shown, a playback bar can be displayed at the bottom of the track playback interface, and the total playing time and the time corresponding to the current playback progress are displayed on the right side of the playback bar. Among them, as Figure 4As shown, when the original trajectory is used as the target trajectory, the total playback time is 26 minutes. The current playback reaches 13 minutes, and the black part in the playback bar accounts for half of the whole, which is used to represent that the current playback reaches half of the path of the original trajectory.
[0095] Optionally, Figure 5 and Figure 6 a playback bar can also be arranged.
[0096] In a feasible embodiment, the playback bar includes a switching control for controlling pause playback or resume playback; specifically, as Figure 4 , Figure 7 and Figure 8 shown, a switching control is arranged on the left side of the playback bar, and the same switching control can control pause playback or resume playback.
[0097] Specifically, the trajectory playback method provided by the embodiment of the present application further includes the following steps C2-step C3:
[0098] Step C2: During the playback of the travel data, in response to a first trigger operation on the switching control, pause the playback of the travel data.
[0099] Step C3: During the pause of the playback of the travel data, in response to a second trigger operation on the switching control, resume the playback of the travel data.
[0100] Specifically, during the playback of the travel data, when an object of the client triggers the switching control, that is, control to pause the playback of the travel data; during the pause of the playback of the travel data, when an object of the client triggers the switching space, that is, control to resume the playback of the travel data from the paused position.
[0101] Next, the specific content of the background execution logic of the trajectory playback method provided by the embodiment of the present application will be described.
[0102] Specifically, the following data is defined during the background execution:
[0103] 1. The movement status moveStatus of the current moving point, whose initial value is init; the movement status includes: initial init; start start; in progress moving; end end;
[0104] 2. The current playback of which segment of the trajectory moveIndex, the initial value is 0
[0105] 3. The passed path passedPathref, the initial value is [].
[0106] In a feasible embodiment, when playing the travel data of the current segmented trajectory starting from the starting point in step S101, it includes the following steps D1 - step D2:
[0107] Step D1: When starting to play the travel data of the current segmented trajectory, set the movement state of the moving point to start.
[0108] Step D2: When playing the travel data of the current segmented trajectory, trigger the in - progress event of the moving point.
[0109] Specifically, during the playback of the target trajectory, a moving point identifier is also used to indicate the progress in the target trajectory. For example, Figure 4 As shown, a five - pointed star is used to represent the moving point.
[0110] Specifically, the execution logic in the background includes:
[0111] Point 1: When triggering the start of playback, the travel data of the first segmented trajectory can be played by calling the uniform - speed trajectory playback api - moveAlone. Among them, the uniform - speed trajectory playback api - moveAlone plays the first segmented trajectory at a uniform speed using the overall playback speed of the original trajectory.
[0112] Point 2: When the moving point moves, trigger the in - progress moving event of the moving point. When the moving point finishes moving, trigger the end - of - movement moveend event. When the moving point starts to move, the movement state moveStatu can be set to start. During the movement of the moving point, in the in - progress moving event of the moving point, continuously update the passed path passedPathref of the movement and assign it to the polylinePath of the movement trajectory.
[0113] In a feasible embodiment, based on the implementation of the above steps D1 - D2, when the travel data of the current segmented trajectory finishes playing in step S102, play the travel data of the next segmented trajectory until the playback of the target trajectory ends, including the following steps D3 - step D5:
[0114] Step D3: When the travel data of the current segmented trajectory finishes playing, trigger the end - of - movement event of the moving point and set the movement state of the moving point to end.
[0115] Step D4: In the end - of - movement event, increment the label identifying the current segmented trajectory by 1, play the travel data of the next segmented trajectory, trigger the in - progress event of the moving point, and set the movement state of the moving point to start until the playback of the last segmented trajectory of the target trajectory ends.
[0116] Step D5: When the playback of the target trajectory ends, set the moving state of the moving point to the initial state, and set the label for identifying the segmented trajectory to a preset value.
[0117] Among them, the preset value can be 0.
[0118] Specifically, based on the above points 1 and 2, the execution logic of the background further includes the following points 3 - 5:
[0119] Point 3: After the current segmented trajectory is played at a constant speed (the corresponding travel data is played at the playback speed of this segmented trajectory) and ends, set the moving state moveStatu of the moving point to end. In the moveend event of the moving point's movement end, increment the label value moveIndex of the recorded segmented trajectory by 1. After setting the travel data of the next segmented trajectory to be played back, the movement effect of the moving point on the next segmented trajectory can be achieved by calling the moving point api - moveTo.
[0120] Point 4: Repeat the process of points 2 - 3 until the label moveIndex of the recorded segmented trajectory is the last segment of the segmentation. After the movement of the moving point ends, set the moving state moveStatue to init and the label moveIndex to 0 to restore the initial state.
[0121] Point 5: The playback control can call the trajectory playback tool through the interface api. Among them, the pause control corresponding to the switching control can be: marker instance.pauseMove(); the resume control corresponding to the switching space can be: marker instance.resumeMove().
[0122] Next, the specific processing process regarding the visualization part in the embodiments of the present application will be described.
[0123] In a feasible embodiment, during the playback of the target trajectory, a first element is used on the trajectory playback interface to identify the travel position of the moving point in the target trajectory.
[0124] Among them, the first element can be set accordingly according to the application scenario. For example, in the food delivery scenario, the first element can be the icon of an electric scooter. As Figure 4 、 Figure 7 and Figure 8 shown, the first element can be a five - pointed star icon. By displaying the five - pointed star icon in the target trajectory, it represents the travel position of the moving point during the trajectory playback.
[0125] In a feasible embodiment, on the trajectory playback interface, the starting point of the target trajectory is identified by a second element, and the ending point of the target trajectory is identified by a third element.
[0126] Among them, to better distinguish the target trajectory from the original trajectory, the starting point of the target trajectory can be identified by a second element and the ending point of the target trajectory can be identified by a third element. For example, Figure 7 As shown, the starting point of the target trajectory is C and the ending point is D. Then, a hollow diamond can be used to identify the target starting point and the target ending point respectively.
[0127] Optionally, the second element and the third element can be the same or different; among them, the second element can adopt a text icon of "start", and the third element can adopt a text icon of "end".
[0128] In a feasible embodiment, on the trajectory playback interface, the original trajectory is displayed by a first identification information, the target trajectory is displayed by a second identification information, and the segmented trajectory of the played travel data is displayed by a third identification information.
[0129] Specifically, the identification information can be information such as line type, line thickness, color, etc.; for example: Figure 7 As shown, the first identification information is a dotted line, the second identification information is a thin solid line, and the third identification information is a thick solid line. Optionally, the first identification information can be color A, the second identification information can be color B, and the third identification information can be color C.
[0130] Among them, the third identification information is only displayed in the path after the moving point passes by. For example, Figure 4 and Figure 7 As shown, in the target trajectory, the third identification information is only displayed in the path traveled by the moving point.
[0131] In a feasible embodiment, the trajectory playback method provided by the embodiments of the present application can be applied to analyze data or make travel decisions in some scenarios. For example, Figure 8 As shown, assuming it is a food delivery scenario, it can be determined the relationship between the deliveryman's travel route in the currently played video and the area shown by the dotted line box in the figure to determine whether the deliveryman enters the area shown by the dotted line box. If the deliveryman stays at the current positioning point for more than a preset duration, it can be determined that the deliveryman enters the area shown by the dotted line box.
[0132] An embodiment of the present application provides an intuitive dynamic trajectory playback solution that can feedback the travel trajectory and the change in travel speed of a traveling object. The trajectory playback can be paused or continued according to the needs of the object using the client, and the start and end points of the playback can also be selected (intercept the target trajectory) to focus on the key trajectory that the user wants to view in the trajectory, which can intuitively assist in tracing the trajectory of the traveling object, performing road segment data analysis, optimizing algorithm data, discovering problems, and mining more solutions that are beneficial to improving the travel experience (for example, in the case of food delivery scenarios, more solutions that are beneficial to improving the delivery of orders by delivery personnel can be mined).
[0133] Based on the same principle as the above method embodiment, an embodiment of the present application also provides a trajectory playback device, as shown in Figure 9 shown in, the trajectory playback device 100 may include a playback module 101.
[0134] Among them, the playback module 101 is configured to, in response to a playback operation for a target trajectory, use the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory; when the travel data of the current segmented trajectory is played, play the travel data of the next segmented trajectory until the target trajectory playback ends;
[0135] Among them, each segmented trajectory is obtained by dividing a number of positioning points included in the target trajectory, the playback speed of each segmented trajectory is determined based on any two positioning points in this segmented trajectory, and the end point of the current segmented trajectory is the starting point of the next segmented trajectory.
[0136] In a feasible embodiment, when the playback module 101 is configured to, in response to a playback operation for a target trajectory, use the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory, it is specifically configured to perform one of the following:
[0137] In response to a first playback operation triggered by using the original trajectory as the target trajectory, use the original trajectory as the target trajectory, use the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory;
[0138] In response to an intercept operation of intercepting a target trajectory from the original trajectory, intercept the original trajectory with the target starting point and target end point corresponding to this intercept operation to obtain the target trajectory; in response to a second playback operation triggered for the target trajectory, use the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of this segmented trajectory starting from the starting point of the current segmented trajectory.
[0139] In a feasible embodiment, when the playback module 101 is configured to respond to a clipping operation for clipping a target trajectory from an original trajectory and clip the original trajectory with a target start point and a target end point corresponding to the clipping operation to obtain the target trajectory, it is specifically configured to perform one of the following:
[0140] In response to a selection operation for selecting a target trajectory from the original trajectory, display a selection window, where the selection window includes a start point input box, an end point input box, and a determination control for triggering the clipping operation, and the number of positioning points included in the original trajectory is displayed in the selection window; receive a first positioning point value input in the start point input box and a second positioning point value input in the end point input box; in response to a triggering operation on the determination control, clip the original trajectory with the positioning point corresponding to the first positioning point value as the target start point and the positioning point corresponding to the second positioning point value as the target end point to obtain the target trajectory;
[0141] In response to a selection operation for selecting a target trajectory from the original trajectory, display a plurality of positioning points included in the original trajectory; in response to a selection operation on a first positioning point and a second positioning point in the original trajectory, determine a target start point and a target end point based on the traveling direction of the original trajectory, the first positioning point, and the second positioning point; in response to a clipping operation for clipping a target trajectory from the original trajectory, clip the original trajectory with the target start point and the target end point to obtain the target trajectory.
[0142] In a feasible embodiment, in the trajectory playback device 100, splitting the plurality of positioning points included in the target trajectory to obtain each segmented trajectory includes:
[0143] Obtain traveling data corresponding to the target trajectory, where the traveling data includes a plurality of positioning points and the moving speed corresponding to each positioning point.
[0144] Split the target trajectory based on a preset splitting method to obtain a plurality of segmented trajectories; each segmented trajectory has a corresponding start point and end point; where the preset splitting method includes at least one of a method of splitting one by one based on positioning points, a method of splitting based on landmarks, and a method of splitting based on moving speed;
[0145] For each segmented trajectory, determine the playback speed of the segmented trajectory based on the average moving speed of any two positioning points in the segmented trajectory.
[0146] In a feasible embodiment, in the trajectory playback device 100, splitting the plurality of positioning points included in the target trajectory to obtain each segmented trajectory further includes:
[0147] For each segmented trajectory, determine the playback time of the segmented trajectory based on the distance between the start point and the end point of the segmented trajectory and the playback speed;
[0148] Determine the sum of the playback times of each segmented trajectory as the total playback time of the target trajectory;
[0149] The travel data for playing the segmented trajectory starting from the starting point of the current segmented trajectory includes:
[0150] The travel data for playing the segmented trajectory starting from the starting point of the current segmented trajectory on the trajectory playback interface, and display a playback bar based on the total playback time; the playback bar is used to identify the playback progress of the target trajectory.
[0151] In a feasible embodiment, the playback bar includes a switching control for controlling pause or resume playback; the device further includes:
[0152] A first response module, configured to pause the playback of the travel data in response to a first trigger operation on the switching control during the playback of the travel data;
[0153] A second response module, configured to resume the playback of the travel data in response to a second trigger operation on the switching control during the pause of the playback of the travel data.
[0154] In a feasible embodiment, when the playback module 101 is used to play the travel data of the segmented trajectory starting from the starting point of the current segmented trajectory, it is specifically configured to:
[0155] When starting to play the travel data of the current segmented trajectory, set the moving state of the moving point to start;
[0156] When playing the travel data of the current segmented trajectory, trigger the in-travel event of the moving point;
[0157] When the playback module 101 is used to play the travel data of the next segmented trajectory when the travel data of the current segmented trajectory ends, until the playback of the target trajectory ends, it is specifically configured to:
[0158] When the travel data of the current segmented trajectory ends, trigger the end-of-travel event of the moving point and set the moving state of the moving point to end;
[0159] In the end-of-travel event, increment by 1 the label identifying the current segmented trajectory, play the travel data of the next segmented trajectory, trigger the in-travel event of the moving point and set the moving state of the moving point to start, until the playback of the last segmented trajectory of the target trajectory ends;
[0160] When the playback of the target trajectory ends, set the moving state of the moving point to the initial state, and set the label used to identify the segmented trajectory to a preset value.
[0161] In a feasible embodiment, the playback module 101 is further configured to, during the playback of the target trajectory, use a first element to identify the traveling position of the moving point in the target trajectory on the trajectory playback interface.
[0162] In a feasible embodiment, the playback module 101 is further configured to use a second element to identify the starting point of the target trajectory and a third element to identify the ending point of the target trajectory on the trajectory playback interface.
[0163] In a feasible embodiment, the playback module 101 is further configured to display the original trajectory with a first identification information, display the target trajectory with a second identification information, and display the segmented trajectory of the played traveling data with a third identification information on the trajectory playback interface.
[0164] The device according to the embodiment of the present application can execute the method provided by the embodiment of the present application, and the implementation principle is similar. The actions performed by each module in the device according to the embodiments of the present application correspond to the steps in the method according to the embodiments of the present application. For the detailed function description of each module of the device, reference can be specifically made to the description in the corresponding method shown above, and details are not described herein again.
[0165] In the embodiment of the present application, an electronic device is provided, including a memory, a processor, and a computer program stored on the memory. The processor executes the above computer program to implement the steps of the trajectory playback method. Compared with the related art, it can be realized that: in response to a playback operation for a target trajectory, the first segmented trajectory of the target trajectory is used as the current segmented trajectory, and the traveling data of this segmented trajectory is played starting from the starting point of the current segmented trajectory; when the playback of the traveling data of the current segmented trajectory ends, the starting point of the next segmented trajectory can be determined based on the ending point of the current segmented trajectory, and then the traveling data of the next segmented trajectory is played. At this time, the next segmented trajectory replaces the current segmented trajectory until the playback of the target trajectory ends; wherein, since each segmented trajectory is obtained by dividing a plurality of positioning points included in the target trajectory, that is, a target trajectory can be divided into several segmented trajectories based on the positioning points, and each segmented trajectory has its own corresponding starting point and ending point. On this basis, the playback speed of each segmented trajectory is determined based on any two positioning points in this segmented trajectory; that is, the playback speeds of each segmented trajectory are different. The implementation of the present application realizes dynamic trajectory playback by dynamically configuring the playback speed of each segmented trajectory. The dynamic trajectory playback can reflect the time the object stays at the point and the speed change during the traveling process, etc., and improves the experience of trajectory playback.
[0166] In an alternative embodiment, an electronic device is provided, as Figure 10 shown Figure 10The illustrated electronic device 4000 includes: a processor 4001 and a memory 4003. Among them, the processor 4001 and the memory 4003 are connected, such as being connected through a bus 4002. Optionally, the electronic device 4000 may further include a transceiver 4004, and the transceiver 4004 can be used for data interaction between this electronic device and other electronic devices, such as data transmission and / or data reception, etc. It should be noted that in practical applications, the transceiver 4004 is not limited to one, and the structure of the electronic device 4000 does not constitute a limitation to the embodiments of the present application.
[0167] The processor 4001 can be a CPU (Central Processing Unit, central processor), a general-purpose processor, a DSP (Digital Signal Processor, data signal processor), an ASIC (Application Specific Integrated Circuit, application-specific integrated circuit), an FPGA (Field Programmable Gate Array, field programmable gate array), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute various exemplary logical blocks, modules, and circuits described in connection with the disclosure of the present application. The processor 4001 can also be a combination that realizes computing functions, such as a combination including one or more microprocessors, a combination of a DSP and a microprocessor, etc.
[0168] The bus 4002 may include a path for transmitting information between the above components. The bus 4002 can be a PCI (Peripheral Component Interconnect, peripheral component interconnect standard) bus or an EISA (Extended Industry Standard Architecture, extended industry standard architecture) bus, etc. The bus 4002 can be divided into an address bus, a data bus, a control bus, etc. For the sake of representation, Figure 10 only a thick line is used to represent it in the figure, but it does not mean that there is only one bus or one type of bus.
[0169] The memory 4003 can be a ROM (Read Only Memory), or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory), or other types of dynamic storage devices that can store information and instructions. It can also be an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory), or other optical disc storage, optical disc storage (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media, other magnetic storage devices, or any other medium that can be used to carry or store computer programs and can be read by a computer, which is not limited here.
[0170] The memory 4003 is used to store the computer program for implementing the embodiments of the present application and is controlled by the processor 4001 to execute. The processor 4001 is used to execute the computer program stored in the memory 4003 to implement the steps shown in the foregoing method embodiments.
[0171] Among them, the electronic device includes but is not limited to: user terminals, in-vehicle devices.
[0172] The embodiments of the present application provide a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps and corresponding contents of the foregoing method embodiments can be implemented.
[0173] The embodiments of the present application also provide a computer program product, including a computer program. When the computer program is executed by a processor, the steps and corresponding contents of the foregoing method embodiments can be implemented.
[0174] In the description and claims of the present application and the above-mentioned drawings, the terms "first", "second", "third", "fourth", "1", "2", etc. (if any) are used to distinguish similar objects and do not necessarily describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances so that the embodiments of the present application described here can be implemented in an order other than that shown or described in words.
[0175] It should be understood that although the flowchart of the embodiments of the present application indicates each operation step by an arrow, the execution order of these steps is not limited to the order indicated by the arrow. Unless there is a clear description in this article, in some implementation scenarios of the embodiments of the present application, the implementation steps in each flowchart can be executed in other orders according to requirements. In addition, some or all of the steps in each flowchart may include multiple sub-steps or multiple stages based on the actual implementation scenario. Some or all of these sub-steps or stages can be executed at the same time, and each sub-step or stage among these sub-steps or stages can also be executed at different times respectively. In the scenario where the execution times are different, the execution order of these sub-steps or stages can be flexibly configured according to requirements, and the embodiments of the present application do not limit this.
[0176] The above are only optional implementation manners of some implementation scenarios of the present application. It should be noted that for those of ordinary skill in the art, without departing from the technical concept of the solution of the present application, using other similar implementation means based on the technical idea of the present application also belongs to the protection scope of the embodiments of the present application.
Claims
1. A trajectory playback method, characterized in that, Including: In response to a playback operation for a target trajectory, taking a first segment trajectory of the target trajectory as a current segment trajectory, and playing travel data of this segment trajectory starting from the starting point of the current segment trajectory; When the playback of the travel data of the current segment trajectory ends, playing the travel data of the next segment trajectory until the playback of the target trajectory ends; Wherein, the playback speed of each segment trajectory is determined based on any two positioning points in this segment trajectory, and the end point of the current segment trajectory is the starting point of the next segment trajectory; Wherein, each segment trajectory is obtained through the following operations: Obtaining travel data corresponding to the target trajectory, the travel data including a plurality of positioning points and a moving speed corresponding to each positioning point; Segmenting the target trajectory based on a preset segmentation method to obtain a plurality of segment trajectories; each segment trajectory has a corresponding starting point and end point; For each segment trajectory, determining the playback speed of this segment trajectory based on the average value of the moving speeds of any two positioning points in this segment trajectory.
2. The method according to claim 1, wherein The step of, in response to a playback operation for a target trajectory, taking a first segment trajectory of the target trajectory as a current segment trajectory, and playing travel data of this segment starting from the starting point of the current segment trajectory, includes one of the following: In response to a first playback operation triggered by taking an original trajectory as a target trajectory, taking the original trajectory as the target trajectory, taking a first segment trajectory of the target trajectory as the current segment trajectory, and playing travel data of this segment trajectory starting from the starting point of the current segment trajectory; In response to an intercepting operation of intercepting a target trajectory from an original trajectory, intercepting the original trajectory with a target starting point and a target end point corresponding to this intercepting operation to obtain the target trajectory; In response to a second playback operation triggered for the target trajectory, taking a first segment trajectory of the target trajectory as the current segment trajectory, and playing travel data of this segment trajectory starting from the starting point of the current segment trajectory.
3. The method according to claim 2, wherein The step of, in response to an intercepting operation of intercepting a target trajectory from an original trajectory, intercepting the original trajectory with a target starting point and a target end point corresponding to this intercepting operation to obtain the target trajectory, includes one of the following: In response to a selection operation of selecting a target trajectory from an original trajectory, displaying a selection window, the selection window including a starting point input box, an end point input box, and a determination control for triggering an intercepting operation, and the selection window displaying the number of positioning points included in the original trajectory; receiving a first positioning point value input in the starting point input box and a second positioning point value input in the end point input box; in response to a triggering operation on the determination control, intercepting the original trajectory with the positioning point corresponding to the first positioning point value as the target starting point and the positioning point corresponding to the second positioning point value as the target end point to obtain the target trajectory; In response to a selection operation of selecting a target trajectory from an original trajectory, displaying a plurality of positioning points included in the original trajectory; in response to a selection operation of a first positioning point and a second positioning point in the original trajectory, determining a target starting point and a target end point based on the travel direction of the original trajectory, the first positioning point, and the second positioning point. In response to an intercept operation that intercepts a target trajectory from an original trajectory, the original trajectory is intercepted with the target start point and the target end point to obtain the target trajectory.
4. The method according to claim 1, wherein The preset segmentation method includes at least one of a method of segmenting one by one based on positioning points, a method of segmenting based on landmarks, and a method of segmenting based on moving speed.
5. The method according to claim 4, characterized in that, The processing of each segmented trajectory further includes: For each segmented trajectory, based on the distance between the start point and the end point of the segmented trajectory and the playback speed, determine the playback time of the segmented trajectory; Determine the total playback time of the target trajectory as the sum of the playback times of each segmented trajectory; The travel data for playing the segmented trajectory starting from the start point of the current segmented trajectory includes: On the trajectory playback interface, play the travel data of the segmented trajectory starting from the start point of the current segmented trajectory, and display a playback bar based on the total playback time; the playback bar is used to identify the playback progress of the target trajectory.
6. The method according to claim 5, characterized in that, The playback bar includes a switching control for controlling pause or resume playback; the method further includes: During the playback of the travel data, in response to a first trigger operation on the switching control, pause the playback of the travel data; During the pause of the playback of the travel data, in response to a second trigger operation on the switching control, resume the playback of the travel data.
7. The method according to claim 1, characterized in that, The travel data for playing the segmented trajectory starting from the start point of the current segmented trajectory includes: When starting to play the travel data of the current segmented trajectory, set the moving state of the moving point to start; When playing the travel data of the current segmented trajectory, trigger the in-travel event of the moving point; The step of, when the travel data of the current segmented trajectory is played to the end, playing the travel data of the next segmented trajectory until the playback of the target trajectory ends, includes: When the travel data of the current segmented trajectory is played to the end, trigger the end-of-travel event of the moving point and set the moving state of the moving point to end; In the end-of-travel event, increment by 1 the label identifying the current segmented trajectory, play the travel data of the next segmented trajectory, trigger the in-travel event of the moving point and set the moving state of the moving point to start, until the playback of the last segmented trajectory of the target trajectory ends; When the playback of the target trajectory ends, set the moving state of the moving point to the initial state, and set the label for identifying the segmented trajectory to a preset value.
8. The method according to claim 1 or 7, characterized in that During the playback of the target trajectory, on the trajectory playback interface, use a first element to identify the travel position of the moving point in the target trajectory; On the trajectory playback interface, use a second element to identify the start point of the target trajectory and a third element to identify the end point of the target trajectory.
9. The method according to claim 2, wherein On the trajectory playback interface, display the original trajectory with a first identification information, display the target trajectory with a second identification information, and display the segmented trajectory of the played travel data with a third identification information.
10. A trajectory playback device, characterized in that, Includes: A playback module, configured to, in response to a playback operation on a target trajectory, use the first segmented trajectory of the target trajectory as the current segmented trajectory, and play the travel data of the segmented trajectory starting from the start point of the current segmented trajectory; When the playback of the travel data of the current segmented trajectory ends, play the travel data of the next segmented trajectory until the playback of the target trajectory ends; Among them, the playback speed of each segmented trajectory is determined based on any two positioning points in this segmented trajectory, and the end point of the current segmented trajectory is the starting point of the next segmented trajectory; Among them, each segmented trajectory is obtained through the following operations: Obtain the travel data corresponding to the target trajectory, and the travel data includes a number of positioning points and the moving speed corresponding to each positioning point; Segment the target trajectory based on a preset segmentation method to obtain a number of segmented trajectories; each segmented trajectory has a corresponding starting point and end point; For each segmented trajectory, determine the playback speed of this segmented trajectory based on the average value of the moving speeds of any two positioning points in this segmented trajectory.
11. An electronic device, characterized in that, It includes a memory and a processor. Among them, a computer program is stored in the memory; when the processor runs the computer program, it is used to execute the method described in any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that, A computer program is stored in the storage medium. When the computer program runs in the processor, the processor is used to execute the method described in any one of claims 1 to 9.
13. A computer program product, characterized in that, The computer program product includes a computer program, and when the computer program is executed by the processor, it implements the method described in any one of claims 1 to 9.
Citation Information
Patent Citations
Method and system for replaying vehicle historical traveling track
CN103927795A
Electronic map simulation track playback method and system
CN107741944A
Method and device for playing historic trails in electronic map
CN109727524A