CN112399197A - Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing - Google Patents

Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing Download PDF

Info

Publication number
CN112399197A
CN112399197A CN201910741218.5A CN201910741218A CN112399197A CN 112399197 A CN112399197 A CN 112399197A CN 201910741218 A CN201910741218 A CN 201910741218A CN 112399197 A CN112399197 A CN 112399197A
Authority
CN
China
Prior art keywords
video stream
playing
video
descrambled
video frame
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.)
Pending
Application number
CN201910741218.5A
Other languages
Chinese (zh)
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.)
Shenzhen Ipanel TV Inc
Original Assignee
Shenzhen Ipanel TV Inc
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 Shenzhen Ipanel TV Inc filed Critical Shenzhen Ipanel TV Inc
Priority to CN201910741218.5A priority Critical patent/CN112399197A/en
Publication of CN112399197A publication Critical patent/CN112399197A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
    • H04N21/2347Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs involving video stream encryption
    • 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 or rendering scenes according to encoded video stream scene graphs
    • H04N21/44004Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream 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 or rendering scenes according to encoded video stream scene graphs
    • H04N21/4405Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving video stream decryption
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/643Communication protocols
    • H04N21/64322IP
    • 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/85Assembly of content; Generation of multimedia applications
    • H04N21/854Content authoring
    • H04N21/8547Content authoring involving timestamps for synchronizing content

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The application provides a method, a device, a server and a storage medium for converting IP (Internet protocol) playing to scrambled video stream playing, which are used for determining a target video frame of an unscrambled video stream of current IP playing when the condition that the IP playing is converted to the scrambled video stream playing is met; and descrambling the scrambled video stream which is the same as the unscrambled video stream according to the playing sequence of the video frames to obtain a descrambled video stream, polling the descrambled video stream, determining the video frame of which the first polled playing time is not less than the playing time of the target video frame in the unscrambled video stream, and playing the descrambled video stream from the video frame. Therefore, when the IP playing is switched to the scrambled video stream playing, the method and the device start playing the descrambled video stream from the next video frame adjacent to the target video frame in the play time in the descrambled video stream, and therefore the problem of poor user watching experience caused by serious video frame skipping in the process of switching from the IP playing to the scrambled video stream playing in the prior art is solved.

Description

Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing
Technical Field
The present invention relates to the field of video stream playing technologies, and in particular, to a method, an apparatus, a server, and a storage medium for converting IP playing into scrambled video stream playing.
Background
In the prior art, when live broadcasting starts, program broadcasting is performed by performing IP broadcasting on an unscrambled video stream of a program, and a background acquires a scrambled video stream of the program and switches to the unscrambled video stream to perform program broadcasting after the scrambled video stream is unscrambled to obtain the unscrambled video stream.
Although the switching from the IP playing to the scrambled video stream playing is completed in the live broadcasting process in the prior art, the problem of video picture connection is not considered in the switching process, and the situation that the video frame skipping is serious and the user watching experience is poor often exists in the switching process.
Disclosure of Invention
In view of this, the present invention provides a method, an apparatus, a server and a storage medium for converting IP playing to scrambled video stream playing, so as to avoid the problem of poor user viewing experience caused by serious video frame skipping in the process of switching from IP playing to scrambled video stream playing in the prior art.
In order to achieve the above object, the following solutions are proposed:
a method for converting IP playing to scrambled video stream playing comprises the following steps:
when the preset condition of converting IP playing to scrambled video stream playing is met, determining a target video frame of the unscrambled video stream played by the IP at present;
polling video frames in a current cache according to the sequence of storing the video frames in a descrambled video stream into the cache, wherein the descrambled video stream is obtained by descrambling a scrambled video stream which is the same as the unscrambled video stream, and the video frames in the cache are stored based on the playing sequence of the video frames in the descrambled video stream;
judging whether the playing time of the video frame in the descrambled video stream is not less than the playing time of the target video frame in the unscrambled video stream;
and if so, switching from the IP playing to playing the descrambled video stream from the video frame.
Preferably, the method further comprises the following steps:
receiving a program switching request, and acquiring an unscrambled video stream and a scrambled video stream of the program;
performing IP playing based on the unscrambled video stream;
descrambling the scrambled video stream to obtain a descrambled video stream;
and sequentially storing the video frames in the descrambled video stream into the cache according to the playing sequence of the video frames in the descrambled video stream.
Preferably, the buffer is a first-in first-out queue, the first-in first-out queue is initially empty, and the sequentially storing the video frames in the descrambled video stream into the buffer according to the playing sequence of the video frames in the descrambled video stream includes:
determining a video frame which is not obtained currently and has the most front playing time in the descrambled video stream;
storing the video frame into the first-in first-out queue;
judging whether the first-in first-out queue is full;
if the first-in first-out queue is full, deleting the video frame which is stored in the first-in first-out queue earliest, and returning to execute the step of determining the video frame which is not obtained currently and has the earliest play time in the descrambled video stream;
and if the first-in first-out queue is not full, returning to execute the step of determining the video frame which is not acquired currently and has the most front playing time in the descrambled video stream.
Preferably, the playing time of the video frame is a frame time stamp carried by the video frame.
An apparatus for converting IP playing to scrambled video stream playing, comprising:
the target video frame determining unit is used for determining a target video frame of the unscrambled video stream played by the current IP when a preset condition that the IP playing is converted into the scrambled video stream playing is met;
the video frame polling unit is used for polling the video frames in the current cache according to the sequence of storing the video frames in the descrambled video stream into the cache, wherein the descrambled video stream is obtained by descrambling the scrambled video stream which is the same as the unscrambled video stream, and the video frames in the cache are stored based on the playing sequence of the video frames in the descrambled video stream;
a play time judging unit, configured to judge whether a play time of the video frame in the descrambled video stream is not less than a play time of the target video frame in the unscrambled video stream;
and the video stream switching unit is used for switching from the IP playing to the playing of the descrambled video stream from the video frame if the playing time of the video frame in the descrambled video stream is judged to be not less than the playing time of the target video frame in the unscrambled video stream.
Preferably, the method further comprises the following steps:
a program switching request receiving unit, configured to receive a program switching request, and obtain an unscrambled video stream and a scrambled video stream of the program;
an IP playing unit, configured to perform IP playing based on the unscrambled video stream;
a video stream descrambling unit, configured to descramble the scrambled video stream to obtain a descrambled video stream;
and the buffer unit is used for sequentially storing the video frames in the descrambled video stream into the buffer according to the playing sequence of the video frames in the descrambled video stream.
Preferably, the buffer is a first-in first-out queue, the first-in first-out queue is initially empty, and the buffer unit includes:
a video frame determining unit, configured to determine a video frame in the descrambled video stream, where the playing time of the video frame is the most front and is not currently acquired;
a storing unit, configured to store the video frame into the fifo queue;
the judging unit is used for judging whether the first-in first-out queue is full;
the first execution unit is used for deleting the video frame which is stored in the first-in first-out queue earliest if the first-in first-out queue is full, and returning to trigger the video frame determination unit to execute the process of determining the video frame which is not obtained currently and has the earliest playing time in the descrambled video stream;
and the second execution unit is used for returning to trigger the video frame determination unit to execute a process of determining a video frame with the most front playing time which is not currently acquired in the descrambled video stream if the first-in first-out queue is not full.
Preferably, the playing time of the video frame is a frame time stamp carried by the video frame.
A server, comprising: at least one memory and at least one processor; the processor calls the program stored in the memory, and the program is used for realizing the method for converting the IP playing to the scrambled video stream playing.
A computer-readable storage medium having stored thereon computer-executable instructions for performing the method of converting IP playback to scrambled video stream playback.
The application provides a method, a device, a server and a storage medium for converting IP (Internet protocol) playing to scrambled video stream playing, which are used for determining a target video frame of an unscrambled video stream of current IP playing when the condition that the IP playing is converted to the scrambled video stream playing is met; and descrambling the scrambled video stream which is the same as the unscrambled video stream according to the playing sequence of the video frames to obtain a descrambled video stream, polling the descrambled video stream, determining the video frame of which the first polled playing time is not less than the playing time of the target video frame in the unscrambled video stream, and playing the descrambled video stream from the video frame. Therefore, when the IP playing is switched to the scrambled video stream playing, the method and the device start playing the descrambled video stream from the next video frame adjacent to the target video frame in the play time in the descrambled video stream, and therefore the problem of poor user watching experience caused by serious video frame skipping in the process of switching from the IP playing to the scrambled video stream playing in the prior art is solved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a method for converting an IP playing to a scrambled video stream playing according to an embodiment of the present application;
fig. 2 is a flowchart of another method for converting IP playing to scrambled video stream playing according to an embodiment of the present application;
fig. 3 is a flowchart of a method for sequentially storing video frames in a descrambled video stream into a fifo queue according to a playing order of the video frames in the descrambled video stream according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an apparatus for converting IP playing to scrambled video stream playing according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Example (b):
fig. 1 is a flowchart of a method for converting an IP playing to a scrambled video stream playing according to an embodiment of the present application.
As shown in fig. 1, the method includes:
s101, when a preset condition that IP playing is converted into scrambled video stream playing is met, determining a target video frame of an unscrambled video stream played by the current IP;
generally, when live broadcasting starts, an unscrambled video stream of a live program is played first (a process of playing the unscrambled video stream of the program can be considered as IP playing), and after a certain time of playing, the unscrambled video stream obtained by unscrambling the scrambled video stream of the program is switched to play (a process of playing the unscrambled video stream obtained by unscrambling the scrambled video stream of the program can be considered as scrambled video stream playing).
In the embodiment of the application, a condition for converting the IP playing to the scrambled video stream playing is preset, where the condition for converting the IP playing to the scrambled video stream playing may include an IP playing time length. For example, 5 minutes. And determining that the conditions for converting IP playing to scrambled video stream playing are met after the program is subjected to IP playing for 5 minutes.
As an embodiment of the present application, the condition for converting the IP playing to the scrambled video stream playing may further include that the user requesting the live broadcast is detected to be a legal user for the scrambled video stream playing. The account of the user who detects that the request for live broadcast is a scrambled video stream legal account can be a user who detects that the request for live broadcast is a scrambled video stream legal account. For example, if the account of the user is an account that has purchased the playing permission of the scrambled video stream, the account of the user may be considered as a legal account of the scrambled video stream.
In the embodiment of the application, after the live broadcast is started, the IP broadcast is firstly carried out, after the time length for carrying out the IP broadcast reaches the preset IP broadcast time length, whether the user requesting the live broadcast is a legal user for the scrambled video stream broadcast or not is detected, and if the user requesting the live broadcast is detected to be the legal user for the scrambled video stream broadcast, the condition that the IP broadcast is converted into the scrambled video stream broadcast is determined to be met. When the account of the user requesting the live broadcast is detected to be a legal account of the scrambled video stream, the user requesting the live broadcast is determined to be a legal user playing the scrambled video stream.
The above is only a preferred way of presetting the conditions for converting the IP playing to the scrambled video stream playing provided by the embodiment of the present application, and the inventor can set the conditions according to his own needs, which is not limited herein.
In the embodiment of the application, in the process of live broadcasting the program, the unscrambled video stream is played according to the playing sequence of the video frames in the unscrambled video stream of the program so as to perform IP playing on the program; in the process of performing IP playing on a program, if it is determined that a preset condition for converting IP playing to scrambled video stream playing is satisfied, a video frame currently playing in an unscrambled video stream is determined (for convenience of distinction, the video frame determined here may be regarded as a target video frame).
S102, polling video frames in a current cache according to the sequence of storing the video frames in the descrambled video stream into the cache, wherein the descrambled video stream is obtained by descrambling the scrambled video stream which is the same as the unscrambled video stream, and the video frames in the cache are stored based on the playing sequence of the video frames in the descrambled video stream;
as an embodiment of the present application, when a live broadcast starts, on one hand, video frames in an unscrambled video stream of a program are played to implement IP playing, on the other hand, a scrambled video stream of the program is descrambled to obtain a descrambled video stream, and each video frame in the descrambled video stream is sequentially stored in a buffer according to a playing sequence of the video frames in the descrambled video stream.
In this embodiment of the present application, when switching from live broadcasting of one program to live broadcasting of another program, the buffer may be emptied first, so that when performing live broadcasting of another program, each video frame in the descrambled video stream, which is stored in the buffer and only obtained by descrambling the scrambled video stream of the another program, is descrambled.
S103, judging whether the playing time of the video frame in the descrambled video stream is not less than the playing time of the target video frame in the unscrambled video stream; if yes, go to step S104;
in the embodiment of the application, according to the sequence of storing the video frames in the descrambled video stream into the cache, polling the video frames in the current cache, and judging whether the playing time of the currently polled video frames in the descrambled video is not less than the playing time of the target video frames in the unscrambled video; if yes, switching to playing the descrambled video from the video frame; if not, polling the next video frame with the playing time adjacent to the video frame and later than the video frame from the buffer, and judging whether the playing time of the next video frame in the descrambled video is not less than the playing time … of the target video frame in the unscrambled video or not, and so on.
S104, switching from IP playing to playing of the descrambled video stream from the video frame.
Fig. 2 is a flowchart of another method for converting IP playing to scrambled video stream playing according to an embodiment of the present application.
As shown in fig. 2, the method includes:
s201, receiving a program switching request, and acquiring an unscrambled video stream and a scrambled video stream of a program;
in the embodiment of the application, in the live broadcasting process, a program switching request can be received so as to realize the switching of the live broadcasting program. The program switching request indicates a program to be switched to, after receiving the program switching request, the unscrambled video stream and the scrambled video stream of the program to be switched to, which are indicated by the program switching request, need to be acquired, and the following steps S202 to S209 are executed based on the acquired unscrambled video stream and scrambled video stream.
For example, when program 1 is broadcast directly, a program switching request may be received, where the program switching request indicates that there is program 2, and at this time, the unscrambled video stream and the scrambled video stream of program 2 need to be acquired, and the following steps S202 to S209 are performed based on the acquired unscrambled video stream and the scrambled video stream.
S202, IP playing is carried out based on the unscrambled video stream;
s203, descrambling the scrambled video stream to obtain a descrambled video stream;
in the embodiment of the present application, the execution sequence between step S202 and step S203 is not limited, and step S202 and step S203 may be executed simultaneously; step S202 may be executed first, and step S203 may be executed; step S202 may be performed after step S203 is performed.
It should be noted that: after the scrambled video stream is descrambled to obtain a descrambled video stream, step S204 needs to be executed, that is, each video frame in the descrambled video stream is sequentially stored in the buffer according to the playing sequence of the video frames in the descrambled video stream.
In this embodiment, before step S204 is executed, the buffer may be emptied, so as to store the video frames in the descrambled video stream in the initially empty buffer.
S204, sequentially storing the video frames in the descrambled video stream into a cache according to the playing sequence of the video frames in the descrambled video stream;
s205, judging whether a preset condition of converting IP playing into scrambled video stream playing is met; if yes, go to step S206;
in the embodiment of the present application, when the execution of step S202 is started, step S205 is started, and when it is determined that the preset condition for converting IP playing to scrambled video stream playing is satisfied, step S206 is executed.
S206, determining a target video frame of the unscrambled video stream played by the current IP;
s207, according to the sequence of storing the video frames in the descrambled video stream into a cache, acquiring a first video frame which is not polled in the current cache;
in the embodiment of the application, the unscrambled video stream is composed of a plurality of video frames with different playing times, and each video frame in the unscrambled video stream is played according to the sequence of the playing times, so that the IP playing can be realized. For example, if the unscrambled video stream is composed of 5 video frames, which are respectively video frame 1, video frame 2, video frame 3, video frame 4 and video frame 5, the playing time of video frame 1 is earlier than that of video frame 2, the playing time of video frame 2 is earlier than that of video frame 3, the playing time of video frame 3 is earlier than that of video frame 4, and the playing time of video frame 4 is earlier than that of video frame 5; then video frame 1, video frame 2, video frame 3, video frame 4 and video frame 5 are played in sequence, so that IP playing can be realized.
The descrambled video stream obtained by descrambling the scrambled video stream also comprises a plurality of video frames with different playing time, and each video frame in the descrambled video stream is played according to the sequence of the playing time, so that the scrambled video stream can be played. For example, if the descrambled video stream is composed of 5 video frames, which are respectively the video frame 6, the video frame 7, the video frame 8, the video frame 9 and the video frame 10, the playing time of the video frame 6 is earlier than that of the video frame 7, the playing time of the video frame 7 is earlier than that of the video frame 8, the playing time of the video frame 8 is earlier than that of the video frame 9, and the playing time of the video frame 9 is earlier than that of the video frame 10; then the video frame 6, the video frame 7, the video frame 8, the video frame 9 and the video frame 10 are played in sequence, and the scrambled video stream playing can be realized.
If for a program, the unscrambled video stream is composed of the video frames 1, 2, 3, 4 and 5; the descrambled video stream obtained after the scrambled video stream is descrambled consists of the video frame 6, the video frame 7, the video frame 8, the video frame 9 and the video frame 10; in the process of playing the program, firstly playing the unscrambled video stream of the program to realize IP playing, and sequentially storing each video frame in the unscrambled video stream into a cache according to the sequence of playing time; in the process of IP playing, if the condition that the preset condition that the IP playing is converted into the scrambled video stream playing is met is determined, the target video frame which is currently played and is positioned in the unscrambled video stream can be determined; and sequentially polling each video frame in the cache according to the sequence stored in the cache until a video frame with the playing time not earlier than the playing time of the target video frame is obtained (for example, the target video frame is the video frame 3, and the video frame with the playing time not earlier than the playing time of the target video frame is the video frame 9), and then starting to play the descrambling video stream from the obtained video frame (the video frame 9).
In the embodiment of the present application, the playing time of a video frame is a frame timestamp carried by the video frame.
S208, judging whether the playing time of the video frame in the descrambled video stream is not less than the playing time of the target video frame in the unscrambled video stream; if yes, go to step S209; if not, returning to execute the step S207;
s209, switching from the IP playing to the playing of the descrambled video stream from the video frame.
In the embodiment of the present application, the buffer is a first-in first-out queue, and the manner of sequentially storing the video frames in the descrambled video stream into the first-in first-out queue according to the playing sequence of the video frames in the descrambled video stream may be shown in fig. 3.
As shown in fig. 3, the method includes:
s301, determining a video frame which is not currently acquired and has the most front playing time in the descrambled video stream;
s302, storing the video frame into a first-in first-out queue;
s303, judging whether the first-in first-out queue is full; if the FIFO queue is full, go to step S304; if the FIFO queue is not full, returning to step S301;
s304, deleting the video frame stored earliest in the first-in first-out queue, and returning to execute the step S301.
Fig. 4 is a schematic structural diagram of an apparatus for converting IP playing to scrambled video stream playing according to an embodiment of the present application.
As shown in fig. 4, the apparatus includes:
a target video frame determining unit 41, configured to determine a target video frame of an unscrambled video stream currently played in an IP when a preset condition for converting an IP play to a scrambled video stream play is met;
a video frame polling unit 42, configured to poll a video frame in a current buffer according to an order in which video frames in a descrambled video stream are stored in the buffer, where the descrambled video stream is obtained by descrambling a scrambled video stream that is the same as the unscrambled video stream, and the video frames in the buffer are stored based on a playing order of the video frames in the descrambled video stream;
a play time judgment unit 43, configured to judge whether the play time of the video frame in the descrambled video stream is not less than the play time of the target video frame in the unscrambled video stream;
and the video stream switching unit 44 is configured to switch from the IP playing to playing the descrambled video stream from the video frame if it is determined that the playing time of the video frame in the descrambled video stream is not less than the playing time of the target video frame in the unscrambled video stream.
Further, an apparatus for converting IP playing to scrambled video stream playing provided in this embodiment of the present application may further include:
a program switching request receiving unit, configured to receive a program switching request, and obtain an unscrambled video stream and a scrambled video stream of a program;
an IP playing unit, which is used for carrying out IP playing based on the unscrambled video stream;
a video stream descrambling unit, configured to descramble the scrambled video stream to obtain a descrambled video stream;
and the buffer unit is used for sequentially storing the video frames in the descrambled video stream into a buffer according to the playing sequence of the video frames in the descrambled video stream.
In this embodiment of the present application, the buffer is a first-in first-out queue, the first-in first-out queue is initially empty, and the buffer unit includes:
the video frame determining unit is used for determining a video frame which is not obtained currently and is most advanced in playing time in the descrambled video stream;
the storing unit is used for storing the video frames into a first-in first-out queue;
the judging unit is used for judging whether the first-in first-out queue is full;
the first execution unit is used for deleting the video frame which is stored in the first-in first-out queue earliest if the first-in first-out queue is full, and returning to the trigger video frame determination unit to execute the process of determining the video frame which is not obtained currently and has the earliest play time in the descrambled video stream;
and the second execution unit is used for returning to trigger the video frame determination unit to execute a process of determining the video frame which is not currently acquired and has the earliest playing time in the descrambled video stream if the first-in first-out queue is not full.
In the embodiment of the present application, the playing time of a video frame is a frame timestamp carried by the video frame.
An embodiment of the present application further provides a server, where the server includes: at least one memory and at least one processor; the memory stores a program, and the processor calls the program stored in the memory, and the program is used for realizing the method for converting the IP playing to the scrambled video stream playing provided by the embodiment.
Embodiments of the present application further provide a computer-readable storage medium, where computer-executable instructions are stored in the computer-readable storage medium, and the computer-executable instructions are configured to execute the method for converting IP playing to scrambled video stream playing provided in the foregoing embodiments.
The application provides a method, a device, a server and a storage medium for converting IP (Internet protocol) playing to scrambled video stream playing, which are used for determining a target video frame of an unscrambled video stream of current IP playing when the condition that the IP playing is converted to the scrambled video stream playing is met; and descrambling the scrambled video stream which is the same as the unscrambled video stream according to the playing sequence of the video frames to obtain a descrambled video stream, polling the descrambled video stream, determining the video frame of which the first polled playing time is not less than the playing time of the target video frame in the unscrambled video stream, and playing the descrambled video stream from the video frame. Therefore, when the IP playing is switched to the scrambled video stream playing, the method and the device start playing the descrambled video stream from the next video frame adjacent to the target video frame in the play time in the descrambled video stream, and therefore the problem of poor user watching experience caused by serious video frame skipping in the process of switching from the IP playing to the scrambled video stream playing in the prior art is solved.
In this document, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A method for converting IP playing to scrambled video stream playing is characterized by comprising the following steps:
when the preset condition of converting IP playing to scrambled video stream playing is met, determining a target video frame of the unscrambled video stream played by the IP at present;
polling video frames in a current cache according to the sequence of storing the video frames in a descrambled video stream into the cache, wherein the descrambled video stream is obtained by descrambling a scrambled video stream which is the same as the unscrambled video stream, and the video frames in the cache are stored based on the playing sequence of the video frames in the descrambled video stream;
judging whether the playing time of the video frame in the descrambled video stream is not less than the playing time of the target video frame in the unscrambled video stream;
and if so, switching from the IP playing to playing the descrambled video stream from the video frame.
2. The method of claim 1, further comprising:
receiving a program switching request, and acquiring an unscrambled video stream and a scrambled video stream of the program;
performing IP playing based on the unscrambled video stream;
descrambling the scrambled video stream to obtain a descrambled video stream;
and sequentially storing the video frames in the descrambled video stream into the cache according to the playing sequence of the video frames in the descrambled video stream.
3. The method of claim 2, wherein the buffer is a first-in first-out queue, the first-in first-out queue is initially empty, and the sequentially storing the video frames in the descrambled video stream into the buffer according to the playing order of the video frames in the descrambled video stream comprises:
determining a video frame which is not obtained currently and has the most front playing time in the descrambled video stream;
storing the video frame into the first-in first-out queue;
judging whether the first-in first-out queue is full;
if the first-in first-out queue is full, deleting the video frame which is stored in the first-in first-out queue earliest, and returning to execute the step of determining the video frame which is not obtained currently and has the earliest play time in the descrambled video stream;
and if the first-in first-out queue is not full, returning to execute the step of determining the video frame which is not acquired currently and has the most front playing time in the descrambled video stream.
4. The method of claim 1, wherein the playing time of the video frame is a frame time stamp carried by the video frame.
5. An apparatus for converting IP playing to scrambled video stream playing, comprising:
the target video frame determining unit is used for determining a target video frame of the unscrambled video stream played by the current IP when a preset condition that the IP playing is converted into the scrambled video stream playing is met;
the video frame polling unit is used for polling the video frames in the current cache according to the sequence of storing the video frames in the descrambled video stream into the cache, wherein the descrambled video stream is obtained by descrambling the scrambled video stream which is the same as the unscrambled video stream, and the video frames in the cache are stored based on the playing sequence of the video frames in the descrambled video stream;
a play time judging unit, configured to judge whether a play time of the video frame in the descrambled video stream is not less than a play time of the target video frame in the unscrambled video stream;
and the video stream switching unit is used for switching from the IP playing to the playing of the descrambled video stream from the video frame if the playing time of the video frame in the descrambled video stream is judged to be not less than the playing time of the target video frame in the unscrambled video stream.
6. The apparatus of claim 5, further comprising:
a program switching request receiving unit, configured to receive a program switching request, and obtain an unscrambled video stream and a scrambled video stream of the program;
an IP playing unit, configured to perform IP playing based on the unscrambled video stream;
a video stream descrambling unit, configured to descramble the scrambled video stream to obtain a descrambled video stream;
and the buffer unit is used for sequentially storing the video frames in the descrambled video stream into the buffer according to the playing sequence of the video frames in the descrambled video stream.
7. The apparatus of claim 6, wherein the buffer is a first-in-first-out queue, the first-in-first-out queue initially being empty, the buffer unit comprising:
a video frame determining unit, configured to determine a video frame in the descrambled video stream, where the playing time of the video frame is the most front and is not currently acquired;
a storing unit, configured to store the video frame into the fifo queue;
the judging unit is used for judging whether the first-in first-out queue is full;
the first execution unit is used for deleting the video frame which is stored in the first-in first-out queue earliest if the first-in first-out queue is full, and returning to trigger the video frame determination unit to execute the process of determining the video frame which is not obtained currently and has the earliest playing time in the descrambled video stream;
and the second execution unit is used for returning to trigger the video frame determination unit to execute a process of determining a video frame with the most front playing time which is not currently acquired in the descrambled video stream if the first-in first-out queue is not full.
8. The apparatus of claim 6, wherein the playing time of the video frame is a frame time stamp carried by the video frame.
9. A server, comprising: at least one memory and at least one processor; the memory stores a program, and the processor calls the program stored in the memory, and the program is used for realizing the method for converting IP playing to scrambled video stream playing according to any one of claims 1-4.
10. A computer-readable storage medium having stored thereon computer-executable instructions for performing the method of converting IP playback to scrambled video stream playback as claimed in any of claims 1-4.
CN201910741218.5A 2019-08-12 2019-08-12 Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing Pending CN112399197A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910741218.5A CN112399197A (en) 2019-08-12 2019-08-12 Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910741218.5A CN112399197A (en) 2019-08-12 2019-08-12 Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing

Publications (1)

Publication Number Publication Date
CN112399197A true CN112399197A (en) 2021-02-23

Family

ID=74602375

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910741218.5A Pending CN112399197A (en) 2019-08-12 2019-08-12 Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing

Country Status (1)

Country Link
CN (1) CN112399197A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114866787A (en) * 2022-07-04 2022-08-05 深圳市必提教育科技有限公司 Live broadcast implementation method and system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4215366A (en) * 1977-10-19 1980-07-29 Feature Film Services Subscriber-limited reception television broadcast security encoder-decoder system
US6058192A (en) * 1996-08-06 2000-05-02 Greg Jarque Universal signal processor and method of processing
CN101415087A (en) * 2008-11-27 2009-04-22 中兴通讯股份有限公司 Method and apparatus for displaying mobile phone television business and dynamic content distribution business
CN101980541A (en) * 2010-11-23 2011-02-23 华亚微电子(上海)有限公司 Digital television receiving device and channel-switching method thereof
CN108777813A (en) * 2018-06-28 2018-11-09 广州视源电子科技股份有限公司 Switching method, device, terminal and the storage medium of scrambled number TV programme
CN108965907A (en) * 2018-07-11 2018-12-07 北京字节跳动网络技术有限公司 For playing the methods, devices and systems of video

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4215366A (en) * 1977-10-19 1980-07-29 Feature Film Services Subscriber-limited reception television broadcast security encoder-decoder system
US6058192A (en) * 1996-08-06 2000-05-02 Greg Jarque Universal signal processor and method of processing
CN101415087A (en) * 2008-11-27 2009-04-22 中兴通讯股份有限公司 Method and apparatus for displaying mobile phone television business and dynamic content distribution business
CN101980541A (en) * 2010-11-23 2011-02-23 华亚微电子(上海)有限公司 Digital television receiving device and channel-switching method thereof
CN108777813A (en) * 2018-06-28 2018-11-09 广州视源电子科技股份有限公司 Switching method, device, terminal and the storage medium of scrambled number TV programme
CN108965907A (en) * 2018-07-11 2018-12-07 北京字节跳动网络技术有限公司 For playing the methods, devices and systems of video

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114866787A (en) * 2022-07-04 2022-08-05 深圳市必提教育科技有限公司 Live broadcast implementation method and system

Similar Documents

Publication Publication Date Title
JP5870924B2 (en) Transmitting apparatus, transmitting method, receiving apparatus, receiving method, program, and broadcasting system
CN111010614A (en) Method, device, server and medium for displaying live caption
US9066121B2 (en) Addressable advertising switch by decoupling decoding from service acquisitions
CN110213603B (en) Live streaming transmission method, device, server, system and storage medium
WO2010044926A3 (en) Providing television broadcasts over a managed network and interactive content over an unmanaged network to a client device
EP2410739A3 (en) Start-over feature for ongoing television programs in a switched digital video system
CA2758763C (en) Method and device for fast pushing unicast stream in fast channel change
CN109089131B (en) Screen recording live broadcast method, device, equipment and storage medium based on IOS system
CN109714622B (en) Video data processing method and device and electronic equipment
EP2652958B1 (en) Methods, a client and a server for handling an mpeg transport stream
CN106791994B (en) Low-delay quick broadcasting method and device
EP3101903A1 (en) Hybrid network system, channel content replay method, and hybrid set top box
CN103313129A (en) Method and device for video playing
WO2017101393A1 (en) Method and device for continuously playing video
CN112399197A (en) Method, device, server and medium for converting IP (Internet protocol) playing into scrambled video stream playing
KR101829497B1 (en) Methods and apparatuses for resuming paused media
KR100738043B1 (en) Media service method and apparatus using change of unicast/multicast based on channel information
WO2015154549A1 (en) Data processing method and device
CN112312191A (en) Display method and device of video advertisement material
CN111866526B (en) Live broadcast service processing method and device
CN106612462B (en) Fast forward and fast backward processing method and terminal
WO2017076009A1 (en) Program watch-back method, player and terminal
WO2015117291A1 (en) Method and device for switching network television program, and television system
CN113573114A (en) Screen projection method and device, electronic equipment and storage medium
JP2010258489A (en) Video display device, reception device, transmission and reception system, and video display method

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