[go: up one dir, main page]

CN104254022B - Caption presentation method and device - Google Patents

Caption presentation method and device Download PDF

Info

Publication number
CN104254022B
CN104254022B CN201410499759.9A CN201410499759A CN104254022B CN 104254022 B CN104254022 B CN 104254022B CN 201410499759 A CN201410499759 A CN 201410499759A CN 104254022 B CN104254022 B CN 104254022B
Authority
CN
China
Prior art keywords
subtitle
video file
ratio
threshold
embedded
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410499759.9A
Other languages
Chinese (zh)
Other versions
CN104254022A (en
Inventor
刘朱坤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiaomi Inc
Original Assignee
Xiaomi Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xiaomi Inc filed Critical Xiaomi Inc
Priority to CN201410499759.9A priority Critical patent/CN104254022B/en
Publication of CN104254022A publication Critical patent/CN104254022A/en
Application granted granted Critical
Publication of CN104254022B publication Critical patent/CN104254022B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
  • Studio Circuits (AREA)
  • Transforming Electric Information Into Light Information (AREA)

Abstract

The disclosure proposes a kind of caption presentation method, the method includes:Judge that the video file whether there is embedded subtitle;When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.By the disclosure, it is possible to prevente effectively from video display process, the problem of subtitle is overlapped.

Description

Caption presentation method and device
Technical field
This disclosure relates to video technique field, especially user's caption presentation method and device.
Background technology
In playing video file, in order to use spectators that can be better understood from the content in video described in personage, usually Corresponding subtitle can be shown when playing video.
Currently, the subtitle of video is divided into two kinds of embedded subtitle and plug-in subtitle.The embedded subtitle, refers to being embedded in video Subtitle in file, subtitle file itself can not be extracted individually;Plug-in subtitle refers to the subtitle detached with video file, Subtitle file itself can be extracted individually.
Video file is in playing process, is that video shows plug-in subtitle, meeting again at this time if video, which exists, embeds subtitle The problem of causing subtitle to be overlapped, user experience are very poor.
Invention content
To overcome the problems in correlation technique, a kind of caption presentation method of disclosure offer and device.
According to the first aspect of the embodiments of the present disclosure, a kind of caption presentation method is provided, the method includes:
Judge that the video file whether there is embedded subtitle;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
Optionally, described to judge that the video file whether there is embedded subtitle and include:
Key frame is extracted from the video file;
Calculate pixel number identical with the default color values of subtitle and sum of all pixels in the subtitle hot-zone of the key frame Ratio;
Judge whether the ratio is more than first threshold;
When the ratio is more than the first threshold, determines that the video file exists and embed subtitle;
When the ratio is not more than the first threshold, determine that embedded subtitle is not present in the video file.
Optionally, described to judge whether the ratio is more than before first threshold, further include:
Judge whether the ratio is less than second threshold;
When the ratio is less than the second threshold, determine that the key frame is effective key frame, and continue to judge institute State whether threshold value is more than first threshold.
Optionally, the key frame that extracted from the video file includes:
The identical progress point in several duration intervals is set in the video file;
The video frame on the progress point is extracted as key frame.
Optionally, described when embedded subtitle is not present in the video file, show the plug-in subtitle packet of the video file It includes:
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown automatically.
Optionally, described when embedded subtitle is not present in the video file, show the plug-in subtitle packet of the video file It includes:
When embedded subtitle is not present in the video file, user option is provided a user by default interface;Wherein institute User option is stated for prompting the user whether to show plug-in subtitle;
Receive the operational order that user is directed to user option input;
When the operational order received is to show the instruction of plug-in subtitle, plug-in subtitle is shown.
According to the second aspect of the embodiment of the present disclosure, a kind of subtitling display equipment is provided, described device includes:
Judgment module, for judging that the video file whether there is embedded subtitle;
Display module, for when embedded subtitle is not present in the video file, showing the plug-in subtitle of the video file.
Optionally, the judgment module includes:
Extracting sub-module, for extracting key frame from the video file;
Computational submodule, pixel identical with the default color values of subtitle in the subtitle hot-zone for calculating the key frame The ratio of number and sum of all pixels;
First judging submodule, for judging whether the ratio is more than first threshold;
First determination sub-module embeds word for when the ratio is more than first threshold, determining that the video file exists Curtain;
Second determination sub-module, for when the ratio is not more than the first threshold, determining that the video file is not deposited In embedded subtitle.
Optionally, the judgment module further includes:
Second judgment submodule is used for before the first judging submodule judges whether the ratio is more than first threshold, Judge whether the ratio is less than second threshold;
Third determination sub-module, for when the ratio is less than the second threshold, determining that the key frame is effective Key frame, and turn the processing of the first judging submodule.
Optionally, the extracting sub-module includes:
Submodule is arranged in progress point, for the identical progress point in several duration intervals to be arranged in the video file;
Key-frame extraction submodule, for extracting the video frame on the progress point as key frame.
Optionally, the display module includes:
First display sub-module, for when embedded subtitle is not present in the video file, showing the video file automatically Plug-in subtitle.
Optionally, the display module includes:
Option provides submodule, for when embedded subtitle is not present in the video file, passing through default boundary's user oriented User option is provided;The wherein described user option is for prompting the user whether to show plug-in subtitle;
Command reception submodule is directed to the operational order of user option input for receiving user;
Second display sub-module, for being display when showing the instruction of plug-in subtitle in the operational order received Plug-in subtitle.
According to the second aspect of the embodiment of the present disclosure, a kind of subtitling display equipment is provided, including:
Processor;
Memory for storing processor-executable instruction;
Wherein, the processor is configured as:
Judge that the video file whether there is embedded subtitle;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
The technical scheme provided by this disclosed embodiment can include the following benefits:
In the above example of the disclosure, by judging that video file whether there is embedded subtitle, described regard is being judged It when embedded subtitle is not present in frequency file, then shows plug-in subtitle, effectively prevents in video display process, subtitle overlapping is asked Topic.
It should be understood that above general description and following detailed description is only exemplary and explanatory, not The disclosure can be limited.
Description of the drawings
The drawings herein are incorporated into the specification and forms part of this specification, and shows the implementation for meeting the disclosure Example, and together with specification for explaining the principles of this disclosure.
Fig. 1 is a kind of flow diagram of caption presentation method shown according to an exemplary embodiment;
Fig. 2 is the flow diagram of another caption presentation method shown according to an exemplary embodiment;
Fig. 3 is the schematic diagram that key frame is extracted in slave video file shown according to an exemplary embodiment;
Fig. 4 is according to the schematic diagram for providing a user user option shown in an exemplary embodiment;
Fig. 5 is a kind of schematic block diagram of subtitling display equipment shown according to an exemplary embodiment;
Fig. 6 is the schematic block diagram of another subtitling display equipment shown according to an exemplary embodiment;
Fig. 7 is the schematic block diagram of another subtitling display equipment shown according to an exemplary embodiment;
Fig. 8 is the schematic block diagram of another subtitling display equipment shown according to an exemplary embodiment;
Fig. 9 is the schematic block diagram of another subtitling display equipment shown according to an exemplary embodiment;
Figure 10 is the schematic block diagram of another subtitling display equipment shown according to an exemplary embodiment;
Figure 11 is a kind of structural schematic diagram for subtitling display equipment shown according to an exemplary embodiment.
Specific implementation mode
Example embodiments are described in detail here, and the example is illustrated in the accompanying drawings.Following description is related to When attached drawing, unless otherwise indicated, the same numbers in different drawings indicate the same or similar elements.Following exemplary embodiment Described in embodiment do not represent all implementations consistent with this disclosure.On the contrary, they be only with it is such as appended The example of the consistent device and method of some aspects be described in detail in claims, the disclosure.
It is the purpose only merely for description specific embodiment in the term that the disclosure uses, is not intended to be limiting the disclosure. The "an" of singulative used in disclosure and the accompanying claims book, " described " and "the" are also intended to including majority Form, unless context clearly shows that other meanings.It is also understood that term "and/or" used herein refers to and wraps Containing one or more associated list items purposes, any or all may be combined.
It will be appreciated that though various information, but this may be described using term first, second, third, etc. in the disclosure A little information should not necessarily be limited by these terms.These terms are only used for same type of information being distinguished from each other out.For example, not departing from In the case of disclosure range, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as One information.Depending on context, word as used in this " if " can be construed to " ... when " or " when ... When " or " in response to determination ".
As shown in Figure 1, Fig. 1 is a kind of caption presentation method shown according to an exemplary embodiment, this method is for eventually In end, the terminal can be TV, smart mobile phone, tablet computer etc., the described method comprises the following steps:
In a step 101, judge that the video file whether there is embedded subtitle;
In the present embodiment, judge that video file whether there is embedded subtitle, can be based in video file subtitle hot-zone Identical with the default color values of the subtitle pixel number proportion in total pixel number carries out intelligent decision;When the ratio reaches To certain level, system can consider the included embedded subtitle of the video file.For example, it is assumed that subtitle color is white, then can To account for the ratio of sum of all pixels by counting the number of white pixel point in subtitle hot-zone, to determine whether the video file carries Embedded subtitle.Certainly, when realizing, judge whether included embedded subtitle there can also be other methods in the video file, this Embodiment is no longer enumerated.
Realize when, key frame can be extracted from the video file, and calculate in the subtitle hot-zone of the key frame with Ratio between the identical pixel number of default color values and sum of all pixels of subtitle, then by the calculated ratio and setting First threshold is compared, if the ratio is more than the first threshold, it is believed that the video file, which exists, embeds subtitle, phase Instead, if the ratio is less than or equal to the first threshold, it is believed that embedded subtitle is not present in the video file.
Wherein, the size of the first threshold can choose engineering experience value, such as can choose a certain number of included The video file of embedded subtitle extracts key frame, and calculate respectively as Video reference files in above-mentioned Video reference files In the subtitle hot-zone of these Video reference files, pixel number identical with the default color values of subtitle institute's accounting in total pixel number Example is used as the first threshold after being then averaged calculated ratio value.
It, can be by being arranged between several durations in the video file when extracting key frame from the video file Every identical progress point, the video frame then extracted on progress point is realized as key frame.For example, can be by video text 20%, 40%, the 60% of part playing progress rate and 80% is set as progress point, then extracts the video frame on this 4 progress points As key frame.
In a step 102, when embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown;
In the present embodiment, when judging that embedded subtitle is not present in the video file, then when playing the video file, Show the plug-in subtitle of the video file;On the contrary, if the video file, which exists, embeds subtitle, the video file is being played When, acquiescence shows the embedded subtitle of the video file, to prevent from, when playing the video file for existing and embedding subtitle, showing simultaneously Plug-in subtitle is to cause subtitle to be overlapped.
Wherein, can be automatic when judging that embedded subtitle is not present in the video file when showing plug-in subtitle It has been shown that, can also manually be selected by user.
For example, when judging that embedded subtitle is not present in the video file, can on the display interface of terminal to Family exports a user option for prompting the user whether to show plug-in subtitle, then determines whether to show according to the user's choice Plug-in subtitle.
In the embodiment above, by judging that video file whether there is embedded subtitle, judging the video file It there is no when embedded subtitle, then shows plug-in subtitle, effectively prevents in video display process, the problem of subtitle is overlapped.
As shown in Fig. 2, Fig. 2 is a kind of caption presentation method shown according to an exemplary embodiment, this method is for eventually In end, the terminal can be TV, smart mobile phone, tablet computer etc., the described method comprises the following steps:
In step 201, key frame is extracted from video file;
It in the present embodiment, can be by being set in the video file when extracting key frame from the video file The identical progress point in several duration intervals is set, the video frame then extracted on progress point is realized as key frame.For example, asking Referring to Fig. 3,20%, 40%, the 60% of the video file playing progress rate and 80% can be set to progress point, then carried Take the video frame on this 4 progress points as key frame.
In step 202, pixel number identical with the default color values of subtitle in the subtitle hot-zone of the key frame is calculated With the ratio of sum of all pixels;
In the present embodiment, judge that video file whether there is embedded subtitle, can be based in video file subtitle hot-zone Identical with the default color values of the subtitle pixel number proportion in total pixel number carries out intelligent decision;When the ratio reaches To certain level, system can consider the included embedded subtitle of the video file.For example, it is assumed that subtitle color is white, then can To account for the ratio of sum of all pixels by counting the number of white pixel point in subtitle hot-zone, to determine whether the video file carries Embedded subtitle.
When computationally stating ratio, can determine the subtitle hot-zone of the key frame first, the subtitle hot-zone be regarding Delimited in advance in frequency frame for showing the region of subtitle, the position of subtitle hot-zone is usually consistent in standard video format, is position Elongated zones in the underface of video file.After the subtitle hot-zone of the key frame is determined, subtitle heat can be counted Sum of all pixels in area in pixel number identical with the default color values of subtitle and subtitle hot-zone, and calculate described with subtitle The ratio of default color values identical pixel number and the sum of all pixels.
Wherein, the default color values of the subtitle are that the display color of subtitle in video is indicated according to general color The value that method obtains, for example, by taking RGB color standard as an example, if subtitle is white (subtitle is usually pure color), according to RGB (255,255,255) usually are used for indicating that white, the corresponding default color values of white are #FFFFFF in color standard.
In step 203, judge whether the ratio is more than first threshold;
In step 204, it when the ratio is more than the first threshold, determines that the video file exists and embeds subtitle; When the ratio is not more than the first threshold, determine that embedded subtitle is not present in the video file;
In the present embodiment, after calculating the ratio, the ratio and preset first threshold can be carried out Compare, if it is described be more than the first threshold when, can determine the video file exist embed subtitle;If the ratio When less than or equal to the first threshold, then it can determine that embedded subtitle is not present in the video file.
Wherein, the size of the first threshold can choose engineering experience value when realizing, such as can choose a fixed number The video file of the included embedded subtitle of amount is as Video reference files, and extraction is crucial respectively in above-mentioned Video reference files Frame, and calculate in the subtitle hot-zone of these Video reference files, pixel number identical with the default color values of subtitle is in total pixel Proportion in number is used as the first threshold after being then averaged calculated ratio value.
It is worth noting that the calculated first threshold is reference value, the institute theoretically chosen according to the method described above The quantity for stating Video reference files is more, and the first threshold is more accurate, therefore can be with video reference text when realizing The first threshold is constantly calibrated in the increase of number of packages amount.
In step 205, when embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
In the present embodiment, when judging the embedded subtitle of video file presence according to the method described above, then this is being played When video file, acquiescence shows the embedded subtitle of the video file, to prevent when playing the video file for existing and embedding subtitle, Show plug-in subtitle to cause subtitle to be overlapped simultaneously.Opposite, if it is judged that embedded subtitle is not present in the video file, Then when playing the video file, the plug-in subtitle of the video file is shown.
Wherein, can be that there is no embedded judging the video file when showing the plug-in subtitle of the video It shows, can also be manually selected by user automatically when subtitle.
When realizing, when system judges that embedded subtitle is not present in the video file according to the above method, Ke Yili The operation for the plug-in subtitle for showing the video file automatically is triggered on backstage;Can also on the display interface of terminal to Family exports a user option for prompting the user whether to show plug-in subtitle, and system receives user on backstage and selected for the user Then the operational order of item input determines whether that triggering shows the plug-in of the video file according to the operational order received The operation of subtitle.
For example, referring to Fig. 4, the user option can be a prompt text including " whether showing plug-in subtitle " The text prompting frame of this and two kinds of options of "Yes" and "No", when user selects "Yes", system can be in backstage triggering display The operation of plug-in subtitle;Same reason, if user has selected "No", system triggering aforesaid operations from the background, acquiescence is aobvious Show the embedded subtitle of the video file.
It is worth noting that when realizing since the first threshold can be with the Video reference files of selection Quantity and change, therefore when the Video reference files selection negligible amounts, then the first threshold may exist not Enough accurate problems are missed when consequently, it is possible to system video file described in intelligent decision being caused to whether there is plug-in subtitle Sentence.Therefore, it is chosen whether to show plug-in subtitle manually by user, can made when system intelligent decision malfunctions, by user hand The intelligent decision result of system is corrected in dynamic selection.
For example, if since first threshold is inaccurate, accidentally there will be the videos of embedded subtitle to be judged as being not present for system When embedded subtitle, at this time if showing plug-in subtitle automatically, it will cause subtitle overlappings, so if being selected manually by user It selects, can close plug-in subtitle when user has found that the video file carries embedded subtitle, to avoid asking for subtitle overlapping Topic.
By above description as it can be seen that above-mentioned caption presentation method is particularly suitable for regarding the standard of those included embedded subtitles Frequency format (such as MVB formats).
In the present embodiment, by calculating in video file subtitle hot-zone, pixel identical with the default color values of subtitle Number proportion in total pixel number carrys out video file described in intelligent decision and whether there is embedded subtitle, is judging described regard It when embedded subtitle is not present in frequency file, then shows plug-in subtitle, effectively prevents in video display process, subtitle overlapping is asked Topic.Meanwhile when showing plug-in subtitle, plug-in subtitle is shown by being chosen whether manually by user so that intelligently sentence in system When disconnected error, user can be corrected by the intelligent decision result for manually selecting to system.
In another optional embodiment, in conjunction with above-mentioned Fig. 1 or Fig. 2 shows embodiment, due to realize when, it is described There may be consistent problems with the color of subtitle for picture tone in key frame, for example, if the color of the subtitle is white Color, and what the key frame was presented is by chance snow scenes in mute, then at this time in subtitle hot-zone white pixel point number Amount can have that exception is bigger than normal, if can cause prodigious error using similar video frame as key frame.
Therefore, before judging whether the ratio is more than the first threshold, can also be by judging the ratio It is no to be less than second threshold, to confirm whether the key frame is effective key frame;If the ratio is less than the second threshold When, it may be determined that the key frame is effective key frame, and continues the above-mentioned operation for judging the threshold value and whether being more than first threshold; If the ratio be more than or equal to the second threshold, at this time in the subtitle hot-zone of the key frame there may be with subtitle The key frame, can be determined as invalid key frame by the identical pixel number of default color values problem extremely bigger than normal.For invalid Key frame can extract key frame again from the video file, and carry out the calculating of the ratio, until according to described Until two threshold decisions go out the key frame for effective key frame.
Wherein, the second threshold is more than the first threshold, the size of the second threshold in the present embodiment not into Row is particularly limited to, and can be configured according to practical application.For example, can 50% be set as the second threshold, if institute State wallpaper be more than 50% it is considered that the key frame it is invalid.
In the embodiment above, before judging whether the ratio is more than first threshold, by judging that the ratio is It is no to determine whether the key frame is effective less than second threshold, when determining that the key frame is effective, then carry out in next step Judgement, the erroneous judgement of system can be effectively reduced.
Corresponding with aforementioned caption presentation method embodiment, the disclosure additionally provides the embodiment of subtitling display equipment.
Fig. 5 is a kind of schematic block diagram of subtitling display equipment shown according to an exemplary embodiment.
As shown in figure 5, a kind of subtitling display equipment 500 shown according to an exemplary embodiment, including:Judgment module 501, display module 502;Wherein:
The judgment module 501 is configured as, and judges that the video file whether there is embedded subtitle;
The display module 502 is configured as, and when embedded subtitle is not present in the video file, shows the video file Plug-in subtitle.
In the embodiment above, by judging that video file whether there is embedded subtitle, judging the video file It there is no when embedded subtitle, then shows plug-in subtitle, effectively prevents in video display process, the problem of subtitle is overlapped.
Fig. 6 is referred to, Fig. 6 is another subtitling display equipment block diagram of the disclosure shown according to an exemplary embodiment, On the basis of aforementioned embodiment illustrated in fig. 5, the judgment module 501 further includes extracting sub-module 501A, calculates the embodiment Submodule 501B, the first judging submodule 501C, the first determination sub-module 501D and the second determination sub-module 502E;Wherein:
The extracting sub-module 501A is configured as, and key frame is extracted from the video file;
The computational submodule 501B is configured as, and calculates the default color with subtitle in the subtitle hot-zone of the key frame It is worth the ratio of identical pixel number and sum of all pixels;
The first judging submodule 501C is configured as, and judges whether the ratio is more than first threshold;
The first determination sub-module 501D is configured as, and when the ratio is more than first threshold, determines video text Part, which exists, embeds subtitle;
The second determination sub-module 501E is configured as, and when the ratio is not more than the first threshold, determining should Embedded subtitle is not present in video file.
Fig. 7 is referred to, Fig. 7 is another subtitling display equipment block diagram of the disclosure shown according to an exemplary embodiment, The embodiment on the basis of aforementioned embodiment illustrated in fig. 6, the judgment module 501 further include second judgment submodule 501F, Third determination sub-module 502G;Wherein:
The second judgment submodule 501F is configured as, and judges whether the ratio is more than the in the first judging submodule Before one threshold value, judge whether the ratio is less than second threshold;
The third determination sub-module 502G is configured as, when the ratio is less than the second threshold, described in determination Key frame is effective key frame, and turns the first judging submodule 501C processing;
It should be noted that second judgment submodule 501F, third shown in above-mentioned device embodiment shown in Fig. 7 are true The structure of stator modules 502G can also be included in the device embodiment of earlier figures 5, be not limited to this disclosure.
Fig. 8 is referred to, Fig. 8 is another subtitling display equipment block diagram of the disclosure shown according to an exemplary embodiment, For the embodiment on the basis of aforementioned embodiment illustrated in fig. 6, the extracting sub-module 501A further includes progress point setting submodule 501A1, key-frame extraction submodule 501A2;Wherein:
The progress point setting submodule 501A1 is configured as, several duration intervals are arranged in the video file Identical progress point;
The key-frame extraction submodule 501A2 is configured as, and extracts the video frame on the progress point as key frame.
It should be noted that progress point setting submodule 501A1, pass shown in above-mentioned device embodiment shown in Fig. 8 The structure of key frame extracting sub-module 501A2 can also be included in earlier figures 5 or the device embodiment of Fig. 7, not to this disclosure It is limited.
Fig. 9 is referred to, Fig. 9 is another subtitling display equipment block diagram of the disclosure shown according to an exemplary embodiment, For the embodiment on the basis of aforementioned embodiment illustrated in fig. 5, the display module 502 includes the first display sub-module 502A;Its In:
The first display sub-module 502A is configured as, automatic aobvious when embedded subtitle is not present in the video file Show the plug-in subtitle of the video file.
It should be noted that the structure of the first display sub-module 502A shown in above-mentioned device embodiment shown in Fig. 9 This disclosure can also be not limited included in the device embodiment of earlier figures 6-8.
Figure 10 is referred to, Figure 10 is another subtitling display equipment frame of the disclosure shown according to an exemplary embodiment Figure, for the embodiment on the basis of aforementioned embodiment illustrated in fig. 5, the display module 502 can also include that option provides submodule Block 502B, command reception submodule 502C and the second display sub-module 502D;Wherein:
The option provides submodule 502B and is configured as, when embedded subtitle is not present in the video file, by pre- If interface provides a user user option;The wherein described user option is for prompting the user whether to show plug-in subtitle;
Described instruction receiving submodule 502C is configured as, and is received user and is inputted for the user option
Operational order;
The second display sub-module 502D is configured as, and is the plug-in subtitle of display in the operational order received When instruction, plug-in subtitle is shown.
It should be noted that option shown in above-mentioned device embodiment shown in Fig. 10 provides submodule 502B, instruction The structure of receiving submodule 502C and the second display sub-module 502D can also be included in the device embodiment of earlier figures 6-9, This disclosure is not limited.
The function of modules and the realization process of effect specifically refer to and correspond to step in the above method in above-mentioned apparatus Realization process, details are not described herein.
For device embodiments, since it corresponds essentially to embodiment of the method, so related place is referring to method reality Apply the part explanation of example.The apparatus embodiments described above are merely exemplary, wherein described be used as separating component The module of explanation may or may not be physically separated, and the component shown as module can be or can also It is not physical module, you can be located at a place, or may be distributed on multiple network modules.It can be according to actual It needs that some or all of module therein is selected to realize the purpose of disclosure scheme.Those of ordinary skill in the art are not paying In the case of going out creative work, you can to understand and implement.
Correspondingly, the disclosure also provides a kind of subtitling display equipment, described device include memory and one or More than one program, either more than one program is stored in memory and is configured to by one or one for one of them It includes the instruction for being operated below that a above processor, which executes the one or more programs,:
Judge that the video file whether there is embedded subtitle;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
Figure 11 is a kind of structural schematic diagram of subtitling display equipment shown according to an exemplary embodiment.
As shown in figure 11, according to an exemplary embodiment shown in a kind of subtitling display equipment 110, which can be with It is computer, mobile phone, digital broadcast terminal, messaging devices, game console, tablet device, Medical Devices, body-building Equipment, personal digital assistant etc..
Referring to Fig.1 1, device 110 may include following one or more components:Processing component 111, memory 112, power supply Component 113, multimedia component 114, audio component 115, the interface 116 of input/output (I/O), sensor module 117, and Communication component 118.
The integrated operation of 111 usual control device 110 of processing component, such as with display, call, data communication, phase Machine operates and record operates associated operation.Processing component 111 may include that one or more processors 119 refer to execute It enables, to perform all or part of the steps of the methods described above.In addition, processing component 111 may include one or more modules, just Interaction between processing component 111 and other assemblies.For example, processing component 111 may include multi-media module, it is more to facilitate Interaction between media component 114 and processing component 111.
Memory 112 is configured as storing various types of data to support the operation in device 110.These data are shown Example includes instruction for any application program or method that are operated on device 110, contact data, and telephone book data disappears Breath, picture, video etc..Memory 112 can be by any kind of volatibility or non-volatile memory device or their group It closes and realizes, such as static RAM (SRAM), electrically erasable programmable read-only memory (EEPROM) is erasable to compile Journey read-only memory (EPROM), programmable read only memory (PROM), read-only memory (ROM), magnetic memory, flash Device, disk or CD.
Power supply module 113 provides electric power for the various assemblies of device 110.Power supply module 113 may include power management system System, one or more power supplys and other generated with for device 110, management and the associated component of distribution electric power.
Multimedia component 114 is included in the screen of one output interface of offer between described device 110 and user.One In a little embodiments, screen may include liquid crystal display (LCD) and touch panel (TP).If screen includes touch panel, screen Curtain may be implemented as touch screen, to receive input signal from the user.Touch panel includes one or more touch sensings Device is to sense the gesture on touch, slide, and touch panel.The touch sensor can not only sense touch or sliding action Boundary, but also detect duration and pressure associated with the touch or slide operation.In some embodiments, more matchmakers Body component 114 includes a front camera and/or rear camera.When device 110 is in operation mode, such as screening-mode or When video mode, front camera and/or rear camera can receive external multi-medium data.Each front camera and Rear camera can be a fixed optical lens system or have focusing and optical zoom capabilities.
Audio component 115 is configured as output and/or input audio signal.For example, audio component 115 includes a Mike Wind (MIC), when device 110 is in operation mode, when such as call model, logging mode and speech recognition mode, microphone by with It is set to reception external audio signal.The received audio signal can be further stored in memory 112 or via communication set Part 118 is sent.In some embodiments, audio component 115 further includes a loud speaker, is used for exports audio signal.
I/O interfaces 112 provide interface between processing component 111 and peripheral interface module, and above-mentioned peripheral interface module can To be keyboard, click wheel, button etc..These buttons may include but be not limited to:Home button, volume button, start button and lock Determine button.
Sensor module 117 includes one or more sensors, and the state for providing various aspects for device 110 is commented Estimate.For example, sensor module 117 can detect the state that opens/closes of device 110, and the relative positioning of component, for example, it is described Component is the display and keypad of device 110, and sensor module 117 can be with 110 1 components of detection device 110 or device Position change, the existence or non-existence that user contacts with device 110,110 orientation of device or acceleration/deceleration and device 110 Temperature change.Sensor module 117 may include proximity sensor, be configured to detect without any physical contact Presence of nearby objects.Sensor module 117 can also include optical sensor, such as CMOS or ccd image sensor, at As being used in application.In some embodiments, which can also include acceleration transducer, gyro sensors Device, Magnetic Sensor, pressure sensor or temperature sensor.
Communication component 118 is configured to facilitate the communication of wired or wireless way between device 110 and other equipment.Device 110 can access the wireless network based on communication standard, such as WiFi, 2G or 3G or combination thereof.In an exemplary implementation In example, communication component 118 receives broadcast singal or broadcast related information from external broadcasting management system via broadcast channel. In one exemplary embodiment, the communication component 118 further includes near-field communication (NFC) module, to promote short range communication.Example Such as, NFC module can be based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra wide band (UWB) technology, Bluetooth (BT) technology and other technologies are realized.
In the exemplary embodiment, device 110 can be believed by one or more application application-specific integrated circuit (ASIC), number Number processor (DSP), digital signal processing appts (DSPD), programmable logic device (PLD), field programmable gate array (FPGA), controller, microcontroller, microprocessor or other electronic components are realized, for executing the above method.
In the exemplary embodiment, it includes the non-transitorycomputer readable storage medium instructed, example to additionally provide a kind of Such as include the memory 112 of instruction, above-metioned instruction can be executed by the processor 119 of device 110 to complete the above method.For example, The non-transitorycomputer readable storage medium can be ROM, random access memory (RAM), CD-ROM, tape, floppy disk With optical data storage devices etc..
Wherein, when the instruction in the storage medium is executed by the processor of mobile terminal so that mobile terminal can A kind of caption presentation method is executed, including:
Judge that the video file whether there is embedded subtitle;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
Those skilled in the art after considering the specification and implementing the invention disclosed here, will readily occur to its of the disclosure Its embodiment.This application is intended to cover any variations, uses, or adaptations of the disclosure, these modifications, purposes or Person's adaptive change follows the general principles of this disclosure and includes the undocumented common knowledge in the art of the disclosure Or conventional techniques.The description and examples are only to be considered as illustrative, and the true scope and spirit of the disclosure are by following Claim is pointed out.
It should be understood that the present disclosure is not limited to the precise structures that have been described above and shown in the drawings, and And various modifications and changes may be made without departing from the scope thereof.The scope of the present disclosure is only limited by the accompanying claims.

Claims (11)

1. a kind of caption presentation method, which is characterized in that the method includes:
It is total to calculate pixel number identical with the default color values of subtitle and pixel in the subtitle hot-zone of the key frame in video file Several ratio, and embedded subtitle whether there is based on video file described in the ratio in judgement;Wherein, described to be based on the ratio Judge that the video file whether there is embedded subtitle and include:Judge whether the ratio is less than second threshold;When the ratio It when less than the second threshold, determines that the key frame is effective key frame, and continues to judge whether the threshold value is more than first Threshold value;When the ratio is more than the first threshold, determines that the video file exists and embed subtitle;When the ratio is not more than When the first threshold, determine that embedded subtitle is not present in the video file;The second threshold is more than the first threshold;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
2. the method as described in claim 1, which is characterized in that in the subtitle hot-zone for calculating the key frame in video file The ratio of identical with the default color values of subtitle pixel number and sum of all pixels, including:
Key frame is extracted from the video file;
Calculate the ratio of identical with the default color values of subtitle pixel number and sum of all pixels in the subtitle hot-zone of the key frame.
3. method as claimed in claim 2, which is characterized in that it is described from the video file extract key frame include:
The identical progress point in several duration intervals is set in the video file;
The video frame on the progress point is extracted as key frame.
4. the method as described in claim 1, which is characterized in that it is described when embedded subtitle is not present in the video file, it shows Show that the plug-in subtitle of the video file includes:
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown automatically.
5. the method as described in claim 1, which is characterized in that it is described when embedded subtitle is not present in the video file, it shows Show that the plug-in subtitle of the video file includes:
When embedded subtitle is not present in the video file, user option is provided a user by default interface;The wherein described use Family option is for prompting the user whether to show plug-in subtitle;
Receive the operational order that user is directed to user option input;
When the operational order received is to show the instruction of plug-in subtitle, plug-in subtitle is shown.
6. a kind of subtitling display equipment, which is characterized in that described device includes:
Judgment module, picture identical with the default color values of subtitle in the subtitle hot-zone for calculating the key frame in video file The ratio of prime number and sum of all pixels, and embedded subtitle whether there is based on video file described in the ratio in judgement;Wherein, described Judgment module is further:Judge whether the ratio is less than second threshold;When the ratio is less than the second threshold, determine The key frame is effective key frame, and continues to judge whether the threshold value is more than first threshold;Described in being more than when the ratio When first threshold, determines that the video file exists and embed subtitle;When the ratio is not more than the first threshold, determine that this is regarded Embedded subtitle is not present in frequency file;The second threshold is more than the first threshold;
Display module, for when embedded subtitle is not present in the video file, showing the plug-in subtitle of the video file.
7. device as claimed in claim 6, which is characterized in that the judgment module includes:
Extracting sub-module, for extracting key frame from the video file;
Computational submodule, in the subtitle hot-zone for calculating the key frame pixel number identical with the default color values of subtitle with The ratio of sum of all pixels.
8. device as claimed in claim 7, which is characterized in that the extracting sub-module includes:
Submodule is arranged in progress point, for the identical progress point in several duration intervals to be arranged in the video file;
Key-frame extraction submodule, for extracting the video frame on the progress point as key frame.
9. device as claimed in claim 7, which is characterized in that the display module includes:
First display sub-module, for when embedded subtitle is not present in the video file, showing the outer of the video file automatically Hang subtitle.
10. device as claimed in claim 7, which is characterized in that the display module includes:
Option provides submodule, for when embedded subtitle is not present in the video file, being provided a user by default interface User option;The wherein described user option is for prompting the user whether to show plug-in subtitle;
Command reception submodule is directed to the operational order of user option input for receiving user;
Second display sub-module, for being when showing the instruction of plug-in subtitle in the operational order received, display is plug-in Subtitle.
11. a kind of subtitling display equipment, which is characterized in that including:
Processor;
Memory for storing processor-executable instruction;
Wherein, the processor is configured as:
It is total to calculate pixel number identical with the default color values of subtitle and pixel in the subtitle hot-zone of the key frame in video file Several ratio, and embedded subtitle whether there is based on video file described in the ratio in judgement;Wherein, described to be based on the ratio Judge that the video file whether there is embedded subtitle and include:Judge whether the ratio is less than second threshold;When the ratio It when less than the second threshold, determines that the key frame is effective key frame, and continues to judge whether the threshold value is more than first Threshold value;When the ratio is more than the first threshold, determines that the video file exists and embed subtitle;When the ratio is not more than When the first threshold, determine that embedded subtitle is not present in the video file;The second threshold is more than the first threshold;
When embedded subtitle is not present in the video file, the plug-in subtitle of the video file is shown.
CN201410499759.9A 2014-09-25 2014-09-25 Caption presentation method and device Active CN104254022B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410499759.9A CN104254022B (en) 2014-09-25 2014-09-25 Caption presentation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410499759.9A CN104254022B (en) 2014-09-25 2014-09-25 Caption presentation method and device

Publications (2)

Publication Number Publication Date
CN104254022A CN104254022A (en) 2014-12-31
CN104254022B true CN104254022B (en) 2018-10-12

Family

ID=52188496

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410499759.9A Active CN104254022B (en) 2014-09-25 2014-09-25 Caption presentation method and device

Country Status (1)

Country Link
CN (1) CN104254022B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106911971A (en) * 2017-02-28 2017-06-30 维沃移动通信有限公司 A kind of video caption processing method and electronic equipment
CN111986656B (en) * 2020-08-31 2021-07-30 上海松鼠课堂人工智能科技有限公司 Teaching video automatic subtitle processing method and system
CN112464935A (en) * 2020-12-09 2021-03-09 深圳康佳电子科技有限公司 LRC lyric display control method, intelligent terminal and storage medium
CN114615520B (en) * 2022-03-08 2024-01-02 北京达佳互联信息技术有限公司 Subtitle positioning method, subtitle positioning device, computer equipment and medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3379453B2 (en) * 1998-12-17 2003-02-24 松下電器産業株式会社 Caption region detection method and device, and moving image search method and device
CN101043609A (en) * 2006-03-24 2007-09-26 株式会社东芝 Subtitle detection apparatus, subtitle detection method and pull-down signal detection apparatus
CN101115151A (en) * 2007-07-10 2008-01-30 北京大学 A method for extracting video subtitles
CN102098455A (en) * 2011-01-21 2011-06-15 四川长虹电器股份有限公司 System for supporting multi-format subtitle display on television
CN102843603A (en) * 2012-08-17 2012-12-26 Tcl集团股份有限公司 Intelligent television and method for controlling caption thereof
CN103034854A (en) * 2011-09-30 2013-04-10 富士通株式会社 Image processing device and image processing method
CN103067678A (en) * 2011-10-20 2013-04-24 四川长虹电器股份有限公司 Television subtitle display method and device

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4620163B2 (en) * 2009-06-30 2011-01-26 株式会社東芝 Still subtitle detection apparatus, video device for displaying image including still subtitle, and method for processing image including still subtitle
CN103729641A (en) * 2013-12-20 2014-04-16 乐视致新电子科技(天津)有限公司 Human body feature detecting method and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3379453B2 (en) * 1998-12-17 2003-02-24 松下電器産業株式会社 Caption region detection method and device, and moving image search method and device
CN101043609A (en) * 2006-03-24 2007-09-26 株式会社东芝 Subtitle detection apparatus, subtitle detection method and pull-down signal detection apparatus
CN101115151A (en) * 2007-07-10 2008-01-30 北京大学 A method for extracting video subtitles
CN102098455A (en) * 2011-01-21 2011-06-15 四川长虹电器股份有限公司 System for supporting multi-format subtitle display on television
CN103034854A (en) * 2011-09-30 2013-04-10 富士通株式会社 Image processing device and image processing method
CN103067678A (en) * 2011-10-20 2013-04-24 四川长虹电器股份有限公司 Television subtitle display method and device
CN102843603A (en) * 2012-08-17 2012-12-26 Tcl集团股份有限公司 Intelligent television and method for controlling caption thereof

Also Published As

Publication number Publication date
CN104254022A (en) 2014-12-31

Similar Documents

Publication Publication Date Title
US11696021B2 (en) Video recording device and camera function control program
US10324682B2 (en) Method, apparatus, and storage medium for controlling audio playing based on playing environment
CN106911961B (en) Multimedia data playing method and device
US20170344192A1 (en) Method and device for playing live videos
US20180151199A1 (en) Method, Device and Computer-Readable Medium for Adjusting Video Playing Progress
CN104104990B (en) Adjust the method and device of subtitle in video
CN107396177A (en) Video broadcasting method, device and storage medium
CN104104986B (en) The synchronous method and device of audio and captions
RU2621285C2 (en) Method and device of slow motion
CN104391711B (en) A kind of method and device that screen protection is set
CN105306752B (en) The method and device that generation event is reminded
CN106331338A (en) Volume adjusting method and device
CN104254022B (en) Caption presentation method and device
US20170034336A1 (en) Event prompting method and device
CN105511749A (en) Method and device for equipment control
CN105288941A (en) Treadmill speed regulating method and device
CN104779420B (en) Method for charging batteries and device
CN110798728B (en) Video playing method, device and storage medium
CN105549960B (en) Control the method and device of camera
CN107820131A (en) Share the method and device of comment information
CN105554255A (en) Operation control method and device for terminal equipment
CN106453032B (en) Information-pushing method and device, system
CN108028951A (en) Control the method and device played
CN105630655B (en) A kind of method and apparatus of prompt charging connection
CN109495765B (en) Video interception method and device

Legal Events

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