WO2018095302A1 - Method and system for displaying video file recorded on set-top box - Google Patents

Method and system for displaying video file recorded on set-top box Download PDF

Info

Publication number
WO2018095302A1
WO2018095302A1 PCT/CN2017/111944 CN2017111944W WO2018095302A1 WO 2018095302 A1 WO2018095302 A1 WO 2018095302A1 CN 2017111944 W CN2017111944 W CN 2017111944W WO 2018095302 A1 WO2018095302 A1 WO 2018095302A1
Authority
WO
WIPO (PCT)
Prior art keywords
video frame
file
video
recorded
video file
Prior art date
Application number
PCT/CN2017/111944
Other languages
French (fr)
Chinese (zh)
Inventor
姚小伟
Original Assignee
深圳创维数字技术有限公司
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 深圳创维数字技术有限公司 filed Critical 深圳创维数字技术有限公司
Publication of WO2018095302A1 publication Critical patent/WO2018095302A1/en

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/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/433Content storage operation, e.g. storage operation in response to a pause request, caching operations
    • H04N21/4331Caching operations, e.g. of an advertisement for later insertion during playback
    • 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/433Content storage operation, e.g. storage operation in response to a pause request, caching operations
    • H04N21/4334Recording operations
    • 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/8549Creating video summaries, e.g. movie trailer
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/44Receiver circuitry for the reception of television signals according to analogue transmission standards
    • H04N5/4448Receiver circuitry for the reception of television signals according to analogue transmission standards for frame-grabbing

Definitions

  • the present disclosure relates to the field of set top box technologies, for example, to a display method and system for recording video files of a set top box.
  • Digital TV is popular among people for its rich programs and diversified functions, attracting more and more users. For users who watch TV, such a rich digital program is not overwhelming. In order to look back later, video recording of the program is required.
  • PVR Personal Video Record
  • the traditional PVR recording management interface presents the recorded file information through a file list.
  • the display mode when the video file is recorded in the related art is mainly displayed in the form of a file list.
  • the central one program has a recording time of 20160801 and a program name of 152122. It also displays the channel name, the date of recording, and the duration of the video.
  • the file list presentation format of the traditional PVR recording management interface is too simple and single.
  • the present disclosure provides a method and system for displaying a recorded video file of a set top box, which aims to solve the problem that the existing recording management interface in the related art is displayed in the form of a file list, and it is difficult to distinguish the difference between different videos, which brings great The inconvenience of the technical problem.
  • the present disclosure provides a method for displaying a recorded video file of a set top box, including:
  • the thumbnail is displayed as the cover of the recorded video file
  • the video frame of the recorded video file is captured, and after the valid video frame is captured, the valid video frame is classified according to a specific image format.
  • the storage is stored in the specified cache directory, and the captured valid video frame is displayed as the cover of the recorded video file.
  • the video frame of the recorded video file is captured, and after the valid video frame is captured, the effective video is captured.
  • the step of storing the frame in the specified cache format to the specified cache directory and displaying the captured valid video frame as the cover of the recorded video file includes:
  • the PVR recording management interface After the PVR recording management interface sends the recorded video file to the background thread, the recorded video file is played in the background, and the video frame is captured by the snapshot function according to a preset rule, and the video frame that meets the predetermined condition is captured as a video frame.
  • Valid video frame
  • the recorded video file is displayed with the thumbnail as a cover.
  • the recorded video file is played in the background, and the video frame is captured by the snapshot function according to a preset rule.
  • the steps of taking a video frame that meets a predetermined condition as a valid video frame include:
  • the background thread is started, and the video player is started in the background to play the recorded video file;
  • the video frame When the number of color points of the captured video frame is greater than or equal to a predetermined threshold, the video frame is stopped to be captured, and the current video frame is used as the effective video frame; when the number of color points of the captured video frame is less than a predetermined threshold Then, the video frame is continuously captured, and when the number of times the video frame is captured is greater than the predetermined number of times, the video frame is stopped, and the video frame with the largest number of captured color points is used as the effective video frame, and the color point refers to a pixel point in the video frame that satisfies a preset condition, where the absolute value of the absolute value of the difference between the r component, the g component, and the b component of the pixel is greater than 50 pixel.
  • the step of storing the valid video frame into a bmp format thumbnail and storing the file in a specified cache directory comprises:
  • the valid video frame is encapsulated into a thumbnail of the bmp format and stored in a specified cache directory, and the key name is used as a file name of the thumbnail of the bmp format.
  • the present disclosure also provides a display system for recording video files of a set top box, including:
  • the detecting and acquiring module is configured to: when detecting the personal video recording PVR set top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file;
  • a first cover display control module configured to display the thumbnail as a cover of the recorded video file when a thumbnail has been detected in the information of the recorded video file
  • a second cover display control module configured to: when there is no thumbnail in the information of the recorded video file, capture the video frame of the recorded video file, and after capturing the valid video frame, The valid video frame is stored in a specified cache directory according to a specific picture format, and the captured valid video frame is displayed as a cover of the recorded video file.
  • the second cover display control module includes:
  • a preset picture display unit configured to: when there is no thumbnail in the information of the recorded video file, obtain a preset picture as a cover of the recorded video file;
  • the effective video frame capture unit is configured to play the recorded video file in the background after the PVR recording management interface sends the recorded video file to the background thread, and capture the video frame by using the snapshot function according to a preset rule. Grab a video frame that meets the predetermined condition as a valid video frame;
  • a storage unit configured to encapsulate the valid video frame into a bitmap of a bitmap bmp format and store the image in a specified cache directory
  • thumbnail display unit configured to display the recorded video file with the thumbnail as a cover when the recorded video file is still detected in the PVR recording management interface.
  • the valid video frame capture unit includes:
  • Recording a video file background playing unit configured to: after the data of the recorded video file is sent to the background thread in the PVR recording management interface, start a background thread, and start a video player in the background to play the recorded video file;
  • a color point number determining unit configured to capture a video frame during playback of the video player, And determining whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold
  • the first valid video frame determining unit is configured to stop capturing the video frame and use the current video frame as the effective video frame when the number of the color points of the captured video frame is greater than or equal to a predetermined threshold;
  • the second effective video frame determining unit is configured to continue to capture the video frame when the number of color points of the captured video frame is less than a predetermined threshold, and stop capturing the video frame when the number of times the video frame is captured is greater than a predetermined number of times.
  • the video frame with the largest number of captured color points is used as the effective video frame, wherein the color point refers to a pixel point in the video frame that satisfies a preset condition, and the preset condition is the pixel point.
  • the absolute value of the difference between the two components of the r component, the g component, and the b component has a maximum value greater than 50 pixel points.
  • the step of storing the valid video frame into a bmp format thumbnail and storing the file in a specified cache directory comprises:
  • a key generating unit configured to acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the message digest algorithm fifth version MD5 algorithm;
  • the encapsulation and storage unit is configured to encapsulate the valid video frame into a bmp format thumbnail and store it in a specified cache directory, and use the key name as a file name of the bmp format thumbnail.
  • the present disclosure also provides a computer readable storage medium storing computer executable instructions for performing the above method.
  • the present disclosure also provides a display device for recording a video file of a set top box, the display device of the set top box recording the video file comprising one or more processors, a memory and one or more programs, the one or more programs being stored in the memory
  • the above method is performed when executed by one or more processors.
  • the present disclosure also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions, when the program instructions are executed by a computer, Having the computer perform any of the methods described above.
  • the present disclosure provides a method and system for displaying a recorded video file of a set top box.
  • the thumbnail of the video frame in the recorded file is displayed as a cover of the recorded file, so that the user can conveniently and quickly obtain the difference of different recorded video files, thereby Quickly get the recorded video file you want to play.
  • FIG. 1 is a schematic diagram showing a recorded video file in a file list manner in the related art.
  • FIG. 2 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
  • FIG. 3 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
  • FIG. 4 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
  • FIG. 5 is a schematic diagram of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
  • FIG. 6 is a functional block diagram of a recording file cover display system based on a PVR set top box according to an embodiment.
  • FIG. 7 is a schematic structural diagram of a display system for recording a video file of a set top box according to an embodiment.
  • FIG. 8 is a schematic structural diagram of a display system for recording a video file of another set top box according to an embodiment.
  • FIG. 9 is a schematic structural diagram of a display system for recording a video file of another set top box according to an embodiment.
  • FIG. 10 is a schematic diagram showing the hardware structure of a display device for recording a video file of a set top box according to an embodiment.
  • This embodiment provides a flowchart of a cover display method for recording a video file based on a PVR set top box. As shown in FIG. 2, the method includes:
  • Step 100 When detecting that the PVR set-top box enters the PVR recording management interface, obtain information of the recorded video file, determine whether there is a thumbnail in the information of the recorded video file, and when there is a thumbnail, perform step 200, when there is no thumbnail Then, step 300 is performed.
  • the PVR recording management interface also known as the PVR recording resource management scene menu
  • the thumbnail is generally used for a scene such as a computer desktop or a webpage, and may be a picture processed by the original image in a compressed manner. Because the thumbnails are small and load fast, a quick preview is possible.
  • the essence of PVR recording is to store program video data in a format such as MPEG2 or MPEG4 when playing a program. During playback, a dedicated video player is called for decoding playback.
  • Step 200 The PVR recording management interface displays the thumbnail as the cover of the recorded video file.
  • the PVR recording management interface is displayed. Show thumbnails.
  • Step 300 The PVR recording management interface captures the video frame of the recorded video file, and after capturing the valid video frame, stores the video frame in the specified cache format according to a specific image format, and uses the captured valid video frame as the recorded video.
  • the cover of the file is displayed.
  • black frames or gray frames there may be black frames or gray frames in a video, and in order to extract a full-filled video frame as a thumbnail, black frames or gray frames are eliminated, and colorful video frames are captured as much as possible.
  • a certain frame of video data that is, a video frame, is composed of a plurality of pixels, which may be black and white, gray or color. If a rich video frame is to be extracted, the color data pixels of the frame of the video data are included. The more the better.
  • the set-top box decodes and plays the video in the background, the video frame can be captured by the snapshot function. In order to reduce the possibility of capturing the video frame of the black frame or the gray frame, the video frame can be captured by searching for different positions during playback.
  • step 300 includes:
  • Step 301 When it is detected that the recorded video file has no thumbnail, the preset picture is obtained as a cover of the recorded video file for display.
  • Step 302 The PVR recording management interface sends the recorded video file to the background thread, plays the recorded video file in the background, captures the video frame through the snapshot function according to a preset rule, and captures the video frame that meets the predetermined condition as the effective video frame.
  • Step 303 Encapsulate the valid video frame into a bitmap of a bitmap (Bmp) format and store it in a specified cache directory.
  • Step 304 When it is detected that the PVR recording management interface still has a recorded video file, the recorded video file is displayed with the thumbnail as a cover.
  • the PVR recording management interface takes the current path, the name of all the recording files owned by the current directory folder, and the number of recording files that can be displayed on the current display interface.
  • the current display interface is the first page
  • the current user operation mode is The information data such as page up or page down is transmitted to the background thread.
  • the video player is started first (the player runs in the background, the video output is turned off, so the user does not affect the operation in the PVR recording management interface), and then plays in the background according to the name of the recorded file, and crawls A valid video frame for this recording.
  • decoding in the background first judge this recording Whether the file already has a corresponding thumbnail, if there is already a thumbnail, the thumbnail is used as a cover; if there is no thumbnail, the recording is played in the background.
  • a valid video frame is captured according to the method of capturing a video frame.
  • the user can have key operations on the PVR recording management interface, such as turning pages to the previous page or the next page.
  • the PVR recording management interface will promptly display the current display interface.
  • the index number of the first recording file of the current page is thrown to the background thread in time.
  • the background thread interrupts the current operation in time, and timely tracks the current display interface to parse the video frame of the recording file of the current display interface.
  • the background thread After the background thread captures the valid video frame of the recorded file, it must be stored in the specified cache directory according to the bmp format, and promptly notify the PVR recording management interface to refresh.
  • the PVR recording management interface receives the refresh message, it judges the new capture. Whether the recording file to the video frame is on the current screen, if it exists, then obtain the thumbnail of the recording file and refresh the PVR recording management interface to the specified cache directory.
  • the method may further include: when the PVR recording management interface exits, the background thread needs to send an exit message, the background thread stops decoding the recorded video file, closes the background video player, and finally destroys the background thread.
  • step 302 includes:
  • Step 321 The PVR recording management interface sends the recorded video file data to the background thread. After the background thread is started, the video player is started in the background, and the video player plays the recorded video file in the background.
  • Step 322 Grab a video frame during playback of the video player, and determine whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold.
  • Step 323 If the number of color points of the captured video frame is greater than or equal to a predetermined threshold, stop capturing the video frame and set the current video frame as a valid video frame.
  • Step 324 If the number of color points of the captured video frame is less than a predetermined threshold, continue to capture the video frame. If the number of times the video frame is captured is greater than the predetermined number of times, the video frame is stopped, and the captured video frame is colored. The video frame with the most number of points is used as a valid video frame.
  • the color point means that the r component, the g component, and the b component of the pixel in the video frame satisfy the r component, and the absolute value of the difference between the g component and the b component exceeds 50, that is, satisfies max(
  • max is a function that takes the maximum value from
  • the minimum number of color points N of the color frame can be given. If the number of color points of the captured video frame is greater than N, then the video frame is considered to be effectively captured, otherwise the data is captured 3 times, and the color point is the most.
  • One frame of video is the final desired video frame.
  • step 303 includes:
  • Step 331 Acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the Message-Digest Algorithm 5 (MD5) algorithm.
  • MD5 Message-Digest Algorithm 5
  • Step 332 Encapsulate the valid video frame into a bmp format thumbnail and store it in a specified cache directory, and define a file name of the bmp format thumbnail as a key name.
  • the captured valid video frames are stored.
  • the length of the file names may be different, which is difficult to manage.
  • the 16-byte key name generated by the record name can be obtained.
  • Each record name corresponds to generate a unique key name, and the length is fixed, which is convenient for management.
  • the captured video frame is bitmap data that can be directly displayed.
  • the name of the file in bmp format is the key name generated by the MD5 algorithm. Store to the specified area.
  • This embodiment also proposes a flowchart of a cover display method for recording a video file based on a PVR set top box. As shown in FIG. 3, the method includes:
  • Step 10 Start.
  • Step 20 Enter the PVR recording management interface. If the thumbnail has been obtained for the recorded video file, the thumbnail is displayed. If the recorded video file has no thumbnail, the default thumbnail is displayed.
  • Step 30 Start a background thread, decode the recorded video file according to the rules, and play the captured video.
  • the frame is 3 times, and the video frame in which the color point is the most is taken as the final effective video frame.
  • Step 40 After the valid video frame is captured, the key name is generated by using the file name according to the MD5 algorithm, and the valid video frame is encapsulated into a thumbnail of the bmp format for storage, and the thumbnail file of the bmp format is named the key name.
  • Step 50 After the valid video frame is captured, the PVR recording management interface is notified in time, and the PVR recording management interface finds that the recorded video file is refreshed on the current display interface.
  • This embodiment also proposes a flowchart of a method for displaying a cover of a recorded file based on a PVR set top box. As shown in FIG. 4, the method includes:
  • Step 22 Start the background video decoder to play the recorded video file, and start capturing the video frame.
  • Step 23 Determine whether the number of color points of the video frame meets the requirement, wherein the requirement is that whether the number of color points is greater than or equal to a predetermined threshold, and if the threshold is greater than or equal to a predetermined threshold, step 26 is performed, and if the threshold is less than the predetermined threshold, step 24 is performed.
  • Step 24 It is determined whether the video frame has been captured three times. If it is not three times, the next position is searched, and after the next frame is started, step 23 is performed. If it is three times, step 25 is performed.
  • Step 25 taking a frame with the largest number of color points in the three frame video frames, and storing the frame as a valid video frame;
  • Step 26 The video frame is a valid video frame and is stored.
  • This embodiment also provides a schematic diagram of a method for displaying a cover of a recorded file based on a PVR set top box, as shown in FIG. 5, which is mainly displayed in the form of a thumbnail.
  • FIG. 5 is mainly displayed in the form of a thumbnail.
  • the file name generated by the MD5 algorithm is displayed, and the user can obtain the content of the recorded video file through the video thumbnail. Old people or illiterate children at home can also quickly access the programs they are going to watch.
  • a functional block diagram of a cover screen display system based on a PVR set top box is also provided. As shown in FIG. 6, the system includes:
  • the detecting and acquiring module 100 is configured to: when detecting that the PVR set-top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file; refer to the relevant in the method embodiment. content.
  • the first cover display control module 200 is configured to display the thumbnail as a cover of the recorded video file when the thumbnail of the recorded video file is detected; Related content in the law embodiment.
  • the second cover display control module 300 is configured to: when there is no thumbnail in the information of the recorded video file, capture the video frame of the recorded video file, and after capturing the valid video frame, The valid video frame is stored in the specified cache directory according to a specific picture format, and the captured valid video frame is displayed as a cover of the recorded video file; reference may be made to related content in the method embodiment.
  • the second cover display control module 300 includes:
  • the preset picture display unit 301 is configured to: when there is no thumbnail in the information of the recorded video file, obtain a preset picture as a cover of the recorded video file; refer to related content in the method embodiment. .
  • the effective video frame capture unit 302 is configured to play the recorded video file in the background after the PVR recording management interface sends the recorded video file to the background thread, and capture the video frame by using the snapshot function according to a preset rule.
  • the video frame that meets the predetermined condition is captured as a valid video frame; reference may be made to related content in the method embodiment.
  • the storage unit 303 is configured to store the valid video frame into a bmp format thumbnail and store it in a specified cache directory; refer to related content in the method embodiment.
  • the thumbnail display unit 304 is configured to display the recorded video file with the thumbnail as a cover when detecting that the recorded video file is still in the PVR recording management interface; Related content.
  • the valid video frame capture unit 302 includes:
  • the recording video file background playing unit 3021 is configured to: after the data of the recorded video file is sent to the background thread in the PVR recording management interface, start a background thread, and start a video player in the background to play the recorded video file. Reference can be made to the relevant content in the method embodiment.
  • the color point number determining unit 3022 is configured to capture a video frame during playback of the video player, and determine whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold; refer to the correlation in the method embodiment. content.
  • the first effective video frame determining unit 3023 is configured to stop capturing the video frame and use the current video frame as the valid video frame when the number of the color points of the captured video frame is greater than or equal to a predetermined threshold. Refer to the relevant content in the method embodiment.
  • the second effective video frame determining unit 3024 is configured to continue to capture the video frame when the number of color points of the captured video frame is less than a predetermined threshold, and stop capturing the video frame when the number of times the video frame is captured is greater than a predetermined number of times
  • the video frame with the largest number of captured color points is used as the valid video frame; reference may be made to related content in the method embodiment.
  • the storage unit 303 includes:
  • the key generating unit 3031 is configured to acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the MD5 algorithm; reference may be made to related content in the method embodiment.
  • the encapsulation and storage unit 3032 is configured to encapsulate the valid video frame into a thumbnail of the bmp format, store it in a specified cache directory, and use the key name as a file name of the thumbnail of the bmp format; Related content in the example.
  • the color point refers to a pixel point where the r component, the g component, and the b component of the pixel in the video frame satisfy max(
  • )>50 refers to the method embodiment.
  • the present embodiment provides a recording file cover display system based on a PVR set-top box, which uses a thumbnail of a video frame in a recorded video file as a cover display of the recorded video file, so that the user can obtain differently conveniently and quickly.
  • the difference in recording video files allows you to quickly get the recorded video files you want to play.
  • An embodiment further provides a computer readable storage medium storing computer executable instructions for performing the above method.
  • FIG. 10 is a schematic diagram showing the hardware structure of a display device for recording a video file of a set top box according to an embodiment.
  • the display device for recording a video file of the set top box includes: one or more processors 1010 and a memory 1020.
  • One processor 1010 is taken as an example in FIG.
  • the display device for recording a video file of the set top box may further include: an input device 1030 and an output device 1040.
  • the processor 1010, the memory 1020, the input device 1030, and the output device 1040 in the display device of the set top box recording the video file may be connected by a bus or other means, and the bus connection is taken as an example in FIG.
  • the input device 1030 can receive input numeric or character information
  • the output device 1040 can include a display device such as a display screen.
  • the memory 1020 is a computer readable storage medium that can be used to store software programs, computer executable programs, and modules.
  • the processor 1010 performs various functional applications and data processing by executing software programs, instructions, and modules stored in the memory 1020 to implement any of the above-described embodiments.
  • the memory 1020 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; and the storage data area may store the use of the display device according to the recorded video file of the set top box. Data, etc.
  • the memory may include volatile memory such as random access memory (RAM), and may also include non-volatile memory such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device.
  • Memory 1020 can be a non-transitory computer storage medium or a transitory computer storage medium.
  • the non-transitory computer storage medium such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device.
  • memory 1020 can optionally include memory remotely located relative to processor 1010 that can be connected to the display device of the set top box for recording video files over a network. Examples of the above networks may include the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
  • the input device 1030 can be configured to receive input numeric or character information, and to generate key signal inputs related to user settings and function control of a display device of the set video cassette of the set top box.
  • the output device 1040 can include a display device such as a display screen.
  • the display device for recording a video file of the set top box of the present embodiment may further include a communication device 1050 for transmitting and/or receiving information through the communication network.
  • a person skilled in the art can understand that all or part of the process of implementing the above embodiment method can be completed by executing related hardware by a computer program, and the program can be stored in a non-transitory computer readable storage medium.
  • the program when executed, may include the flow of an embodiment of the method as described above, wherein the non-transitory computer readable storage medium may be a magnetic disk, an optical disk, a read only memory (ROM), or a random access memory (RAM). Wait.
  • the present disclosure provides a method and system for displaying a recorded video file of a set top box.
  • the thumbnail of the video frame in the recorded file is displayed as a cover of the recorded file, so that the user can conveniently and quickly obtain the difference of different recorded video files, thereby Quickly get the recorded video file you want to play.

Abstract

A method and system for displaying a video file recorded on a set-top box. The method comprises: upon detecting that a PVR recording control interface is initiated on the PVR set-top box, acquiring a recorded video file, and determining whether the recorded video file has a thumbnail image; if so, displaying the thumbnail image as a video thumbnail of the recorded video file; otherwise, obtaining a video frame of the recorded video file, and after a valid video frame is obtained, storing, according to a specific image format, the valid video frame into a specified folder, and displaying the obtained valid video frame as the video thumbnail of the recorded video file.

Description

机顶盒的录制视频文件的显示方法及系统Display method and system for recording video file of set top box 技术领域Technical field
本公开涉及机顶盒技术领域,例如涉及一种机顶盒的录制视频文件的显示方法及系统。The present disclosure relates to the field of set top box technologies, for example, to a display method and system for recording video files of a set top box.
背景技术Background technique
数字电视以节目丰富,功能多样化方式深受人们的喜爱,吸引了越来越多的用户群。而对于看电视的用户而言,如此丰富的数字节目,目接不暇,为了日后回看,需要对节目进行视频录制。Digital TV is popular among people for its rich programs and diversified functions, attracting more and more users. For users who watch TV, such a rich digital program is not overwhelming. In order to look back later, video recording of the program is required.
个人视频录制(Personal Video Record,PVR)可以帮助用户把当前正在播放的用户喜欢看的节目给录制下来,也可以对将要播放的某一时间段的节目进行预录。Personal Video Record (PVR) can help the user to record the program that the user who is currently playing likes to watch, or pre-record the program for a certain period of time to be played.
一般来说,我们是通过录制时的时间+录制的事件名给录制的文件命名,这样方便我们检索录制文件,并在机顶盒的PVR录制管理界面选中文件进行播放。传统PVR录制管理界面是通过文件列表的方式呈现录制文件信息。如图1所示,为相关技术中打开录制视频文件时的显示方式,主要是以文件列表的形式显示。如图1中选定的中央一台的节目,录制时间为20160801,节目名为152122,还显示有频道名称,录制的日期以及视频的时长等信息。In general, we name the recorded file by the time of recording + the name of the recorded event, so that we can retrieve the recorded file and select the file to play in the PVR recording management interface of the set-top box. The traditional PVR recording management interface presents the recorded file information through a file list. As shown in FIG. 1, the display mode when the video file is recorded in the related art is mainly displayed in the form of a file list. As shown in Figure 1, the central one program has a recording time of 20160801 and a program name of 152122. It also displays the channel name, the date of recording, and the duration of the video.
传统PVR录制管理界面的文件列表呈现形式过于简单和单一,存在以下问题:界面只有录制时间和录制事件不容易区别不同视频之间的差异,时间过长后,用户容易忘记录制节目的内容,而且若有老人或小孩无法识别录制的事件名,从而无法获取到自己需要查看的录制节目,为用户带来了极大的不便。The file list presentation format of the traditional PVR recording management interface is too simple and single. The following problems exist: only the recording time and the recording event are not easy to distinguish the difference between different videos. After the time is too long, the user easily forgets to record the content of the program, and If an old person or a child cannot recognize the recorded event name and thus cannot obtain the recorded program that he or she needs to view, it brings great inconvenience to the user.
发明内容Summary of the invention
本公开提供一种机顶盒的录制视频文件的显示方法及系统,旨在解决相关技术中现有录制管理界面以文件列表形式进行显示,难以区别不同视频之间的差异,为用户带来了极大的不便的技术问题。The present disclosure provides a method and system for displaying a recorded video file of a set top box, which aims to solve the problem that the existing recording management interface in the related art is displayed in the form of a file list, and it is difficult to distinguish the difference between different videos, which brings great The inconvenience of the technical problem.
本公开提供一种机顶盒的录制视频文件的显示方法,包括:The present disclosure provides a method for displaying a recorded video file of a set top box, including:
在检测到个人视频录制PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,并判断所述录制视频文件的信息中是否有缩略图; When detecting that the personal video recording PVR set top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file;
在检测到录制视频文件的信息中已经有缩略图时,则将所述缩略图作为所述录制视频文件的封面进行显示;When there is already a thumbnail in the information of the recorded video file, the thumbnail is displayed as the cover of the recorded video file;
在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示。When there is no thumbnail in the information of the recorded video file, the video frame of the recorded video file is captured, and after the valid video frame is captured, the valid video frame is classified according to a specific image format. The storage is stored in the specified cache directory, and the captured valid video frame is displayed as the cover of the recorded video file.
可选地,所述在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示的步骤包括:Optionally, when there is no thumbnail in the information of the recorded video file, the video frame of the recorded video file is captured, and after the valid video frame is captured, the effective video is captured. The step of storing the frame in the specified cache format to the specified cache directory and displaying the captured valid video frame as the cover of the recorded video file includes:
在检测到所述录制视频文件的信息中没有缩略图时,获取预设的图片作为所述录制视频文件的封面进行显示;When it is detected that there is no thumbnail in the information of the recorded video file, acquiring a preset picture as a cover of the recorded video file for display;
当所述PVR录制管理界面将所述录制视频文件发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧;After the PVR recording management interface sends the recorded video file to the background thread, the recorded video file is played in the background, and the video frame is captured by the snapshot function according to a preset rule, and the video frame that meets the predetermined condition is captured as a video frame. Valid video frame;
将所述有效视频帧封装成位图bmp格式的缩略图后存储至指定缓存目录;Encapsulating the valid video frame into a thumbnail of the bitmap bmp format and storing it in a specified cache directory;
在检测到所述PVR录制管理界面中仍有所述录制视频文件时,则将所述录制视频文件以所述缩略图作为封面进行显示。When it is detected that the recorded video file is still in the PVR recording management interface, the recorded video file is displayed with the thumbnail as a cover.
可选地,所述在所述PVR录制管理界面获取所述录制视频文件的数据发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧的步骤包括:Optionally, after the data of the recorded video file is acquired by the PVR recording management interface and sent to the background thread, the recorded video file is played in the background, and the video frame is captured by the snapshot function according to a preset rule. The steps of taking a video frame that meets a predetermined condition as a valid video frame include:
在所述PVR录制管理界面将所述录制视频文件的数据发送至所述后台线程后,启动后台线程,在后台启动视频播放器以播放所述录制视频文件;After the data of the recorded video file is sent to the background thread in the PVR recording management interface, the background thread is started, and the video player is started in the background to play the recorded video file;
在所述视频播放器播放过程中抓取视频帧,并判断抓取的视频帧的彩色点个数是否大于等于预定阈值;Grasing a video frame during playback of the video player, and determining whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold;
当抓取的视频帧的彩色点个数大于等于预定阈值时,则停止抓取视频帧,将当前视频帧作为所述有效视频帧;在抓取的视频帧的彩色点个数小于预定阈值时,则继续抓取视频帧,当抓取视频帧的次数大于预定次数时停止抓取视频帧,将抓取的彩色点个数最多的视频帧作为所述有效视频帧,所述彩色点是指所述视频帧中满足预设条件的像素点,所述预设条件为所述像素点的r分量、g分量和b分量中的两个分量之间的差值的绝对值最大值大于50的像素点。 When the number of color points of the captured video frame is greater than or equal to a predetermined threshold, the video frame is stopped to be captured, and the current video frame is used as the effective video frame; when the number of color points of the captured video frame is less than a predetermined threshold Then, the video frame is continuously captured, and when the number of times the video frame is captured is greater than the predetermined number of times, the video frame is stopped, and the video frame with the largest number of captured color points is used as the effective video frame, and the color point refers to a pixel point in the video frame that satisfies a preset condition, where the absolute value of the absolute value of the difference between the r component, the g component, and the b component of the pixel is greater than 50 pixel.
可选地,所述将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录的步骤包括:Optionally, the step of storing the valid video frame into a bmp format thumbnail and storing the file in a specified cache directory comprises:
获取所述有效视频帧对应的录制视频文件的文件名,根据消息摘要算法第五版MD5算法对所述文件名计算后生成密钥名称;Obtaining a file name of the recorded video file corresponding to the valid video frame, and generating a key name after calculating the file name according to the message digest algorithm fifth edition MD5 algorithm;
将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将所述密钥名作为该bmp格式的缩略图的文件名。The valid video frame is encapsulated into a thumbnail of the bmp format and stored in a specified cache directory, and the key name is used as a file name of the thumbnail of the bmp format.
本公开还提供一种机顶盒的录制视频文件的显示系统,包括:The present disclosure also provides a display system for recording video files of a set top box, including:
检测与获取模块,设置为在检测到个人视频录制PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,并判断所述录制视频文件的信息中是否有缩略图;The detecting and acquiring module is configured to: when detecting the personal video recording PVR set top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file;
第一封面显示控制模块,设置为在检测到录制视频文件的信息中已经有缩略图时,则将所述缩略图作为所述录制视频文件的封面进行显示;a first cover display control module configured to display the thumbnail as a cover of the recorded video file when a thumbnail has been detected in the information of the recorded video file;
第二封面显示控制模块,设置为在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示。a second cover display control module, configured to: when there is no thumbnail in the information of the recorded video file, capture the video frame of the recorded video file, and after capturing the valid video frame, The valid video frame is stored in a specified cache directory according to a specific picture format, and the captured valid video frame is displayed as a cover of the recorded video file.
可选地,所述第二封面显示控制模块包括:Optionally, the second cover display control module includes:
预设图片显示单元,设置为在检测到所述录制视频文件的信息中没有缩略图时,获取预设的图片作为所述录制视频文件的封面进行显示;a preset picture display unit configured to: when there is no thumbnail in the information of the recorded video file, obtain a preset picture as a cover of the recorded video file;
有效视频帧抓取单元,设置为当所述PVR录制管理界面将所述录制视频文件发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧;The effective video frame capture unit is configured to play the recorded video file in the background after the PVR recording management interface sends the recorded video file to the background thread, and capture the video frame by using the snapshot function according to a preset rule. Grab a video frame that meets the predetermined condition as a valid video frame;
存储单元,设置为将所述有效视频帧封装成位图bmp格式的缩略图后存储至指定缓存目录;a storage unit, configured to encapsulate the valid video frame into a bitmap of a bitmap bmp format and store the image in a specified cache directory;
缩略图显示单元,设置为在检测到所述PVR录制管理界面中仍有所述录制视频文件时,则将所述录制视频文件以所述缩略图作为封面进行显示。And a thumbnail display unit configured to display the recorded video file with the thumbnail as a cover when the recorded video file is still detected in the PVR recording management interface.
可选地,所述有效视频帧抓取单元包括:Optionally, the valid video frame capture unit includes:
录制视频文件后台播放单元,设置为在所述PVR录制管理界面将所述录制视频文件的数据发送至所述后台线程后,启动后台线程,在后台启动视频播放器以播放所述录制视频文件;Recording a video file background playing unit, configured to: after the data of the recorded video file is sent to the background thread in the PVR recording management interface, start a background thread, and start a video player in the background to play the recorded video file;
彩色点个数判断单元,设置为在所述视频播放器播放过程中抓取视频帧, 并判断抓取的视频帧的彩色点个数是否大于等于预定阈值;a color point number determining unit configured to capture a video frame during playback of the video player, And determining whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold;
第一有效视频帧判定单元,设置为当抓取的视频帧的彩色点个数大于等于预定阈值时,则停止抓取视频帧,将当前视频帧作为所述有效视频帧;The first valid video frame determining unit is configured to stop capturing the video frame and use the current video frame as the effective video frame when the number of the color points of the captured video frame is greater than or equal to a predetermined threshold;
第二有效视频帧判定单元,设置为在抓取的视频帧的彩色点个数小于预定阈值时,则继续抓取视频帧,当抓取视频帧的次数大于预定次数时停止抓取视频帧,将抓取的彩色点个数最多的视频帧作为所述有效视频帧,其中,所述彩色点是指所述视频帧中满足预设条件的像素点,所述预设条件为所述像素点的r分量、g分量和b分量中的两个分量之间的差值的绝对值最大值大于50的像素点。The second effective video frame determining unit is configured to continue to capture the video frame when the number of color points of the captured video frame is less than a predetermined threshold, and stop capturing the video frame when the number of times the video frame is captured is greater than a predetermined number of times. The video frame with the largest number of captured color points is used as the effective video frame, wherein the color point refers to a pixel point in the video frame that satisfies a preset condition, and the preset condition is the pixel point. The absolute value of the difference between the two components of the r component, the g component, and the b component has a maximum value greater than 50 pixel points.
可选地,所述将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录的步骤包括:Optionally, the step of storing the valid video frame into a bmp format thumbnail and storing the file in a specified cache directory comprises:
密钥生成单元,设置为获取所述有效视频帧对应的录制视频文件的文件名,根据消息摘要算法第五版MD5算法对所述文件名计算后生成密钥名称;a key generating unit, configured to acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the message digest algorithm fifth version MD5 algorithm;
封装与存储单元,设置为将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将所述密钥名作为该bmp格式的缩略图的文件名。The encapsulation and storage unit is configured to encapsulate the valid video frame into a bmp format thumbnail and store it in a specified cache directory, and use the key name as a file name of the bmp format thumbnail.
本公开还提供一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行上述方法。The present disclosure also provides a computer readable storage medium storing computer executable instructions for performing the above method.
本公开还提供一种机顶盒的录制视频文件的显示设备,该机顶盒的录制视频文件的显示设备包括一个或多个处理器、存储器以及一个或多个程序,所述一个或多个程序存储在存储器中,当被一个或多个处理器执行时,执行上述方法。The present disclosure also provides a display device for recording a video file of a set top box, the display device of the set top box recording the video file comprising one or more processors, a memory and one or more programs, the one or more programs being stored in the memory The above method is performed when executed by one or more processors.
本公开还提供了一种计算机程序产品,所述计算机程序产品包括存储在非暂态计算机可读存储介质上的计算机程序,所述计算机程序包括程序指令,当所述程序指令被计算机执行时,使所述计算机执行上述任意一种方法。The present disclosure also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions, when the program instructions are executed by a computer, Having the computer perform any of the methods described above.
本公开提供了一种机顶盒的录制视频文件的显示方法及系统,以录制文件中的视频帧的缩略图作为录制文件封面显示,使用户可以方便、快捷的获取不同的录制视频文件的差异,从而快速获取自己想要的录制视频文件进行播放。The present disclosure provides a method and system for displaying a recorded video file of a set top box. The thumbnail of the video frame in the recorded file is displayed as a cover of the recorded file, so that the user can conveniently and quickly obtain the difference of different recorded video files, thereby Quickly get the recorded video file you want to play.
附图说明DRAWINGS
图1为相关技术中以文件列表方式显示录制视频文件的示意图。FIG. 1 is a schematic diagram showing a recorded video file in a file list manner in the related art.
图2为一实施例的一种基于PVR机顶盒的录制文件封面显示方法的流程图。2 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
图3为一实施例的一种基于PVR机顶盒的录制文件封面显示方法的流程图。 3 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
图4为一实施例的一种基于PVR机顶盒的录制文件封面显示方法的流程图。4 is a flow chart of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
图5为一实施例的一种基于PVR机顶盒的录制文件封面显示方法的示意图。FIG. 5 is a schematic diagram of a method for displaying a cover of a recorded file based on a PVR set top box according to an embodiment.
图6为一实施例的一种基于PVR机顶盒的录制文件封面显示系统的功能原理框图。6 is a functional block diagram of a recording file cover display system based on a PVR set top box according to an embodiment.
图7为一实施例提供的一种机顶盒的录制视频文件的显示系统的结构示意图。FIG. 7 is a schematic structural diagram of a display system for recording a video file of a set top box according to an embodiment.
图8为一实施例提供的另一种机顶盒的录制视频文件的显示系统的结构示意图。FIG. 8 is a schematic structural diagram of a display system for recording a video file of another set top box according to an embodiment.
图9为一实施例提供的另一种机顶盒的录制视频文件的显示系统的结构示意图。FIG. 9 is a schematic structural diagram of a display system for recording a video file of another set top box according to an embodiment.
图10为一实施例提供的一种机顶盒的录制视频文件的显示设备的硬件结构示意图。FIG. 10 is a schematic diagram showing the hardware structure of a display device for recording a video file of a set top box according to an embodiment.
具体实施方式detailed description
本实施例提供了一种基于PVR机顶盒的录制视频文件的封面显示方法的的流程图,如图2所示,方法包括:This embodiment provides a flowchart of a cover display method for recording a video file based on a PVR set top box. As shown in FIG. 2, the method includes:
步骤100、在检测到PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,判断录制视频文件的信息中是否有缩略图,当有缩略图时,则执行步骤200,当没有缩略图时,则执行步骤300。Step 100: When detecting that the PVR set-top box enters the PVR recording management interface, obtain information of the recorded video file, determine whether there is a thumbnail in the information of the recorded video file, and when there is a thumbnail, perform step 200, when there is no thumbnail Then, step 300 is performed.
进入PVR录制管理界面,也可称作PVR录制资源管理场景菜单,以缩略图形式的界面风格显示录制视频文件,如果录制视频文件已经具有属于自己的缩略图,显示缩略图;如果没有缩略图,先用默认的缩略图图片显示。其中,缩略图一般用于电脑桌面或者网页等场景,可以是原图片经过压缩方式处理的图片。因为缩略图体积小,加载速度非常快,可以实现快速预览。PVR录制的本质是在播放节目时,把节目视频数据按一定格式,例如MPEG2或MPEG4等格式存储起来。在回放时,调用专门的视频播放器进行解码播放。Enter the PVR recording management interface, also known as the PVR recording resource management scene menu, display the recorded video file in the interface style of the thumbnail form, if the recorded video file already has its own thumbnail, display the thumbnail; if there is no thumbnail, First display with the default thumbnail image. Among them, the thumbnail is generally used for a scene such as a computer desktop or a webpage, and may be a picture processed by the original image in a compressed manner. Because the thumbnails are small and load fast, a quick preview is possible. The essence of PVR recording is to store program video data in a format such as MPEG2 or MPEG4 when playing a program. During playback, a dedicated video player is called for decoding playback.
步骤200、PVR录制管理界面将缩略图作为录制视频文件的封面进行显示。Step 200: The PVR recording management interface displays the thumbnail as the cover of the recorded video file.
如果录制视频文件已经有属于自己的缩略图,那么在PVR录制管理界面显 示缩略图。If the recorded video file already has its own thumbnail, then the PVR recording management interface is displayed. Show thumbnails.
步骤300、PVR录制管理界面对录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,按照特定的图片格式存储到指定缓存目录,并将抓取到的有效视频帧作为录制视频文件的封面进行显示。Step 300: The PVR recording management interface captures the video frame of the recorded video file, and after capturing the valid video frame, stores the video frame in the specified cache format according to a specific image format, and uses the captured valid video frame as the recorded video. The cover of the file is displayed.
在一段视频中可能会有黑帧或者灰帧,而为了提取信息饱满的视频帧用作缩略图,则剔除掉黑帧或者灰帧,并且尽可能抓取到色彩丰富的视频帧。There may be black frames or gray frames in a video, and in order to extract a full-filled video frame as a thumbnail, black frames or gray frames are eliminated, and colorful video frames are captured as much as possible.
某一帧视频数据,也即视频帧,是由多个像素点组成,像素点可能是黑白色,灰色或者是彩色,如果要提取信息丰富的视频帧,这帧视频数据包含的彩色的像素点越多越好。机顶盒在后台解码播放视频时,可以通过快照功能抓取视频帧,为减少抓到黑帧或者灰帧的视频帧的可能性,播放时可以通过搜索到不同位置去抓取视频帧。A certain frame of video data, that is, a video frame, is composed of a plurality of pixels, which may be black and white, gray or color. If a rich video frame is to be extracted, the color data pixels of the frame of the video data are included. The more the better. When the set-top box decodes and plays the video in the background, the video frame can be captured by the snapshot function. In order to reduce the possibility of capturing the video frame of the black frame or the gray frame, the video frame can be captured by searching for different positions during playback.
可选地,步骤300包括:Optionally, step 300 includes:
步骤301、在检测到录制视频文件没有缩略图时,获取预设的图片作为录制视频文件的封面进行显示。Step 301: When it is detected that the recorded video file has no thumbnail, the preset picture is obtained as a cover of the recorded video file for display.
步骤302、PVR录制管理界面将录制视频文件发送至后台线程后,在后台播放录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧。Step 302: The PVR recording management interface sends the recorded video file to the background thread, plays the recorded video file in the background, captures the video frame through the snapshot function according to a preset rule, and captures the video frame that meets the predetermined condition as the effective video frame.
步骤303、将有效视频帧封装成位图(Bitmap,bmp)格式的缩略图后存储至指定缓存目录。Step 303: Encapsulate the valid video frame into a bitmap of a bitmap (Bmp) format and store it in a specified cache directory.
步骤304、当检测到PVR录制管理界面中仍具有录制视频文件,则将录制视频文件以所述缩略图作为封面进行显示。Step 304: When it is detected that the PVR recording management interface still has a recorded video file, the recorded video file is displayed with the thumbnail as a cover.
启动后台线程后,PVR录制管理界面把当前路径,当前目录文件夹拥有的所有录制文件名称,当前显示界面可以显示的录制文件个数,当前显示界面为第几页,当前用户的操作方式是往上翻页还是往下翻页等信息数据传输给后台线程。After the background thread is started, the PVR recording management interface takes the current path, the name of all the recording files owned by the current directory folder, and the number of recording files that can be displayed on the current display interface. The current display interface is the first page, and the current user operation mode is The information data such as page up or page down is transmitted to the background thread.
后台线程启动后,先启动视频播放器(此时播放器在后台运行,关闭了视频输出,因此不影响用户在PVR录制管理界面中的操作),然后根据录制文件名称在后台播放,并抓取此录制文件的有效视频帧。后台解码播放时,先判断此录 制文件是否已经有对应缩略图,如果已经有缩略图,以该缩略图作为封面进行显示;如果没有缩略图,那么后台播放此录制文件。在后台播放此录制文件时,根据抓取视频帧方法,抓取到有效视频帧。After the background thread starts, the video player is started first (the player runs in the background, the video output is turned off, so the user does not affect the operation in the PVR recording management interface), and then plays in the background according to the name of the recorded file, and crawls A valid video frame for this recording. When decoding in the background, first judge this recording Whether the file already has a corresponding thumbnail, if there is already a thumbnail, the thumbnail is used as a cover; if there is no thumbnail, the recording is played in the background. When playing this recording file in the background, a valid video frame is captured according to the method of capturing a video frame.
后台抓取视频帧时,可以有优先级顺序,先抓取当前显示界面的录制文件的视频帧,再抓取当前显示界面的前一页或后一页的录制文件的视频帧,最后再按照目录的文件夹顺序抓取其它文件夹录制文件的视频帧。When capturing video frames in the background, there may be a priority order, first grab the video frame of the recording file of the current display interface, and then grab the video frame of the recording file of the previous or next page of the current display interface, and finally follow The folder order of the directory captures the video frames of the other folder recording files.
后台在抓取视频帧时,用户可以在PVR录制管理界面有按键操作,比如翻页移动到上一页或者下一页,当有翻页动作时,PVR录制管理界面会及时把当前显示界面属于第几页,当前页的第一个录制文件的索引号及时丢给后台线程。后台线程及时中断当前操作,及时跟踪当前显示界面,以解析当前显示界面的录制文件视频帧。When capturing video frames in the background, the user can have key operations on the PVR recording management interface, such as turning pages to the previous page or the next page. When there is a page turning action, the PVR recording management interface will promptly display the current display interface. On the first few pages, the index number of the first recording file of the current page is thrown to the background thread in time. The background thread interrupts the current operation in time, and timely tracks the current display interface to parse the video frame of the recording file of the current display interface.
后台线程在抓取到录制文件的有效视频帧后,要及时按照bmp格式存储到指定的缓存目录,并及时通知PVR录制管理界面进行刷新,当PVR录制管理界面接到刷新消息后,判断新抓到视频帧的录制文件是否在当前屏幕,如果存在,那么到指定缓存目录获取此录制文件的缩略图并刷新PVR录制管理界面。After the background thread captures the valid video frame of the recorded file, it must be stored in the specified cache directory according to the bmp format, and promptly notify the PVR recording management interface to refresh. When the PVR recording management interface receives the refresh message, it judges the new capture. Whether the recording file to the video frame is on the current screen, if it exists, then obtain the thumbnail of the recording file and refresh the PVR recording management interface to the specified cache directory.
在步骤300之后还可以包括:在PVR录制管理界面退出时,需要给后台线程发退出消息,后台线程停止解码录制视频文件,并关闭后台视频播放器,最后销毁后台线程。After the step 300, the method may further include: when the PVR recording management interface exits, the background thread needs to send an exit message, the background thread stops decoding the recorded video file, closes the background video player, and finally destroys the background thread.
可选地,步骤302包括:Optionally, step 302 includes:
步骤321、PVR录制管理界面将录制视频文件数据发送至后台线程,后台线程启动后,在后台启动视频播放器,视频播放器在后台播放录制视频文件。Step 321: The PVR recording management interface sends the recorded video file data to the background thread. After the background thread is started, the video player is started in the background, and the video player plays the recorded video file in the background.
步骤322、在视频播放器播放过程中抓取视频帧,并判断抓取的视频帧的彩色点个数是否大于等于预定阈值。Step 322: Grab a video frame during playback of the video player, and determine whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold.
步骤323、若抓取的视频帧的彩色点个数大于等于预定阈值,则停止抓取视频帧,将当前视频帧为有效视频帧。Step 323: If the number of color points of the captured video frame is greater than or equal to a predetermined threshold, stop capturing the video frame and set the current video frame as a valid video frame.
步骤324、若抓取的视频帧的彩色点个数小于预定阈值,则继续抓取视频帧,若抓取视频帧的次数大于预定次数,停止抓取视频帧,将抓取的视频帧中彩色点个数最多的视频帧作为有效视频帧。 Step 324: If the number of color points of the captured video frame is less than a predetermined threshold, continue to capture the video frame. If the number of times the video frame is captured is greater than the predetermined number of times, the video frame is stopped, and the captured video frame is colored. The video frame with the most number of points is used as a valid video frame.
其中,彩色点是指视频帧中的像素点的r分量、g分量、b分量满足r分量、g分量和b分量之间的差值的绝对值最大值超越50,即满足max(|r-g|,|r-b|,|b-g|)>50的像素点,其中,max为从|r-g|、|r-b|、和|b-g|中取最大值的函数。为了快速抓取视频帧,可以给定彩色帧最小彩色点数N,如果抓取的视频帧彩色点数大于N,那么认为此视频帧为有效抓取,否则抓取3次,取其中彩色点最多的一帧视频为最终需要的视频帧。Wherein, the color point means that the r component, the g component, and the b component of the pixel in the video frame satisfy the r component, and the absolute value of the difference between the g component and the b component exceeds 50, that is, satisfies max(|rg| , |rb|,|bg|)>50 pixels, where max is a function that takes the maximum value from |rg|, |rb|, and |bg|. In order to quickly capture the video frame, the minimum number of color points N of the color frame can be given. If the number of color points of the captured video frame is greater than N, then the video frame is considered to be effectively captured, otherwise the data is captured 3 times, and the color point is the most. One frame of video is the final desired video frame.
可选地,步骤303包括:Optionally, step 303 includes:
步骤331、获取有效视频帧对应的录制视频文件的文件名,根据消息摘要算法第五版(Message-Digest Algorithm 5,MD5)算法对文件名计算后生成密钥名称。Step 331: Acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the Message-Digest Algorithm 5 (MD5) algorithm.
步骤332、将有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将bmp格式的缩略图的文件名定义为密钥名称。Step 332: Encapsulate the valid video frame into a bmp format thumbnail and store it in a specified cache directory, and define a file name of the bmp format thumbnail as a key name.
因为抓取有效视频帧是需要一定时间的,所以如果抓取到有效视频帧后,对于同一个录制视频文件,为了避免以后重复去抓取浪费时间,影响界面的流畅度和友好交互,可以把抓取的有效视频帧存储起来。Because it takes a certain time to capture a valid video frame, if you capture a valid video frame, you can put the same recorded video file in order to avoid wasting time and affecting the smoothness and friendly interaction of the interface. The captured valid video frames are stored.
因为不同的录制文件的文件名是不同的,文件名称的长度也可能是不同的,这样不易管理。可以根据MD5算法得到此录制文件名生成的16个字节的密钥名称,每一个录制文件名称对应生成唯一的一个密钥名称,并且长度是固定的,这样比较方便管理。Because the file names of different recording files are different, the length of the file names may be different, which is difficult to manage. According to the MD5 algorithm, the 16-byte key name generated by the record name can be obtained. Each record name corresponds to generate a unique key name, and the length is fixed, which is convenient for management.
抓取的视频帧是可以直接显示的位图数据,我们可以把抓取的视频帧按照bmp格式封装存储起来,bmp格式的文件的名称就是此录制文件名按照MD5算法生成的密钥名,然后存储到指定区域。The captured video frame is bitmap data that can be directly displayed. We can store the captured video frame in bmp format. The name of the file in bmp format is the key name generated by the MD5 algorithm. Store to the specified area.
本实施例还提出了一种基于PVR机顶盒的录制视频文件的封面显示方法的流程图,图3所示,方法包括:This embodiment also proposes a flowchart of a cover display method for recording a video file based on a PVR set top box. As shown in FIG. 3, the method includes:
步骤10、开始。 Step 10. Start.
步骤20、进入PVR录制管理界面,如果对录制视频文件已经获取过缩略图,那么显示上述缩略图,如果录制视频文件没有缩略图,用显示默认的缩略图。Step 20: Enter the PVR recording management interface. If the thumbnail has been obtained for the recorded video file, the thumbnail is displayed. If the recorded video file has no thumbnail, the default thumbnail is displayed.
步骤30、启动后台线程,按照规则对录制视频文件进行解码播放抓取视频 帧3次,取其中彩色点最多的视频帧为最终有效视频帧。Step 30: Start a background thread, decode the recorded video file according to the rules, and play the captured video. The frame is 3 times, and the video frame in which the color point is the most is taken as the final effective video frame.
步骤40、在抓取到有效视频帧后,按照MD5算法利用文件名生成密钥名称,把有效视频帧封装成bmp格式的缩略图进行存储,bmp格式的缩略图文件名为密钥名称。Step 40: After the valid video frame is captured, the key name is generated by using the file name according to the MD5 algorithm, and the valid video frame is encapsulated into a thumbnail of the bmp format for storage, and the thumbnail file of the bmp format is named the key name.
步骤50、在抓取到有效视频帧后,及时通知PVR录制管理界面,PVR录制管理界面发现此录制视频文件在当前显示界面,则进行刷新。Step 50: After the valid video frame is captured, the PVR recording management interface is notified in time, and the PVR recording management interface finds that the recorded video file is refreshed on the current display interface.
本实施例还提出了一种基于PVR机顶盒的录制文件封面显示方法的流程图,图4所示,方法包括:This embodiment also proposes a flowchart of a method for displaying a cover of a recorded file based on a PVR set top box. As shown in FIG. 4, the method includes:
步骤21、开始。 Step 21, start.
步骤22、启动后台视频解码器播放录制视频文件,开始抓取视频帧。Step 22: Start the background video decoder to play the recorded video file, and start capturing the video frame.
步骤23、判断此视频帧彩色点数是否满足要求,其中满足要求是指彩色点个数是否大于等于预定阈值,大于等于预定阈值,则执行步骤26,小于预定阈值,则执行步骤24。Step 23: Determine whether the number of color points of the video frame meets the requirement, wherein the requirement is that whether the number of color points is greater than or equal to a predetermined threshold, and if the threshold is greater than or equal to a predetermined threshold, step 26 is performed, and if the threshold is less than the predetermined threshold, step 24 is performed.
步骤24、判断是否已抓取视频帧三次,如果没满三次,搜索到下一个位置,开始抓取下一帧后,执行步骤23,若已满三次,则执行步骤25。Step 24: It is determined whether the video frame has been captured three times. If it is not three times, the next position is searched, and after the next frame is started, step 23 is performed. If it is three times, step 25 is performed.
步骤25、取三帧视频帧中彩色点数最多的帧,当作有效视频帧进行存储;Step 25: taking a frame with the largest number of color points in the three frame video frames, and storing the frame as a valid video frame;
步骤26、此视频帧为有效视频帧,进行存储。Step 26: The video frame is a valid video frame and is stored.
本实施例还提供了一种基于PVR机顶盒的录制文件封面显示方法的示意图,如图5所示,主要是以缩略图的形式显示。如图5中选定节目,只显示利用MD5算法生成的文件名称,用户可通过视频略图获取录制视频文件的内容。在家有老人或不识字的小孩也可无障碍的快速获取自己将要观看的节目。This embodiment also provides a schematic diagram of a method for displaying a cover of a recorded file based on a PVR set top box, as shown in FIG. 5, which is mainly displayed in the form of a thumbnail. As shown in Figure 5, only the file name generated by the MD5 algorithm is displayed, and the user can obtain the content of the recorded video file through the video thumbnail. Old people or illiterate children at home can also quickly access the programs they are going to watch.
本实施例中还提供了一种基于PVR机顶盒的录制文件封面显示系统的功能原理框图,如图6所示,系统包括:In this embodiment, a functional block diagram of a cover screen display system based on a PVR set top box is also provided. As shown in FIG. 6, the system includes:
检测与获取模块100,设置为在检测到PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,并判断所述录制视频文件的信息中是否有缩略图;可参考方法实施例中的相关内容。The detecting and acquiring module 100 is configured to: when detecting that the PVR set-top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file; refer to the relevant in the method embodiment. content.
第一封面显示控制模块200,设置为在检测到录制视频文件的信息中已经有缩略图时,则将所述缩略图作为所述录制视频文件的封面进行显示;可参考方 法实施例中的相关内容。The first cover display control module 200 is configured to display the thumbnail as a cover of the recorded video file when the thumbnail of the recorded video file is detected; Related content in the law embodiment.
第二封面显示控制模块300,设置为在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示;可参考方法实施例中的相关内容。The second cover display control module 300 is configured to: when there is no thumbnail in the information of the recorded video file, capture the video frame of the recorded video file, and after capturing the valid video frame, The valid video frame is stored in the specified cache directory according to a specific picture format, and the captured valid video frame is displayed as a cover of the recorded video file; reference may be made to related content in the method embodiment.
可选地,参考图7,其中,所述第二封面显示控制模块300包括:Optionally, referring to FIG. 7, the second cover display control module 300 includes:
预设图片显示单元301,设置为在检测到所述录制视频文件的信息中没有缩略图时,获取预设的图片作为所述录制视频文件的封面进行显示;可参考方法实施例中的相关内容。The preset picture display unit 301 is configured to: when there is no thumbnail in the information of the recorded video file, obtain a preset picture as a cover of the recorded video file; refer to related content in the method embodiment. .
有效视频帧抓取单元302,设置为当所述PVR录制管理界面将所述录制视频文件发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧;可参考方法实施例中的相关内容。The effective video frame capture unit 302 is configured to play the recorded video file in the background after the PVR recording management interface sends the recorded video file to the background thread, and capture the video frame by using the snapshot function according to a preset rule. The video frame that meets the predetermined condition is captured as a valid video frame; reference may be made to related content in the method embodiment.
存储单元303,设置为将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录;可参考方法实施例中的相关内容。The storage unit 303 is configured to store the valid video frame into a bmp format thumbnail and store it in a specified cache directory; refer to related content in the method embodiment.
缩略图显示单元304,设置为在检测到所述PVR录制管理界面中仍有所述录制视频文件时,则将所述录制视频文件以所述缩略图作为封面进行显示;可参考方法实施例中的相关内容。The thumbnail display unit 304 is configured to display the recorded video file with the thumbnail as a cover when detecting that the recorded video file is still in the PVR recording management interface; Related content.
可选地,参考图8,其中,所述有效视频帧抓取单元302包括:Optionally, referring to FIG. 8, the valid video frame capture unit 302 includes:
录制视频文件后台播放单元3021,设置为在所述PVR录制管理界面将所述录制视频文件的数据发送至所述后台线程后,启动后台线程,在后台启动视频播放器以播放所述录制视频文件;可参考方法实施例中的相关内容。The recording video file background playing unit 3021 is configured to: after the data of the recorded video file is sent to the background thread in the PVR recording management interface, start a background thread, and start a video player in the background to play the recorded video file. Reference can be made to the relevant content in the method embodiment.
彩色点个数判断单元3022,设置为在所述视频播放器播放过程中抓取视频帧,并判断抓取的视频帧的彩色点个数是否大于等于预定阈值;可参考方法实施例中的相关内容。The color point number determining unit 3022 is configured to capture a video frame during playback of the video player, and determine whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold; refer to the correlation in the method embodiment. content.
第一有效视频帧判定单元3023,设置为当抓取的视频帧的彩色点个数大于等于预定阈值时,则停止抓取视频帧,将当前视频帧作为所述有效视频帧;可 参考方法实施例中的相关内容。The first effective video frame determining unit 3023 is configured to stop capturing the video frame and use the current video frame as the valid video frame when the number of the color points of the captured video frame is greater than or equal to a predetermined threshold. Refer to the relevant content in the method embodiment.
第二有效视频帧判定单元3024,设置为在抓取的视频帧的彩色点个数小于预定阈值时,则继续抓取视频帧,当抓取视频帧的次数大于预定次数时停止抓取视频帧,将抓取的彩色点个数最多的视频帧作为所述有效视频帧;可参考方法实施例中的相关内容。The second effective video frame determining unit 3024 is configured to continue to capture the video frame when the number of color points of the captured video frame is less than a predetermined threshold, and stop capturing the video frame when the number of times the video frame is captured is greater than a predetermined number of times The video frame with the largest number of captured color points is used as the valid video frame; reference may be made to related content in the method embodiment.
可选地,参考图9,其中,所述存储单元303包括:Optionally, referring to FIG. 9, the storage unit 303 includes:
密钥生成单元3031,设置为获取所述有效视频帧对应的录制视频文件的文件名,根据MD5算法对所述文件名计算后生成密钥名称;可参考方法实施例中的相关内容。The key generating unit 3031 is configured to acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the MD5 algorithm; reference may be made to related content in the method embodiment.
封装与存储单元3032,设置为将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将所述密钥名作为该bmp格式的缩略图的文件名;可参考方法实施例中的相关内容。The encapsulation and storage unit 3032 is configured to encapsulate the valid video frame into a thumbnail of the bmp format, store it in a specified cache directory, and use the key name as a file name of the thumbnail of the bmp format; Related content in the example.
其中,所述彩色点是指视频帧中的像素点的r分量、g分量、b分量满足max(|r-g|,|r-b|,|b-g|)>50的像素点;可参考方法实施例中的相关内容。The color point refers to a pixel point where the r component, the g component, and the b component of the pixel in the video frame satisfy max(|rg|, |rb|, |bg|)>50; refer to the method embodiment. Related content.
综上所述,本实施例提供了一种基于PVR机顶盒的录制文件封面显示系统,以录制视频文件中的视频帧的缩略图作为录制视频文件的封面显示,使用户可以方便、快捷的获取不同的录制视频文件的差异,从而快速获取自己想要的录制视频文件进行播放。In summary, the present embodiment provides a recording file cover display system based on a PVR set-top box, which uses a thumbnail of a video frame in a recorded video file as a cover display of the recorded video file, so that the user can obtain differently conveniently and quickly. The difference in recording video files allows you to quickly get the recorded video files you want to play.
一实施例还提供一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行上述方法。An embodiment further provides a computer readable storage medium storing computer executable instructions for performing the above method.
图10是一实施例的一种机顶盒的录制视频文件的显示设备的硬件结构示意图,如图10所示,该机顶盒的录制视频文件的显示设备包括:一个或多个处理器1010和存储器1020。图10中以一个处理器1010为例。FIG. 10 is a schematic diagram showing the hardware structure of a display device for recording a video file of a set top box according to an embodiment. As shown in FIG. 10, the display device for recording a video file of the set top box includes: one or more processors 1010 and a memory 1020. One processor 1010 is taken as an example in FIG.
所述机顶盒的录制视频文件的显示设备还可以包括:输入装置1030和输出装置1040。The display device for recording a video file of the set top box may further include: an input device 1030 and an output device 1040.
所述机顶盒的录制视频文件的显示设备中的处理器1010、存储器1020、输入装置1030和输出装置1040可以通过总线或者其他方式连接,图10中以通过总线连接为例。 The processor 1010, the memory 1020, the input device 1030, and the output device 1040 in the display device of the set top box recording the video file may be connected by a bus or other means, and the bus connection is taken as an example in FIG.
输入装置1030可以接收输入的数字或字符信息,输出装置1040可以包括显示屏等显示设备。The input device 1030 can receive input numeric or character information, and the output device 1040 can include a display device such as a display screen.
存储器1020作为一种计算机可读存储介质,可用于存储软件程序、计算机可执行程序以及模块。处理器1010通过运行存储在存储器1020中的软件程序、指令以及模块,从而执行多种功能应用以及数据处理,以实现上述实施例中的任意一种方法。The memory 1020 is a computer readable storage medium that can be used to store software programs, computer executable programs, and modules. The processor 1010 performs various functional applications and data processing by executing software programs, instructions, and modules stored in the memory 1020 to implement any of the above-described embodiments.
存储器1020可以包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需要的应用程序;存储数据区可存储根据机顶盒的录制视频文件的显示设备的使用所创建的数据等。此外,存储器可以包括随机存取存储器(Random Access Memory,RAM)等易失性存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件或者其他非暂态固态存储器件。The memory 1020 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; and the storage data area may store the use of the display device according to the recorded video file of the set top box. Data, etc. In addition, the memory may include volatile memory such as random access memory (RAM), and may also include non-volatile memory such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device.
存储器1020可以是非暂态计算机存储介质或暂态计算机存储介质。该非暂态计算机存储介质,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实施例中,存储器1020可选包括相对于处理器1010远程设置的存储器,这些远程存储器可以通过网络连接至机顶盒的录制视频文件的显示设备。上述网络的实例可以包括互联网、企业内部网、局域网、移动通信网及其组合。 Memory 1020 can be a non-transitory computer storage medium or a transitory computer storage medium. The non-transitory computer storage medium, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, memory 1020 can optionally include memory remotely located relative to processor 1010 that can be connected to the display device of the set top box for recording video files over a network. Examples of the above networks may include the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
输入装置1030可用于接收输入的数字或字符信息,以及产生与机顶盒的录制视频文件的显示设备的用户设置以及功能控制有关的键信号输入。输出装置1040可包括显示屏等显示设备。The input device 1030 can be configured to receive input numeric or character information, and to generate key signal inputs related to user settings and function control of a display device of the set video cassette of the set top box. The output device 1040 can include a display device such as a display screen.
本实施例的机顶盒的录制视频文件的显示设备还可以包括通信装置1050,通过通信网络传输和/或接收信息。The display device for recording a video file of the set top box of the present embodiment may further include a communication device 1050 for transmitting and/or receiving information through the communication network.
本领域普通技术人员可理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来执行相关的硬件来完成的,该程序可存储于一个非暂态计算机可读存储介质中,该程序在执行时,可包括如上述方法的实施例的流程,其中,该非暂态计算机可读存储介质可以为磁碟、光盘、只读存储记忆体(ROM)或随机存储记忆体(RAM)等。 A person skilled in the art can understand that all or part of the process of implementing the above embodiment method can be completed by executing related hardware by a computer program, and the program can be stored in a non-transitory computer readable storage medium. The program, when executed, may include the flow of an embodiment of the method as described above, wherein the non-transitory computer readable storage medium may be a magnetic disk, an optical disk, a read only memory (ROM), or a random access memory (RAM). Wait.
工业实用性Industrial applicability
本公开提供了一种机顶盒的录制视频文件的显示方法及系统,以录制文件中的视频帧的缩略图作为录制文件封面显示,使用户可以方便、快捷的获取不同的录制视频文件的差异,从而快速获取自己想要的录制视频文件进行播放。 The present disclosure provides a method and system for displaying a recorded video file of a set top box. The thumbnail of the video frame in the recorded file is displayed as a cover of the recorded file, so that the user can conveniently and quickly obtain the difference of different recorded video files, thereby Quickly get the recorded video file you want to play.

Claims (9)

  1. 一种机顶盒的录制视频文件的显示方法,包括:A method for displaying a recorded video file of a set top box, comprising:
    在检测到个人视频录制PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,并判断所述录制视频文件的信息中是否有缩略图;When detecting that the personal video recording PVR set top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file;
    在检测到录制视频文件的信息中已经有缩略图时,则将所述缩略图作为所述录制视频文件的封面进行显示;When there is already a thumbnail in the information of the recorded video file, the thumbnail is displayed as the cover of the recorded video file;
    在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示。When there is no thumbnail in the information of the recorded video file, the video frame of the recorded video file is captured, and after the valid video frame is captured, the valid video frame is classified according to a specific image format. The storage is stored in the specified cache directory, and the captured valid video frame is displayed as the cover of the recorded video file.
  2. 根据权利要求1所述的显示方法,其中,所述在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示的步骤包括:The display method according to claim 1, wherein when there is no thumbnail in the information of the recorded video file, the video frame of the recorded video file is captured, and the effective video is captured. After the frame, the valid video frame is stored in the specified cache directory according to a specific picture format, and the captured valid video frame is displayed as the cover of the recorded video file, including:
    在检测到所述录制视频文件的信息中没有缩略图时,获取预设的图片作为所述录制视频文件的封面进行显示;When it is detected that there is no thumbnail in the information of the recorded video file, acquiring a preset picture as a cover of the recorded video file for display;
    当所述PVR录制管理界面将所述录制视频文件发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧;After the PVR recording management interface sends the recorded video file to the background thread, the recorded video file is played in the background, and the video frame is captured by the snapshot function according to a preset rule, and the video frame that meets the predetermined condition is captured as a video frame. Valid video frame;
    将所述有效视频帧封装成位图bmp格式的缩略图后存储至指定缓存目录;Encapsulating the valid video frame into a thumbnail of the bitmap bmp format and storing it in a specified cache directory;
    在检测到所述PVR录制管理界面中仍有所述录制视频文件时,则将所述录制视频文件以所述缩略图作为封面进行显示。When it is detected that the recorded video file is still in the PVR recording management interface, the recorded video file is displayed with the thumbnail as a cover.
  3. 根据权利要求2所述的显示方法,其中,所述在所述PVR录制管理界面获取所述录制视频文件的数据发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧的步骤包括:The display method according to claim 2, wherein after the data of the recorded video file is acquired by the PVR recording management interface and sent to a background thread, the recorded video file is played in the background, and is passed according to a preset rule. The snapshot function captures a video frame, and the steps of capturing a video frame that meets a predetermined condition as a valid video frame include:
    在所述PVR录制管理界面将所述录制视频文件的数据发送至所述后台线程后,启动后台线程,在后台启动视频播放器以播放所述录制视频文件;After the data of the recorded video file is sent to the background thread in the PVR recording management interface, the background thread is started, and the video player is started in the background to play the recorded video file;
    在所述视频播放器播放过程中抓取视频帧,并判断抓取的视频帧的彩色点个数是否大于等于预定阈值;Grasing a video frame during playback of the video player, and determining whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold;
    当抓取的视频帧的彩色点个数大于等于预定阈值时,则停止抓取视频帧, 将当前视频帧作为所述有效视频帧;在抓取的视频帧的彩色点个数小于预定阈值时,则继续抓取视频帧,当抓取视频帧的次数大于预定次数时停止抓取视频帧,将抓取的彩色点个数最多的视频帧作为所述有效视频帧,所述彩色点是指所述视频帧中满足预设条件的像素点,所述预设条件为所述像素点的r分量、g分量和b分量中的两个分量之间的差值的绝对值最大值大于50的像素点。When the number of color points of the captured video frame is greater than or equal to a predetermined threshold, the video frame is stopped to be captured. The current video frame is used as the valid video frame; when the number of color points of the captured video frame is less than a predetermined threshold, the video frame is continuously captured, and when the number of captured video frames is greater than a predetermined number of times, the video frame is stopped. The video frame with the largest number of captured color points is used as the effective video frame, and the color point refers to a pixel point in the video frame that satisfies a preset condition, and the preset condition is the pixel point. The absolute value of the difference between the two components of the r component, the g component, and the b component has a maximum value greater than 50 pixel points.
  4. 根据权利要求3所述的显示方法,其中,所述将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录的步骤包括:The display method according to claim 3, wherein the step of storing the valid video frame into a bmp format thumbnail and storing it in a specified cache directory comprises:
    获取所述有效视频帧对应的录制视频文件的文件名,根据消息摘要算法第五版MD5算法对所述文件名计算后生成密钥名称;Obtaining a file name of the recorded video file corresponding to the valid video frame, and generating a key name after calculating the file name according to the message digest algorithm fifth edition MD5 algorithm;
    将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将所述密钥名作为该bmp格式的缩略图的文件名。The valid video frame is encapsulated into a thumbnail of the bmp format and stored in a specified cache directory, and the key name is used as a file name of the thumbnail of the bmp format.
  5. 一种机顶盒的录制视频文件的显示系统,包括:A display system for recording video files of a set top box, comprising:
    检测与获取模块,设置为在检测到个人视频录制PVR机顶盒进入PVR录制管理界面时,获取录制视频文件的信息,并判断所述录制视频文件的信息中是否有缩略图;The detecting and acquiring module is configured to: when detecting the personal video recording PVR set top box enters the PVR recording management interface, obtain information of the recorded video file, and determine whether there is a thumbnail in the information of the recorded video file;
    第一封面显示控制模块,设置为在检测到录制视频文件的信息中已经有缩略图时,则将所述缩略图作为所述录制视频文件的封面进行显示;a first cover display control module configured to display the thumbnail as a cover of the recorded video file when a thumbnail has been detected in the information of the recorded video file;
    第二封面显示控制模块,设置为在检测到所述录制视频文件的信息中没有缩略图时,则对所述录制视频文件的视频帧进行抓取,在抓取到有效视频帧后,将所述有效视频帧按照特定的图片格式存储到指定缓存目录,并将抓取到的所述有效视频帧作为所述录制视频文件的封面进行显示。a second cover display control module, configured to: when there is no thumbnail in the information of the recorded video file, capture the video frame of the recorded video file, and after capturing the valid video frame, The valid video frame is stored in a specified cache directory according to a specific picture format, and the captured valid video frame is displayed as a cover of the recorded video file.
  6. 根据权利要求5所述的显示系统,其中,所述第二封面显示控制模块包括:The display system of claim 5, wherein the second cover display control module comprises:
    预设图片显示单元,设置为在检测到所述录制视频文件的信息中没有缩略图时,获取预设的图片作为所述录制视频文件的封面进行显示;a preset picture display unit configured to: when there is no thumbnail in the information of the recorded video file, obtain a preset picture as a cover of the recorded video file;
    有效视频帧抓取单元,设置为当所述PVR录制管理界面将所述录制视频文件发送至后台线程后,在后台播放所述录制视频文件,根据预先设置的规则通过快照功能抓取视频帧,抓取符合预定条件的视频帧作为有效视频帧;The effective video frame capture unit is configured to play the recorded video file in the background after the PVR recording management interface sends the recorded video file to the background thread, and capture the video frame by using the snapshot function according to a preset rule. Grab a video frame that meets the predetermined condition as a valid video frame;
    存储单元,设置为将所述有效视频帧封装成位图bmp格式的缩略图后存储至指定缓存目录;a storage unit, configured to encapsulate the valid video frame into a bitmap of a bitmap bmp format and store the image in a specified cache directory;
    缩略图显示单元,设置为在检测到所述PVR录制管理界面中仍有所述录制 视频文件时,则将所述录制视频文件以所述缩略图作为封面进行显示。a thumbnail display unit configured to still have the recording in the PVR recording management interface detected When the video file is used, the recorded video file is displayed with the thumbnail as a cover.
  7. 根据权利要求6所述的显示系统,其中,所述有效视频帧抓取单元包括:The display system according to claim 6, wherein the effective video frame capture unit comprises:
    录制视频文件后台播放单元,设置为在所述PVR录制管理界面将所述录制视频文件的数据发送至所述后台线程后,启动后台线程,在后台启动视频播放器以播放所述录制视频文件;Recording a video file background playing unit, configured to: after the data of the recorded video file is sent to the background thread in the PVR recording management interface, start a background thread, and start a video player in the background to play the recorded video file;
    彩色点个数判断单元,设置为在所述视频播放器播放过程中抓取视频帧,并判断抓取的视频帧的彩色点个数是否大于等于预定阈值;The color point number determining unit is configured to capture a video frame during playback of the video player, and determine whether the number of color points of the captured video frame is greater than or equal to a predetermined threshold;
    第一有效视频帧判定单元,设置为当抓取的视频帧的彩色点个数大于等于预定阈值时,则停止抓取视频帧,将当前视频帧作为所述有效视频帧;The first valid video frame determining unit is configured to stop capturing the video frame and use the current video frame as the effective video frame when the number of the color points of the captured video frame is greater than or equal to a predetermined threshold;
    第二有效视频帧判定单元,设置为在抓取的视频帧的彩色点个数小于预定阈值时,则继续抓取视频帧,当抓取视频帧的次数大于预定次数时停止抓取视频帧,将抓取的彩色点个数最多的视频帧作为所述有效视频帧,其中,所述彩色点是指所述视频帧中满足预设条件的像素点,所述预设条件为所述像素点的r分量、g分量和b分量中的两个分量之间的差值的绝对值最大值大于50的像素点。The second effective video frame determining unit is configured to continue to capture the video frame when the number of color points of the captured video frame is less than a predetermined threshold, and stop capturing the video frame when the number of times the video frame is captured is greater than a predetermined number of times. The video frame with the largest number of captured color points is used as the effective video frame, wherein the color point refers to a pixel point in the video frame that satisfies a preset condition, and the preset condition is the pixel point. The absolute value of the difference between the two components of the r component, the g component, and the b component has a maximum value greater than 50 pixel points.
  8. 根据权利要求7所述的显示系统,其中,所述将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录的步骤包括:The display system according to claim 7, wherein the step of storing the valid video frame into a bmp format thumbnail and storing it in a specified cache directory comprises:
    密钥生成单元,设置为获取所述有效视频帧对应的录制视频文件的文件名,根据消息摘要算法第五版MD5算法对所述文件名计算后生成密钥名称;a key generating unit, configured to acquire a file name of the recorded video file corresponding to the valid video frame, and generate a key name after calculating the file name according to the message digest algorithm fifth version MD5 algorithm;
    封装与存储单元,设置为将所述有效视频帧封装成bmp格式的缩略图后存储至指定缓存目录,并将所述密钥名作为该bmp格式的缩略图的文件名。The encapsulation and storage unit is configured to encapsulate the valid video frame into a bmp format thumbnail and store it in a specified cache directory, and use the key name as a file name of the bmp format thumbnail.
  9. 一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行权利要求1-4中任一项的方法。 A computer readable storage medium storing computer executable instructions for performing the method of any of claims 1-4.
PCT/CN2017/111944 2016-11-22 2017-11-20 Method and system for displaying video file recorded on set-top box WO2018095302A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201611044825.9A CN106559697B (en) 2016-11-22 2016-11-22 A kind of recorded file cover display methods and system based on PVR set-top boxes
CN201611044825.9 2016-11-22

Publications (1)

Publication Number Publication Date
WO2018095302A1 true WO2018095302A1 (en) 2018-05-31

Family

ID=58444874

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/111944 WO2018095302A1 (en) 2016-11-22 2017-11-20 Method and system for displaying video file recorded on set-top box

Country Status (2)

Country Link
CN (1) CN106559697B (en)
WO (1) WO2018095302A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114666667A (en) * 2022-03-03 2022-06-24 海宁奕斯伟集成电路设计有限公司 Video key point generation method and device, electronic equipment and storage medium

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106559697B (en) * 2016-11-22 2018-09-18 深圳创维数字技术有限公司 A kind of recorded file cover display methods and system based on PVR set-top boxes
CN107886518B (en) * 2017-11-23 2020-10-09 阿里巴巴(中国)有限公司 Picture detection method and device, electronic equipment and readable storage medium
CN107977436A (en) * 2017-12-05 2018-05-01 广东欧珀移动通信有限公司 Filename generation method, device, terminal and the storage medium of record screen file
CN108833938B (en) * 2018-06-20 2021-05-28 南京尚网网络科技有限公司 Method and apparatus for selecting video covers
CN109862405A (en) * 2019-03-04 2019-06-07 珠海迈越信息技术有限公司 A kind of automatic management PVR audio-video control method of intelligence for set-top box
CN111405221B (en) * 2020-01-13 2023-03-24 Vidaa(荷兰)国际控股有限公司 Display device and display method of recording file list
CN113114965B (en) * 2020-01-13 2022-03-22 海信电子科技(深圳)有限公司 PVR file management method, display device and set top box
CN111901679A (en) * 2020-08-10 2020-11-06 广州繁星互娱信息科技有限公司 Method and device for determining cover image, computer equipment and readable storage medium
CN112423097B (en) * 2020-11-20 2023-02-28 杭州国芯科技股份有限公司 Program recording and playing method for realizing embedded equipment based on PVR protocol
CN113407774A (en) * 2021-06-30 2021-09-17 广州酷狗计算机科技有限公司 Cover determining method and device, computer equipment and storage medium
CN114007133B (en) * 2021-10-25 2024-02-23 杭州当虹科技股份有限公司 Video playing cover automatic generation method and device based on video playing

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060064716A1 (en) * 2000-07-24 2006-03-23 Vivcom, Inc. Techniques for navigating multiple video streams
CN101572788A (en) * 2009-04-03 2009-11-04 深圳市同洲电子股份有限公司 Method, system and PVR set-top box for poster displaying of recorded files
CN103024567A (en) * 2012-12-06 2013-04-03 广东欧珀移动通信有限公司 Method and system for video preview of mobile terminal
CN104902338A (en) * 2015-05-25 2015-09-09 广州视源电子科技股份有限公司 Television channel review method and device
CN106101868A (en) * 2016-07-18 2016-11-09 乐视控股(北京)有限公司 Reduced graph generating method and generating means
CN106559697A (en) * 2016-11-22 2017-04-05 深圳创维数字技术有限公司 A kind of recorded file front cover display packing and system based on PVR Set Top Boxes

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060064716A1 (en) * 2000-07-24 2006-03-23 Vivcom, Inc. Techniques for navigating multiple video streams
CN101572788A (en) * 2009-04-03 2009-11-04 深圳市同洲电子股份有限公司 Method, system and PVR set-top box for poster displaying of recorded files
CN103024567A (en) * 2012-12-06 2013-04-03 广东欧珀移动通信有限公司 Method and system for video preview of mobile terminal
CN104902338A (en) * 2015-05-25 2015-09-09 广州视源电子科技股份有限公司 Television channel review method and device
CN106101868A (en) * 2016-07-18 2016-11-09 乐视控股(北京)有限公司 Reduced graph generating method and generating means
CN106559697A (en) * 2016-11-22 2017-04-05 深圳创维数字技术有限公司 A kind of recorded file front cover display packing and system based on PVR Set Top Boxes

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114666667A (en) * 2022-03-03 2022-06-24 海宁奕斯伟集成电路设计有限公司 Video key point generation method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN106559697A (en) 2017-04-05
CN106559697B (en) 2018-09-18

Similar Documents

Publication Publication Date Title
WO2018095302A1 (en) Method and system for displaying video file recorded on set-top box
US8260090B2 (en) Information processing apparatus, imaging apparatus, image display control method and computer program
US9143691B2 (en) Apparatus, method, and computer-readable storage medium for displaying a first image and a second image corresponding to the first image
US9013604B2 (en) Video summary including a particular person
US9344760B2 (en) Information processing apparatus, information processing method, and program
US8665345B2 (en) Video summary including a feature of interest
US9124860B2 (en) Storing a video summary as metadata
US8432965B2 (en) Efficient method for assembling key video snippets to form a video summary
US9071806B2 (en) Reproducing apparatus
WO2017166509A1 (en) Video playback control method and device
US8446490B2 (en) Video capture system producing a video summary
CN103024607A (en) Method and apparatus for displaying summary video
US20160358633A1 (en) Content playback and recording based on scene change detection and metadata
US20230239539A1 (en) Content-aware progress bar
JP6214762B2 (en) Image search system, search screen display method
CN114710707A (en) Display device and video thumbnail acquisition method
US20180139493A1 (en) Method for setting the level of definition of the images of a multimedia programme
US20190215573A1 (en) Method and device for acquiring and playing video data
US11546666B1 (en) Key event trick-play operation
KR101481689B1 (en) Method and apparatus for detecting multimedia contents using number information
JP2012227615A (en) Recording and reproducing device
EP3855439A1 (en) Recording device and recording method
US20150229786A1 (en) Communication device and control method of communication device
CN113010713A (en) Method for previewing multimedia video picture
JP2014107677A (en) Electronic apparatus, electronic apparatus control method, and electronic apparatus control program

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17874878

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17874878

Country of ref document: EP

Kind code of ref document: A1