Video playback method and device, electronic equipment and computer readable storage medium

文档序号:1172994 发布日期:2020-09-18 浏览:23次 中文

阅读说明:本技术 录像回放方法、装置、电子设备及计算机可读存储介质 (Video playback method and device, electronic equipment and computer readable storage medium ) 是由 金威 姚家振 张硕硕 张丽丽 张龙涛 于 2020-06-05 设计创作,主要内容包括:本申请提供一种录像回放方法、装置、电子设备及计算机可读存储介质,本申请中,在待进行录像回放的情况下,依据待进行录像回放的目标时间点和目标时间点对应的目标时区(录像回放模式按照目标时区进行回放录像),有针对性地为待进行录像回放的各目标录像设备确定用于回放录像的目标播放时间点,之后即可依据为各目标录像设备确定的目标播放时间点回放各目标录像设备中的录像,实现了回放目标录像设备中的录像。(In the application, under the condition of video playback to be performed, a target playing time point for playing back a video is determined for each target video device to be subjected to video playback in a targeted manner according to a target time point to be subjected to video playback and a target time zone corresponding to the target time point (a video playback mode performs playback video according to the target time zone), and then the video in each target video device can be played back according to the target playing time point determined for each target video device, so that the video in the target video device is played back.)

1. A video playback method is applied to a client and comprises the following steps:

determining a target time point and a video playback mode to be subjected to video playback, wherein the video playback mode is a mode for performing playback video according to a target time zone, and the target time zone is a time zone corresponding to the target time point;

determining a target playing time point for playing back the video for target video recording equipment to be subjected to video playback according to the target time zone and the target time point;

and playing back the video in the target video equipment according to the target playing time point determined for the target video equipment.

2. The method of claim 1, wherein the target time zone is a client time zone in which the client is located; under the condition that the number of target video equipment to be subjected to video playback is greater than 1, the target playing time points of all the target video equipment are the same; alternatively, the first and second electrodes may be,

the target time zone is a first time zone where the appointed video equipment is located; and under the condition that the number of the target video equipment to be subjected to video playback is larger than 1, corresponding time information of the target playing time point of each target video equipment in the time zone in which each target video equipment is located is the same.

3. The method of claim 1, wherein determining a target play time point for playing back recorded video for a target recording device to be recorded for playback based on the target time zone and the target time point comprises:

converting the target time point in the target time zone into a reference time point in a set reference time zone according to a first time difference, wherein the first time difference is determined according to a time zone offset between the target time zone and the reference time zone, or, in the case that the target time point is in daylight saving time of the target time zone, according to a time zone offset between the target time zone and the reference time zone and the daylight saving time offset;

and determining a target playing time point for playing back the video for the target video equipment according to the reference time point.

4. The method of claim 3, wherein if the target time zone is the first time zone, the converting the target time point in the target time zone into a reference time point in a set reference time zone according to the first time difference comprises:

determining a second time difference between the target time zone and a second time zone in which target video equipment is located under the condition that the target time zone is different from the second time zone; the second time difference is determined according to a time zone offset between the second time zone and the target time zone, or, in a case where at least one of the target time point and a reference time point is in daylight saving time, according to a daylight saving time offset and a time zone offset between the second time zone and the target time zone; the reference time point is a time point corresponding to the target time point in the second time zone;

and converting the target time point in the target time zone into a reference time point in a set reference time zone according to the first time difference and the second time difference.

5. The method of claim 1, wherein the target time point is a selected time point on a plotted target time axis; the method further comprises the following steps:

and displaying the video information corresponding to at least one time slot in the target time axis in the target video equipment.

6. The method of claim 1, wherein the target time point is a selected time point on a plotted target time axis; the target time axis is drawn in the following way:

determining the target time zone corresponding to the target time axis;

obtaining time zone information of the target time zone; the time zone information includes: the start time information of the target time zone entering daylight saving time and/or the end time information of the daylight saving time ending and the daylight saving time offset;

and drawing the target time axis corresponding to the target time zone, wherein under the condition that the target time axis contains the time point in daylight saving time according to the time zone information, the time point in daylight saving time in the target time axis is adjusted to be the sum of the time point and the daylight saving time offset.

7. A video playback device applied to a client, the device comprising:

the device comprises a first determining module, a second determining module and a third determining module, wherein the first determining module is used for determining a target time point and a video playback mode for video playback to be performed, the video playback mode is a mode for playing back videos according to a target time zone, and the target time zone is a time zone corresponding to the target time point;

a second determining module, configured to determine, for a target video device to be subjected to video playback, a target playing time point for playing back a video according to the target time zone and the target time point;

and the video playback module is used for playing back the video in the target video equipment according to the target playing time point determined for the target video equipment.

8. The apparatus of claim 7, wherein the target time zone is a client time zone in which the client is located; under the condition that the number of target video equipment to be subjected to video playback is greater than 1, the target playing time points of all the target video equipment are the same; alternatively, the first and second electrodes may be,

the target time zone is a first time zone where the appointed video equipment is located; and under the condition that the number of the target video equipment to be subjected to video playback is larger than 1, corresponding time information of the target playing time point of each target video equipment in the time zone in which each target video equipment is located is the same.

9. An electronic device, characterized in that the device comprises a readable storage medium and a processor;

wherein the readable storage medium is configured to store machine executable instructions;

the processor configured to read the machine executable instructions on the readable storage medium and execute the instructions to implement the steps of the method of any one of claims 1-6.

10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 6.

Technical Field

The present application relates to the field of video monitoring technologies, and in particular, to a video playback method and apparatus, an electronic device, and a computer-readable storage medium.

Background

With the continuous development of society, the application in the field of video monitoring is more and more extensive. In the field of video surveillance, there is often a need for video playback.

The recorded video at the target time point, which is stored in the video recording device, can be played back by video playback in the video window. However, the current video playback method does not consider the situation of crossing time zones, for example, the time zone corresponding to the target time point is different from the time zone where the video recording device is located, in this case, the video recording in the video recording device cannot be played back according to the existing video playback method.

Disclosure of Invention

In view of the above, the present application provides a video playback method, apparatus, electronic device and computer readable storage medium, so as to implement playback of a video in a target video device.

According to a first aspect of the embodiments of the present application, there is provided a video playback method applied to a client, the method including:

determining a target time point and a video playback mode to be subjected to video playback, wherein the video playback mode is a mode for performing playback video according to a target time zone, and the target time zone is a time zone corresponding to the target time point;

determining a target playing time point for playing back the video for target video recording equipment to be subjected to video playback according to the target time zone and the target time point;

and playing back the video in the target video equipment according to the target playing time point determined for the target video equipment.

In one embodiment, the target time zone is a client time zone in which the client is located; under the condition that the number of target video equipment to be subjected to video playback is greater than 1, the target playing time points of all the target video equipment are the same; alternatively, the first and second electrodes may be,

the target time zone is a first time zone where the appointed video equipment is located; and under the condition that the number of the target video equipment to be subjected to video playback is larger than 1, corresponding time information of the target playing time point of each target video equipment in the time zone in which each target video equipment is located is the same.

In an embodiment, the determining, according to the target time zone and the target time point, a target play time point for playing back a video for a target video recording device to be subjected to video recording playback includes:

converting the target time point in the target time zone into a reference time point in a set reference time zone according to a first time difference, wherein the first time difference is determined according to a time zone offset between the target time zone and the reference time zone, or, in the case that the target time point is in daylight saving time of the target time zone, according to a time zone offset between the target time zone and the reference time zone and the daylight saving time offset;

and determining a target playing time point for playing back the video for the target video equipment according to the reference time point.

In an embodiment, if the target time zone is the first time zone, the converting the target time point in the target time zone into a reference time point in a set reference time zone according to the first time difference includes:

determining a second time difference between the target time zone and a second time zone in which target video equipment is located under the condition that the target time zone is different from the second time zone; the second time difference is determined according to a time zone offset between the second time zone and the target time zone, or, in a case where at least one of the target time point and a reference time point is in daylight saving time, according to a daylight saving time offset and a time zone offset between the second time zone and the target time zone; the reference time point is a time point corresponding to the target time point in the second time zone;

and converting the target time point in the target time zone into a reference time point in a set reference time zone according to the first time difference and the second time difference.

In one embodiment, the target time point is a selected time point on a plotted target time axis; the method further comprises the following steps:

and displaying the video information corresponding to at least one time slot in the target time axis in the target video equipment.

In one embodiment, the target time point is a selected time point on a plotted target time axis; the target time axis is drawn in the following way:

determining the target time zone corresponding to the target time axis;

obtaining time zone information of the target time zone; the time zone information includes: the start time information of the target time zone entering daylight saving time and/or the end time information of the daylight saving time ending and the daylight saving time offset; and drawing the target time axis corresponding to the target time zone according to the time zone information, wherein under the condition that the target time axis comprises the time point of daylight saving time, the time point of the target time axis at daylight saving time is adjusted to be the sum of the time point and the daylight saving time offset.

According to a second aspect of the embodiments of the present application, there is provided a video recording and playback apparatus for a client, the apparatus including:

the device comprises a first determining module, a second determining module and a third determining module, wherein the first determining module is used for determining a target time point and a video playback mode for video playback to be performed, the video playback mode is a mode for playing back videos according to a target time zone, and the target time zone is a time zone corresponding to the target time point;

a second determining module, configured to determine, for a target video device to be subjected to video playback, a target playing time point for playing back a video according to the target time zone and the target time point;

and the video playback module is used for playing back the video in the target video equipment according to the target playing time point determined for the target video equipment.

In one embodiment, the target time zone is a client time zone in which the client is located; under the condition that the number of target video equipment to be subjected to video playback is greater than 1, the target playing time points of all the target video equipment are the same; alternatively, the first and second electrodes may be,

the target time zone is a first time zone where the appointed video equipment is located; and under the condition that the number of the target video equipment to be subjected to video playback is larger than 1, corresponding time information of the target playing time point of each target video equipment in the time zone in which each target video equipment is located is the same.

In an embodiment, the determining, by the second determining module, a target playing time point for playing back a video for a target video recording device to be subjected to video recording playback according to the target time zone and the target time point includes:

converting the target time point in the target time zone into a reference time point in a set reference time zone according to a first time difference, wherein the first time difference is determined according to a time zone offset between the target time zone and the reference time zone, or, in the case that the target time point is in daylight saving time of the target time zone, according to a time zone offset between the target time zone and the reference time zone and the daylight saving time offset;

and determining a target playing time point for playing back the video for the target video equipment according to the reference time point.

In an embodiment, when the target time zone is the first time zone, the second determining module converts the target time point in the target time zone into a reference time point in a set reference time zone according to a first time difference, including:

determining a second time difference between the target time zone and a second time zone in which target video equipment is located under the condition that the target time zone is different from the second time zone; the second time difference is determined according to a time zone offset between the second time zone and the target time zone, or, in a case where at least one of the target time point and a reference time point is in daylight saving time, according to a daylight saving time offset and a time zone offset between the second time zone and the target time zone; the reference time point is a time point corresponding to the target time point in the second time zone;

and converting the target time point in the target time zone into a reference time point in a set reference time zone according to the first time difference and the second time difference.

In one embodiment, the target time point is a selected time point on a plotted target time axis; the apparatus further comprises: and the display module is used for displaying the video information corresponding to at least one time slot in the target time axis in the target video equipment.

In one embodiment, the target time point is a selected time point on a plotted target time axis; the apparatus further comprises: a timeline drawing module to:

determining the target time zone corresponding to the target time axis;

obtaining time zone information of the target time zone; the time zone information includes: the start time information of the target time zone entering daylight saving time and/or the end time information of the daylight saving time ending and the daylight saving time offset;

and drawing the target time axis corresponding to the target time zone according to the time zone information, wherein under the condition that the target time axis comprises the time point of daylight saving time, the time point of the target time axis at daylight saving time is adjusted to be the sum of the time point and the daylight saving time offset.

According to a third aspect of embodiments herein, there is provided an electronic device, the device comprising a readable storage medium and a processor;

wherein the readable storage medium is configured to store machine executable instructions;

the processor is configured to read the machine executable instructions on the readable storage medium, and execute the instructions to implement the steps of the video playback method provided in the embodiment of the present application.

According to a fourth aspect of the embodiments of the present application, there is provided a computer-readable storage medium on which a computer program is stored, the computer program, when executed by a processor, implementing the steps of the video playback method provided by the embodiments of the present application.

According to a fifth aspect of the embodiments of the present application, there is provided a computer program stored in a computer readable storage medium, where the computer program is executed by a processor to implement the steps of the video playback method provided by the embodiments of the present application.

According to the technical scheme, under the condition of video playback to be performed, the target playing time point for playing back the video is determined for the target video equipment to be subjected to video playback in a targeted manner according to the target time point to be subjected to video playback and the target time zone corresponding to the target time point (the video playback mode performs playback video according to the target time zone), and then the video in each target video equipment can be played back according to the target playing time point determined for the target video equipment, so that the video in the target video equipment can be played back.

Further, in this embodiment, a target playing time point for playing back a video is determined for a target video recording device to be subjected to video playback according to the target time zone and the target time point, so that when a time zone corresponding to the target time point is different from a time zone in which the target video recording device is located, the target playing time point for playing back the video can also be determined for the target video recording device based on the target time zone and the target time point, and a video in the target video recording device can also be played back when the time zone corresponding to the target time point is different from the time zone in which the target video recording device is located;

further, when the number of the target video recording devices is greater than 1, even if the target video recording devices are distributed in different time zones, according to the video recording playback method, the video recordings in the target video recording devices distributed in different time zones can be played back synchronously.

Drawings

FIG. 1 is a system architecture diagram provided in accordance with an exemplary embodiment of the present application;

fig. 2 is a flowchart of an embodiment of a video playback method according to an exemplary embodiment of the present application;

FIG. 3 is a flowchart illustrating an implementation of step 202 according to an exemplary embodiment of the present application;

FIG. 4 is a flowchart illustrating an implementation of a target timeline rendering according to an exemplary embodiment of the present application;

FIG. 5 is an example of a target timeline provided by an exemplary embodiment of the present application;

FIG. 6 is an example of displaying video recording information based on a target timeline provided by an exemplary embodiment of the present application;

fig. 7 is a block diagram of an embodiment of a video playback apparatus according to an exemplary embodiment of the present application;

FIG. 8 is a block diagram of an embodiment of another video playback device according to an exemplary embodiment of the present application;

fig. 9 is a diagram illustrating a hardware configuration of an electronic device according to an exemplary embodiment of the present application.

Detailed Description

Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.

The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in this application and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.

It is to be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present application. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.

To make the present application easier to understand, the system architecture involved in the present application is first exemplified.

Referring to FIG. 1, a system architecture diagram is provided for an exemplary embodiment of the present application. As shown in FIG. 1, the system architecture may include a client 11, a link 12, a recording device 13, and a recording device 14. Fig. 1 is an illustration of a link and two video recording devices, and in this embodiment, any number of links and video recording devices may be set in fig. 1 according to actual needs, which is not limited in this embodiment.

In fig. 1, a client 11 is connected to a recording device 13 and a recording device 14 via a link 12. The link 12 may include a wireless link, a wired link, a fiber optic cable, or the like, which is not limited in this application.

In fig. 1, as an embodiment, the client 11 may be integrated in a specified device. Such as a smartphone, tablet, laptop, desktop, server, etc. As another embodiment, the client 11 may also be an independent device, and this embodiment is not particularly limited.

In fig. 1, the recording devices 13 and 14 may be devices for storing recorded videos. As an example, here, the apparatus for storing the video may be an image pickup apparatus having a video recording function and a video storage function, and may be, for example, a gun camera, a dome camera, a fisheye camera, or the like. As another embodiment, here, the device for storing the video may also be a device that does not have a video recording function but can store the video, such as a storage medium like a network hard disk. Alternatively, when the device for storing the video does not have the video recording function, it may be connected to a device having the video recording function, such as a gun camera, a dome camera, or a fisheye camera, to acquire the video and store it locally.

So far, the description of the system architecture shown in fig. 1 is completed.

Based on the system architecture illustrated in fig. 1, the following describes a video playback method illustrated in fig. 2.

Referring to fig. 2, a flowchart of an embodiment of a video playback method according to an exemplary embodiment of the present application is provided. In one example, the method may be applied to the client 11 described above.

As shown in fig. 2, the process may include the following steps:

step 201: and determining a target time point and a video playback mode to be subjected to video playback.

As an embodiment, the video playback mode may be set by the user according to actual service requirements. In one example, the video recording/playback mode is a mode in which video recording is played back in accordance with a target time zone, and the target time zone is a time zone corresponding to the target time zone.

In one example, the target time zone may be a time zone in which the client 11 is located (hereinafter referred to as a client time zone), and in this case, the recording/playback mode may be a mode in which recording is played back in accordance with the client time zone.

In another example, the target time zone may be a time zone (hereinafter referred to as a first time zone) in which a video recording device (hereinafter referred to as a designated video recording device) designated in the system architecture shown in fig. 1 is located. As an embodiment, the specified video recording device may be a video recording device selected by a user according to actual needs. In the case where the target time zone is the first time zone, the recording/playback mode may be a mode in which recording is played back in accordance with the first time zone. It should be noted that, the specified video recording device may be switched subsequently according to actual service requirements.

Step 202: and determining a target playing time point for playing back the video for the target video recording equipment to be subjected to video playback according to the target time zone and the target time point, and playing back the video in the target video recording equipment according to the target playing time point determined for the target video recording equipment.

As an embodiment, here, playing back the video in the target video recording device according to the target play time point determined for the target video recording device may include: and respectively sending the target playing time points determined for the target video recording devices to the target video recording devices, so that the target video recording devices find corresponding videos from all the stored videos according to the received target playing time points and send the corresponding videos to the client 11, and the videos in the target video recording devices are synchronously played back through the client 11.

In an embodiment, when the video playback mode is a mode for performing playback video according to a client time zone, if the number of target video devices to be subjected to video playback is greater than 1, the target playing time points of the target video devices are the same, so as to achieve synchronous playback of the monitoring pictures of the target video devices at the same time of the client. The target playing time point may be a reference time point convenient for each target video device to identify, and the following embodiment 1 describes an example.

In another embodiment, when the video playback mode is a mode in which video is played back according to the first time zone, if the number of target video devices to be subjected to video playback is greater than 1, the target playing time points of the target video devices are different, but the corresponding time information of the target playing time points of the target video devices in the time zone in which the target video devices are located is the same, so as to implement synchronous playback of the monitoring pictures of which the local times of the target video devices are the same. Example 2 is described below by way of example.

Thus, the flow shown in fig. 2 is completed.

As can be seen from the flow shown in fig. 2, under the condition of video playback to be performed, a target playing time point for playing back a video is specifically determined for a target video device to be subjected to video playback according to a target time point to be subjected to video playback and a target time zone corresponding to the target time point (a video playback mode performs playback video according to the target time zone), and then videos in the target video devices can be played back according to the target playing time point determined for the target video device, so that video in the target video devices can be played back.

Further, in this embodiment, the target playing time point for playing back the video is determined for the target video recording device to be subjected to video playback according to the target time zone and the target time point, instead of blindly directly adopting the target time point as the target video recording device to determine the target playing time point for playing back the video, so that when the time zone corresponding to the target time point is different from the time zone in which the target video recording device is located, the target playing time point for playing back the video can be determined for the target video recording device based on the target time zone and the target time point, and the video in the target video recording device can be played back when the time zone corresponding to the target time point is different from the time zone in which the target video recording device is located.

Still further, when the number of the target video recording devices is greater than 1, even if the target video recording devices are distributed in different time zones, according to the video recording playback method, the video recordings in the target video recording devices distributed in different time zones can be played back synchronously.

Next, how to determine a target playing time point for playing back the recorded video for the target video recording device to be subjected to video recording playback according to the target time zone and the target time point in step 202 is described.

Referring to fig. 3, an implementation flow for determining a target playing time point in step 202 is provided for an exemplary embodiment of the present application. As shown in fig. 3, the process may include the following steps:

step 301: and converting the target time point in the target time zone into a reference time point in the set reference time zone according to the first time difference.

In one example, in a case where the target time point is not in daylight saving time of the target time zone, the first time difference may be determined according to a time zone offset between the target time zone and the reference time zone, for example, the first time difference may be a time zone offset between the target time zone and the reference time zone. As an example, the reference time zone may be a 0 time zone (also referred to as UTC time zone). Taking the reference time zone as 0 time zone (also called UTC +0) and the target time zone as the eighty-th zone (UTC + 8: 00), the first time difference is 8-0 to 8 hours.

In another example, in the case where the target time point is daylight saving time of the target time zone, the first time difference may be determined according to a time zone offset between the target time zone and the reference time zone, and the daylight saving time offset. For example, the first time difference is a result of adding a daylight saving time offset to a time zone offset between the target time zone and the reference time zone. As an example, the reference time zone may be a 0 time zone (also referred to as UTC time zone). Taking the reference time zone as 0 time zone (also called UTC +0), the target time zone as the eighty-th zone (UTC + 8: 00), and the daylight saving offset as 1 hour, the first time difference is 8+1 to 9 hours.

Based on the first time difference, the target time point in the target time zone may be converted into a reference time point in a set reference time zone according to the first time difference, which is described in embodiment 1 and embodiment 2 below by way of example, and details are not repeated here.

Step 302, determining a target playing time point for playing back the video for the target video device according to the reference time point.

In one example, any video recording device records the video recording time by using the reference time in the reference time zone, and based on this, in this step 302, determining the target playing time point for playing back the video for the target video recording device according to the reference time point may include: and directly determining the reference time point as a target playing time point of the target video equipment for playing back the video. In this way, when the reference time point determined for the target video recording device is sent to the target video recording device as the target playing time point of the target video recording device, the target video recording device directly finds the corresponding video from all the stored videos according to the received target playing time point and sends the corresponding video to the client 11, so as to realize synchronous playback of the videos in the target video recording devices through the client 11.

It should be noted that the above is only an example of determining the target playing time point, and is not limited. The target playing time point may also be determined according to the reference time point by other manners, for example, a result obtained by adding a specified time point to the reference time point is the target playing time point, and the like, which are not illustrated in this embodiment.

The flow shown in fig. 3 is completed.

Through the process shown in fig. 3, it may be finally achieved that the target playing time point for playing back the video is determined for the target video recording device to be subjected to video playback according to the target time zone and the target time point.

The flow shown in fig. 3 is described below by two examples:

23页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种交织模式下隔行视频处理方法、系统、设备及介质

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类