CN115396729B - Video target frame determining method, device, equipment and storage medium - Google Patents

Video target frame determining method, device, equipment and storage medium Download PDF

Info

Publication number
CN115396729B
CN115396729B CN202211035665.7A CN202211035665A CN115396729B CN 115396729 B CN115396729 B CN 115396729B CN 202211035665 A CN202211035665 A CN 202211035665A CN 115396729 B CN115396729 B CN 115396729B
Authority
CN
China
Prior art keywords
frame
video
time
decoding
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202211035665.7A
Other languages
Chinese (zh)
Other versions
CN115396729A (en
Inventor
陈博
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Bigo Technology Singapore Pte Ltd
Original Assignee
Bigo Technology Singapore Pte Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Bigo Technology Singapore Pte Ltd filed Critical Bigo Technology Singapore Pte Ltd
Priority to CN202211035665.7A priority Critical patent/CN115396729B/en
Publication of CN115396729A publication Critical patent/CN115396729A/en
Priority to PCT/CN2023/112828 priority patent/WO2024041406A1/en
Application granted granted Critical
Publication of CN115396729B publication Critical patent/CN115396729B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/44004Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving video buffer management, e.g. video decoder buffer or video display buffer
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/472End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
    • H04N21/47217End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content for controlling playback functions for recorded or on-demand content, e.g. using progress bars, mode or play-point indicators or bookmarks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • H04N21/8455Structuring of content, e.g. decomposing content into time segments involving pointers to the content, e.g. pointers to the I-frames of the video stream

Abstract

The embodiment of the application discloses a method, a device, equipment and a storage medium for determining a video target frame, wherein the method comprises the following steps: detecting the type of a video frame in a video, and storing frame information of the video frame into a cache according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index, an associated ending frame index, a frame decoding starting time and a frame decoding ending time; acquiring a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval; and searching based on the decoding time reference frame to obtain a video target frame. According to the scheme, the retrieval efficiency of the video target frames is improved, so that video playing response is more timely, smooth video playing can be realized, and user experience is improved.

Description

Video target frame determining method, device, equipment and storage medium
Technical Field
The embodiment of the application relates to the technical field of video playing, in particular to a method, a device, equipment and a storage medium for determining a video target frame.
Background
In the video playing process, in order to meet the playing requirement of the user, the user can drag the progress bar to modify the playing progress of the video, or open the video and designate to start playing from a certain progress. At this time, the player internally retrieves video frames corresponding to the progress selected by the user, and performs picture playback from the determined video frames.
In the related art, for the case of an I-frame index table carrying video, an I-frame near a target frame is located according to the I-frame index table, and then frame-by-frame decoding is started based on the I-frame until the target frame, and rendering is performed to obtain a display picture. However, in the case of missing I-frame index table of video, a frame-by-frame search is required from the first frame of video to determine the target frame, which causes the problems of long operation time and high performance loss, so that the playing of video is slow, and the user experience is seriously affected.
Disclosure of Invention
The embodiment of the application provides a method, a device, equipment and a storage medium for determining a video target frame, which solve the problems of long operation time consumption and high performance loss when determining the video target frame in the related technology, improve the retrieval efficiency of the video target frame, enable video playing response to be more timely, realize smooth video playing and improve user experience.
In a first aspect, an embodiment of the present application provides a method for determining a video target frame, where the method includes:
detecting the type of a video frame in a video, and storing frame information of the video frame into a cache according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index, an associated ending frame index, a frame decoding starting time and a frame decoding ending time;
acquiring a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval;
and searching based on the decoding time reference frame to obtain a video target frame.
In a second aspect, an embodiment of the present application further provides a video target frame determining apparatus, including:
the information buffer module is configured to detect the type of a video frame in the video, store the frame information of the video frame into a buffer according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index and an associated ending frame index, frame decoding starting time and frame decoding ending time;
the search query module is configured to acquire a selected target playing point, determine a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval, and search the video target frame based on the decoding time reference frame.
In a third aspect, an embodiment of the present application further provides a video object frame determining apparatus, including:
one or more processors;
storage means for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method for determining a video object frame according to the embodiments of the present application.
In a fourth aspect, embodiments of the present application also provide a storage medium storing computer-executable instructions that, when executed by a computer processor, are configured to perform the video object frame determination method of embodiments of the present application.
In a fifth aspect, the embodiment of the present application further provides a computer program product, where the computer program product includes a computer program, where the computer program is stored in a computer readable storage medium, and where at least one processor of the device reads and executes the computer program from the computer readable storage medium, so that the device performs the video object frame determining method according to the embodiment of the present application.
In the embodiment of the application, the type of a video frame in the video is detected, the frame information of the video frame is stored in a buffer memory according to the detection result to obtain a detection interval, wherein the detection interval comprises an I frame index and an associated ending frame index, a frame decoding starting time and a frame decoding ending time, a selected target playing point is obtained, a decoding time reference frame is determined according to the display time of the video target frame and the frame decoding starting time and the frame decoding ending time recorded in the detection interval, and then the video target frame is obtained by searching based on the decoding time reference frame. According to the video target frame searching method and device, the searching efficiency of the video target frame is improved, the video playing response is more timely, smooth video playing can be achieved, and user experience is improved.
Drawings
Fig. 1 is a flowchart of a method for determining a video target frame according to an embodiment of the present application;
FIG. 2 is a flowchart of a method for storing frame information of a video frame in a buffer according to a detection result according to an embodiment of the present application;
FIG. 3 is a flowchart of a method for determining a decoding time reference frame based on a detection interval search according to an embodiment of the present application;
FIG. 4 is a flowchart of a method for determining a decoding time reference frame using a binary search method according to an embodiment of the present application;
FIG. 5 is a flowchart of a method for determining a video target frame based on a decoded time reference frame according to an embodiment of the present application;
FIG. 6 is a flowchart of a method for determining a video target frame and displaying a frame according to an embodiment of the present application;
fig. 7 is a block diagram of a video object frame determining apparatus according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of a video object frame determining apparatus according to an embodiment of the present application.
Detailed Description
Embodiments of the present application will be described in further detail below with reference to the drawings and examples. It should be understood that the particular embodiments described herein are illustrative only and are not limiting of embodiments of the application. It should be further noted that, for convenience of description, only some, but not all of the structures related to the embodiments of the present application are shown in the drawings.
The terms first, second and the like in the description and in the claims, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged, as appropriate, such that embodiments of the present application may be implemented in sequences other than those illustrated or described herein, and that the objects identified by "first," "second," etc. are generally of a type, and are not limited to the number of objects, such as the first object may be one or more. Furthermore, in the description and claims, "and/or" means at least one of the connected objects, and the character "/", generally means that the associated object is an "or" relationship.
Fig. 1 is a flowchart of a method for determining a video target frame, which is provided in an embodiment of the present application, and can be used for determining a corresponding video frame based on a selected play point when playing a video, where the method can be executed by a computing device, such as a server, a notebook computer, a tablet computer, a smart phone, etc., and specifically includes the following steps:
step S101, detecting the type of a video frame in the video, and storing the frame information of the video frame into a cache according to a detection result to obtain a detection interval.
In one embodiment, the type of video frames in the video is detected for the case that the original I-frame information of the video is missing. The deletion of the I-frame information may be deletion, damage or analysis abnormality of an I-frame index table that should be carried by the original video.
In one embodiment, the process of detecting the type of video frame in a video may be: in the video playing process, detecting the type of video frames frame by frame along with the playing of the video; the video file may be decoded in advance, and the video frame type may be detected frame by frame. For example, when the video file is opened and not yet played, the steps are executed after the designated playing time point is received.
And caching the frame information of the video frame according to the detection result to obtain a detection interval. The detection interval is used for searching the video target frames corresponding to the target playing time points.
In one embodiment, the information recorded in the probe interval includes an I-frame index in the video frame and an associated end frame index, frame decoding start time, and frame decoding end time. Wherein the I-frame index uniquely corresponds to an I-frame in one video. Illustratively, if the 1 st video frame detected is a video frame of an I-frame type, then the index of the video frame is recorded as 1 when added to the buffer, and when the video frame of a second I-frame type is detected, then the index is added as 4 assuming that the video frame is a 4 th frame. Optionally, the generated detection interval may further include an index number sequentially increasing according to the detected video frame of the I frame type upon addition. For example, a video frame of a first I frame type is detected, the corresponding index number is 1 at the time of recording, a video frame of a second I frame type is detected, the corresponding index number is 2 at the time of recording, and so on. Wherein the associated end frame index is the index of the last video frame associated with the video frame of the currently recorded I-frame type. Optionally, each GOP (Group of Pictures, video frame group) is taken as a calculation unit, where a GOP includes a plurality of video frames, and the first frame is a video frame of an I-frame type, and the subsequent frames may include a video frame of a P-frame type and a video frame of a B-frame type. Where P frames are forward reference frames in video codec, compression rate is better than I frames, but P frames cannot be used independently to render pictures, and must rely on I frames and other P frames that have occurred before in the same GOP. B frames are bi-directional reference frames in video codec, with higher compression than I and P frames, but B frames cannot be used independently to render pictures, e.g., depending on the I and P frames that occur before and after them. The ending frame index associated with the I frame index may be the index of the last video frame in the same GOP.
The frame decoding start time associated with the I frame index is recorded as the time when the video frame of the I frame type starts to be decoded, such as a decoding time stamp when the video frame is decoded; the frame decoding end time associated with the I frame index is the decoding end time of the last video frame in the same computational unit (e.g., a GOP).
Fig. 2 is a flowchart of a method for storing frame information of a video frame in a buffer according to a detection result, where, as shown in fig. 2, the method specifically includes:
in step S1011, during the video playing process, detecting the type of each video frame in turn, if the type of the video frame is an I frame type, generating an I frame index and an associated end frame index, and recording the frame decoding start time and the frame decoding end time of the video frame.
Illustratively, taking a video segment containing 9 video frames as an example, as shown in the following table, each video frame number corresponds to one video frame, and the corresponding video frame types include an I frame, a B frame, and a P frame, and a frame decoding start time and a frame decoding end time of each video frame. For example, the video frame with video frame number 5 has a frame type of B-frame type, and the corresponding frame decoding start time is 160 ms and the frame decoding end time is 200 ms.
Video frame number Video frame type Frame decoding start time Frame decoding end time
1 I 0ms 40ms
2 B 40ms 80ms
3 P 80ms 120ms
4 I 120ms 160ms
5 B 160ms 200ms
6 P 200ms 240ms
7 I 240ms 280ms
8 B 280ms 320ms
9 P 320ms 360ms
At this time, when the buffering of the frame information is performed, if the first frame is a video frame of the I frame type, an I frame index and an associated end frame index are generated, and a frame decoding start time and a frame decoding end time of the video frame are recorded. Accordingly, the following table shows:
index number I-frame index End frame index Frame decoding start time Frame decoding end time
1 1 1 0ms 40ms
Step S1012, if the video frame type is a non-I frame type, updating the end frame index and the frame decoding end time of the video frame of the associated I frame type.
Illustratively, taking the previous example as an example, when playing the second frame, the frame type is detected, and if it is a non-I frame type, updating of the end frame index and the frame decoding end time is performed. The specific steps can be as follows: the end frame index value of the video frame is incremented by one and the frame decoding end time is updated to the frame decoding end time of the video frame of the non-I frame type. The updated table at this time is as follows:
index number I-frame index End frame index Frame decoding start time Frame decoding end time
1 1 2 0ms 80ms
When the third frame is played, the frame type is P frame, correspondingly, the ending frame index value of the video frame is increased by one, and the frame decoding ending time is updated to the frame decoding ending time of the video frame of the non-I frame type. The updated table at this time is as follows:
index number I-frame index End frame index Frame decoding start time Frame decoding end time
1 1 3 0ms 120ms
When the fourth frame is played, the frame type is I frame, correspondingly, an I frame index and an associated ending frame index are generated, and the frame decoding starting time and the frame decoding ending time of the video frame are recorded. The updated table at this time is as follows:
index number I-frame index End frame index Frame decoding start time Frame decoding end time
1 1 3 0ms 120ms
2 4 4 120ms 160ms
And so on to buffer frame information to generate a detection interval.
Step S102, obtaining a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point, and the frame decoding start time and the frame decoding end time recorded in the detection interval.
In one embodiment, after buffering of the frame information is performed, a determination of the video target frame may be performed based on the buffered frame information. When a user drags a play bar or directly locates a play point, a selected target play point is acquired, and a frame decoding start time and a frame decoding end time recorded in a detection interval are searched according to the display time (for example, 1000 ms) of a video target frame to determine a decoding time reference frame.
Optionally, fig. 3 is a flowchart of a method for determining a decoding time reference frame based on a detection interval search according to an embodiment of the present application. The method for improving the searching efficiency remarkably comprises the following steps:
step S1021, obtaining video frame information, and obtaining a search interval according to the frame decoding time recorded by the video frame information, the playing time of the target playing point and the detection interval.
Step S1022, determining a decoding time reference frame according to the display time of the video target frame and the frame decoding start time and the frame decoding end time corresponding to the search interval.
The video frame information may be an already recorded video play point and corresponding time information. In an exemplary embodiment, the time range of the detection interval is from 0 th second to 1800 th seconds, the playing time of the target playing point is, for example, 100 th seconds, and at this time, the video frame corresponding to 500 th seconds is recorded in the recorded video frame information, and when the video target frame is determined, only the interval range from 0 th second to 500 th seconds needs to be searched, and the interval range is marked as the search interval, so that the search query efficiency is improved.
Optionally, the search is performed using a dichotomy in the search process, since the previously determined search intervals have been ordered sequentially based on the decoding time of the video frames. Fig. 4 is a flowchart of a method for determining a decoding time reference frame by using a binary search method according to an embodiment of the present application, which specifically includes:
step S1023, performing binary search in the search interval, and determining the frame decoding start time and the frame decoding end time associated with the playing time of the target playing point.
Illustratively, it is assumed that a search is performed in a search interval having an I-frame index of n to an I-frame index of m. Determining a frame decoding start time and a frame decoding end time corresponding to the (n+m)/2 th frame index by adopting a binary search method, determining whether the playing time of the target playing point is in the range of the frame decoding start time and the frame decoding end time, and if the playing time is greater than the frame decoding end time, performing binary search between the (n+m)/2 th frame and the m th frame; if it is less than the frame decoding start time, a binary search is performed between the nth frame to the (n+m)/2 th frame to determine the frame decoding start time and the frame decoding end time at which it is located. If it is at the frame decoding start time and the frame decoding end time, the decoding start time and the play time at the frame decoding end time are determined as the target play point. It should be noted that the determined frame decoding start time and frame decoding end time associated with the play time of the target play point may not be the frame decoding start time and frame decoding end time at which the play time of the target play point is actually located. For example, when a time point at which the play time is 1000 ms is determined, the frame decoding start time and the frame decoding end time at which it is actually located may be 1200 ms to 1400 ms, and the above-determined associated frame decoding start time and frame decoding end time may be 900 ms to 1100 ms, for example.
Step S1024, corresponding I frame index and associated ending frame index are determined according to the frame decoding start time and the frame decoding end time.
Step S1025, determining the video frame corresponding to the determined I frame index and the associated ending frame index as a decoding time reference frame.
Illustratively, if it is determined that the video play frame is between I-frame index 150 and end frame index 156. Alternatively, the video frame corresponding to the I frame index 150 and the subsequent 6 frames of video frames may be used as decoding time reference frames, or the video frame corresponding to the I frame index 150 may be used as decoding time reference frames.
And step S103, searching based on the decoding time reference frame to obtain a video target frame.
In one embodiment, since the aforementioned determined decoding time reference frame is a video frame determined based on the decoding time, there is a difference between the decoding time and the display time. Alternatively, the video frames in the video file are arranged according to the decoding time from small to large, but the display time is not necessarily arranged from small to large, so in order to use a search algorithm (such as a binary search method) for improving the search efficiency, the search algorithm must be performed based on an ordered sequence, so after determining the decoding time reference frame by using the decoding time, the final video target frame is determined based on the decoding time reference frame. Although the decoded time reference frame may not be identical to the final video target frame, the final video target frame must be in the vicinity of the decoded time reference frame.
Optionally, fig. 5 is a flowchart of a method for determining a video target frame based on a decoded time reference frame according to an embodiment of the present application, as shown in fig. 5, specifically including:
step S1031, obtaining display time information of the video frames, where the display time information includes each video frame of the video and a corresponding display time.
Step S1032, searching and determining the video target frame based on the target playing point and the decoding time reference frame in the display time information.
In one embodiment, after determining the decoded time reference frame, a search is performed from the data containing the display time information based on the decoded time reference frame and the target play point to determine the final video target frame. Optionally, the display time information is searched for the display time of the video frame corresponding to the decoding time reference frame and the nearby video frame, and the video frame whose display time includes the playing time of the target playing point is determined as the video target frame.
As can be seen from the above, the type of the video frame in the video is detected, the frame information of the video frame is stored in the buffer memory according to the detection result to obtain a detection interval, wherein the detection interval includes an I-frame index and an associated end frame index, a frame decoding start time and a frame decoding end time, a selected target play point is obtained, a decoding time reference frame is determined according to the display time of the video target frame and the frame decoding start time and the frame decoding end time recorded in the detection interval, and then the video target frame is obtained by searching based on the decoding time reference frame. According to the video target frame searching method and device, the searching efficiency of the video target frame is improved, the video playing response is more timely, smooth video playing can be achieved, and user experience is improved.
Fig. 6 is a flowchart of a method for determining a video target frame and displaying a picture according to an embodiment of the present application, as shown in fig. 6, including:
step S201, detecting the type of the video frame in the video, and storing the frame information of the video frame into a cache according to the detection result to obtain a detection interval.
Step S202, obtaining a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point, and the frame decoding start time and the frame decoding end time recorded in the detection interval.
And step S203, searching based on the decoding time reference frame to obtain a video target frame.
Step S204, judging whether the video target frame is of an I frame type, if so, executing step S205, otherwise, executing step S206.
And step S205, decoding and displaying the video target frame.
And S206, carrying out forward search one by one on the video frames to determine I-frame video frames corresponding to the video target frames, and decoding and displaying the video target frames based on the I-frame video frames.
In one embodiment, since the decoding of the video target frame requires the video frame of the I frame type, if the video target frame itself is of the I frame type, the decoding can be directly performed, otherwise, after the video frame of the corresponding I frame type is determined by performing forward search of the video frame one by one, the decoding display is performed on the video target frame based on the I frame video frame.
According to the scheme, the video target frames are retrieved and determined efficiently and accurately, and the corresponding decoding display is performed, so that the video playing response is more timely, smooth video playing can be realized, and the user experience is improved.
On the basis of the technical scheme, the method for determining the audio target frame is further included. Optionally, after searching based on the decoded time reference frame to obtain the video target frame, the method further comprises: and searching the corresponding audio target frame in the audio frame information according to the display time of the video target frame so as to be used for synchronous playing of the video target frame and the audio target frame. Alternatively, a binary search method may be employed to search the audio frame information for the first audio frame after the display time as the audio target frame. Wherein, the audio frame information records each audio frame of the video and the corresponding time point in sequence according to the audio playing sequence.
Fig. 7 is a block diagram of a video object frame determining apparatus according to an embodiment of the present application, where the apparatus is configured to execute the video object frame determining method according to the foregoing embodiment, and the apparatus has functional modules and beneficial effects corresponding to the executing method. As shown in fig. 7, the apparatus specifically includes: an information caching module 101, and a search query module 102, wherein,
the information buffer module 101 is configured to detect the type of a video frame in a video, and store frame information of the video frame into a buffer according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index and an associated end frame index, a frame decoding start time and a frame decoding end time;
the search query module 102 is configured to obtain a selected target play point, determine a decoding time reference frame according to the play time of the target play point and the frame decoding start time and the frame decoding end time recorded in the detection interval, and search the video target frame based on the decoding time reference frame.
According to the scheme, the type of the video frame in the video is detected, the frame information of the video frame is stored in a buffer memory according to the detection result to obtain a detection interval, wherein the detection interval comprises an I frame index and an associated end frame index, frame decoding start time and frame decoding end time, a selected target playing point is obtained, a decoding time reference frame is determined according to the display time of the video target frame and the frame decoding start time and the frame decoding end time recorded in the detection interval, and then the video target frame is obtained by searching based on the decoding time reference frame. According to the video target frame searching method and device, the searching efficiency of the video target frame is improved, the video playing response is more timely, smooth video playing can be achieved, and user experience is improved.
In a possible embodiment, the information caching module 101 is configured to:
in the video playing process, detecting the type of each video frame in sequence;
if the type of the video frame is an I frame type, generating an I frame index and an associated ending frame index, and recording the frame decoding starting time and the frame decoding ending time of the video frame;
if the video frame type is a non-I frame type, updating an end frame index and a frame decoding end time of the video frame of the associated I frame type.
In a possible embodiment, the information caching module 101 is configured to:
adding one to the end frame index value of the video frame;
and updating the frame decoding end time to the frame decoding end time of the video frame of the non-I frame type.
In one possible embodiment, the search query module 102 is configured to:
acquiring video frame information, and obtaining a search interval according to the frame decoding time recorded by the video frame information, the playing time of the target playing point and the detection interval, wherein the interval range of the search interval is smaller than the range of the detection interval;
and determining a decoding time reference frame according to the playing time of the target playing point, and the frame decoding starting time and the frame decoding ending time corresponding to the searching interval.
In one possible embodiment, the search query module 102 is configured to:
performing binary search in the search interval, and determining a frame decoding start time and a frame decoding end time associated with the playing time of the target playing point;
determining a corresponding I frame index and an associated ending frame index according to the frame decoding start time and the frame decoding end time;
and determining the video frame corresponding to the determined I frame index and the associated ending frame index as a decoding time reference frame.
In one possible embodiment, the search query module 102 is configured to:
acquiring display time information of video frames, wherein the display time information comprises each video frame of a video and corresponding display time;
and searching and determining a video target frame in the display time information based on the target playing point and the decoding time reference frame.
In a possible embodiment, the apparatus further comprises a decoding display module 103 configured to:
after searching based on the decoding time reference frame to obtain a video target frame, decoding and displaying the video target frame under the condition that the video target frame is of an I frame type;
the search query module 102 is configured to:
under the condition that the video target frame is not of an I frame type, forward searching one by one of the video frames is carried out to determine an I frame video frame corresponding to the video target frame;
the decoding display module 103 is configured to: and decoding and displaying the video target frame based on the I frame video frame.
In one possible embodiment, the apparatus further comprises an audio frame determination module configured to:
after searching based on the decoding time reference frame to obtain a video target frame, searching corresponding audio target frames in audio frame information according to the playing time of the target playing point so as to be used for synchronous playing of the video target frame and the audio target frame.
Fig. 8 is a schematic structural diagram of a video object frame determining apparatus according to an embodiment of the present application, where, as shown in fig. 8, the apparatus includes a processor 201, a memory 202, an input device 203, and an output device 204; the number of processors 201 in the device may be one or more, one processor 201 being taken as an example in fig. 8; the processor 201, memory 202, input devices 203, and output devices 204 in the apparatus may be connected by a bus or other means, for example in fig. 8. The memory 202 is used as a computer readable storage medium for storing software programs, computer executable programs and modules, such as program instructions/modules corresponding to the video object frame determination method in the embodiment of the present application. The processor 201 executes various functional applications of the device and data processing by running software programs, instructions and modules stored in the memory 202, i.e., implements the video object frame determination method described above. The input means 203 may be used to receive entered numeric or character information and to generate key signal inputs related to user settings and function control of the device. The output device 204 may include a display device such as a display screen.
The embodiment of the present application also provides a storage medium containing computer executable instructions, which when executed by a computer processor, are configured to perform a video object frame determination method described in the above embodiment, where the method includes:
detecting the type of a video frame in a video, and storing frame information of the video frame into a cache according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index, an associated ending frame index, a frame decoding starting time and a frame decoding ending time;
acquiring a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval;
and searching based on the decoding time reference frame to obtain a video target frame.
It should be noted that, in the embodiment of the video object frame determining apparatus, each unit and module included are only divided according to the functional logic, but not limited to the above-mentioned division, so long as the corresponding functions can be implemented; in addition, the specific names of the functional units are also only for distinguishing from each other, and are not used to limit the protection scope of the embodiments of the present application.
In some possible embodiments, the aspects of the method provided by the present application may also be implemented as a program product, which includes a program code for causing a computer device to perform the steps of the method according to the various exemplary embodiments of the present application described in the present specification, when the program product is run on the computer device, for example, the computer device may perform the video object frame determination method described in the embodiment of the present application. The program product may be implemented using any combination of one or more readable media.

Claims (10)

1. A method for determining a video object frame, comprising:
detecting the type of a video frame in a video, and storing frame information of the video frame into a cache according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index, an associated ending frame index, a frame decoding starting time and a frame decoding ending time;
acquiring a selected target playing point, and determining a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval;
searching based on the decoding time reference frame to obtain a video target frame, wherein the method comprises the steps of obtaining display time information of the video frame, wherein the display time information comprises each video frame of the video and corresponding display time, and searching in the display time information based on the target playing point and the decoding time reference frame to determine the video target frame.
2. The method for determining a video target frame according to claim 1, wherein detecting the type of the video frame in the video, and storing the frame information of the video frame in a buffer memory according to the detection result to obtain a detection interval, comprises:
in the video playing process, detecting the type of each video frame in sequence;
if the type of the video frame is an I frame type, generating an I frame index and an associated ending frame index, and recording the frame decoding starting time and the frame decoding ending time of the video frame;
if the video frame type is a non-I frame type, updating an end frame index and a frame decoding end time of the video frame of the associated I frame type.
3. The method according to claim 2, wherein updating the end frame index and the frame decoding end time of the video frame of the associated I-frame type comprises:
adding one to an ending frame index value of the video frame of the associated I frame type;
and updating the frame decoding end time to the frame decoding end time of the video frame of the non-I frame type.
4. The video object frame determination method according to claim 1, wherein the determining a decoding time reference frame based on the play time of the object play point and the frame decoding start time and the frame decoding end time recorded in the probe section includes:
acquiring video frame information, and obtaining a search interval according to the frame decoding time recorded by the video frame information, the playing time of the target playing point and the detection interval, wherein the interval range of the search interval is smaller than the range of the detection interval;
and determining a decoding time reference frame according to the playing time of the target playing point, and the frame decoding starting time and the frame decoding ending time corresponding to the searching interval.
5. The method according to claim 4, wherein determining the decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time corresponding to the search interval comprises:
performing binary search in the search interval, and determining a frame decoding start time and a frame decoding end time associated with the playing time of the target playing point;
determining a corresponding I frame index and an associated ending frame index according to the frame decoding start time and the frame decoding end time;
and determining the video frame corresponding to the determined I frame index and the associated ending frame index as a decoding time reference frame.
6. The method according to any one of claims 1 to 5, further comprising, after the searching for the video target frame based on the decoded time reference frame:
decoding and displaying the video target frame under the condition that the video target frame is of an I frame type;
and under the condition that the video target frame is not of an I frame type, carrying out forward search one by one on the video frame to determine an I frame video frame corresponding to the video target frame, and decoding and displaying the video target frame based on the I frame video frame.
7. The method according to any one of claims 1 to 5, further comprising, after the searching for the video target frame based on the decoded time reference frame:
and searching corresponding audio target frames in the audio frame information according to the playing time of the target playing point so as to be used for synchronously playing the video target frames and the audio target frames.
8. A video object frame determination apparatus, comprising:
the information buffer module is configured to detect the type of a video frame in the video, store the frame information of the video frame into a buffer according to a detection result to obtain a detection interval, wherein the detection interval comprises an I frame index and an associated ending frame index, frame decoding starting time and frame decoding ending time;
the search query module is configured to acquire a selected target playing point, determine a decoding time reference frame according to the playing time of the target playing point and the frame decoding start time and the frame decoding end time recorded in the detection interval, and search the video target frame based on the decoding time reference frame, wherein the search query module is specifically configured to acquire display time information of the video frame, the display time information comprises each video frame of the video and corresponding display time, and search is performed in the display time information based on the target playing point and the decoding time reference frame to determine the video target frame.
9. A video target frame determination device, the device comprising: one or more processors; storage means for storing one or more programs that when executed by the one or more processors cause the one or more processors to implement the video object frame determination method of any of claims 1-7.
10. A storage medium storing computer executable instructions which, when executed by a computer processor, are for performing the video object frame determination method of any one of claims 1-7.
CN202211035665.7A 2022-08-26 2022-08-26 Video target frame determining method, device, equipment and storage medium Active CN115396729B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202211035665.7A CN115396729B (en) 2022-08-26 2022-08-26 Video target frame determining method, device, equipment and storage medium
PCT/CN2023/112828 WO2024041406A1 (en) 2022-08-26 2023-08-14 Video target frame determination method, apparatus and device, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211035665.7A CN115396729B (en) 2022-08-26 2022-08-26 Video target frame determining method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN115396729A CN115396729A (en) 2022-11-25
CN115396729B true CN115396729B (en) 2023-12-08

Family

ID=84123571

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211035665.7A Active CN115396729B (en) 2022-08-26 2022-08-26 Video target frame determining method, device, equipment and storage medium

Country Status (2)

Country Link
CN (1) CN115396729B (en)
WO (1) WO2024041406A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117528154B (en) * 2024-01-04 2024-03-29 湖南快乐阳光互动娱乐传媒有限公司 Video delivery method and device, electronic equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1349351A (en) * 2000-10-13 2002-05-15 北京算通数字技术研究中心有限公司 Method of generating data stream index file and using said file accessing frame and shearing lens
CN104717509A (en) * 2015-03-31 2015-06-17 北京奇艺世纪科技有限公司 Method and device for decoding video
CN112822522A (en) * 2020-12-31 2021-05-18 北京梧桐车联科技有限责任公司 Video playing method, device, equipment and storage medium
CN112929755A (en) * 2021-01-21 2021-06-08 稿定(厦门)科技有限公司 Video file playing method and device in progress dragging process
CN113225585A (en) * 2020-01-21 2021-08-06 腾讯科技(深圳)有限公司 Video definition switching method and device, electronic equipment and storage medium
CN113542888A (en) * 2021-07-09 2021-10-22 北京百度网讯科技有限公司 Video processing method and device
CN113573101A (en) * 2021-07-09 2021-10-29 百果园技术(新加坡)有限公司 Video encoding method, device, equipment and storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100765787B1 (en) * 2006-06-15 2007-10-12 삼성전자주식회사 Method for reproducing compressed and encoded video data stream and apparatus thereof
KR101727316B1 (en) * 2010-10-08 2017-04-17 삼성전자 주식회사 Video playing apparatus and location search method thereof
CN109348251B (en) * 2018-10-08 2021-05-11 腾讯科技(深圳)有限公司 Method and device for video playing, computer readable medium and electronic equipment
CN111083573A (en) * 2018-10-22 2020-04-28 杭州海康威视系统技术有限公司 Video file processing method and device and storage node
CN111436005B (en) * 2019-01-15 2022-03-08 北京字节跳动网络技术有限公司 Method and apparatus for displaying image
CN113259779B (en) * 2021-07-01 2021-09-17 杭州觅睿科技股份有限公司 Video processing method, device, equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1349351A (en) * 2000-10-13 2002-05-15 北京算通数字技术研究中心有限公司 Method of generating data stream index file and using said file accessing frame and shearing lens
CN104717509A (en) * 2015-03-31 2015-06-17 北京奇艺世纪科技有限公司 Method and device for decoding video
CN113225585A (en) * 2020-01-21 2021-08-06 腾讯科技(深圳)有限公司 Video definition switching method and device, electronic equipment and storage medium
CN112822522A (en) * 2020-12-31 2021-05-18 北京梧桐车联科技有限责任公司 Video playing method, device, equipment and storage medium
CN112929755A (en) * 2021-01-21 2021-06-08 稿定(厦门)科技有限公司 Video file playing method and device in progress dragging process
CN113542888A (en) * 2021-07-09 2021-10-22 北京百度网讯科技有限公司 Video processing method and device
CN113573101A (en) * 2021-07-09 2021-10-29 百果园技术(新加坡)有限公司 Video encoding method, device, equipment and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
McFIS: Better I-frame for video coding;M. Paul et al.;《2010 IEEE International Symposium on Circuits and Systems (ISCAS)》;2171-2174 *
对等网络视频点播系统研究;宋伟;《中国优秀硕士学位论文全文数据库信息科技辑(月刊)》(2009年第05期);全文 *

Also Published As

Publication number Publication date
WO2024041406A1 (en) 2024-02-29
CN115396729A (en) 2022-11-25

Similar Documents

Publication Publication Date Title
US10025695B2 (en) Enhancing GUI automation testing using video
WO2022143688A1 (en) Video frame extraction processing method, apparatus and device, and medium
WO2023011094A1 (en) Video editing method and apparatus, electronic device, and storage medium
CN107426603B (en) Video playing method and device
CN109275047B (en) Video information processing method and device, electronic equipment and storage medium
CN115396729B (en) Video target frame determining method, device, equipment and storage medium
US20180157657A1 (en) Method, apparatus, client terminal, and server for associating videos with e-books
US10169053B2 (en) Loading a web page
WO2016165346A1 (en) Method and apparatus for storing and playing audio file
JP2015204105A (en) Method and device for providing recommendation information
CN112532998B (en) Method, device and equipment for extracting video frame and readable storage medium
US9779093B2 (en) Spatial seeking in media files
CN110046263B (en) Multimedia recommendation method, device, server and storage medium
CN104751870A (en) Information processing method and electronic equipment
US10237512B1 (en) Automated in-play detection and video processing
WO2017107887A1 (en) Method and apparatus for switching group picture on mobile terminal
CN111263211B (en) Method for caching video data and terminal equipment
CN100488246C (en) Resume reproduction system
JP2020525949A (en) Media search method and device
US8443015B2 (en) Apparatus and method for providing content and content analysis results
CN114036431A (en) Page cache skipping method and device, electronic equipment and storage medium
CN111147954A (en) Thumbnail extraction method and device
CN111354383B (en) Audio defect positioning method and device and terminal equipment
US10726877B2 (en) System and method for generating a compression invariant motion timeline
CN111083497A (en) Video screenshot method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant