diff options
author | Underground78 <underground78@users.sourceforge.net> | 2012-09-18 17:06:13 +0400 |
---|---|---|
committer | Underground78 <underground78@users.sourceforge.net> | 2012-09-18 18:04:40 +0400 |
commit | ac55b8ba535767639b117aea65fb19348e919224 (patch) | |
tree | dc49023b503b10ec80b9ffa005a210150c4c6332 /src/filters/parser/MpegSplitter | |
parent | 4e9e0ae033d038839a9455db5b0f1def670e1417 (diff) |
MPEG Splitter: Don't output the fake "No subtitle" track when the file contains no subtitles.
This commit fixes ticket #2606.
Diffstat (limited to 'src/filters/parser/MpegSplitter')
-rw-r--r-- | src/filters/parser/MpegSplitter/MpegSplitterFile.cpp | 21 |
1 files changed, 5 insertions, 16 deletions
diff --git a/src/filters/parser/MpegSplitter/MpegSplitterFile.cpp b/src/filters/parser/MpegSplitter/MpegSplitterFile.cpp index 6471f4884..b86dfe3cb 100644 --- a/src/filters/parser/MpegSplitter/MpegSplitterFile.cpp +++ b/src/filters/parser/MpegSplitter/MpegSplitterFile.cpp @@ -211,22 +211,11 @@ HRESULT CMpegSplitterFile::Init(IAsyncReader* pAsyncReader) }
#endif
- // Add fake Subtitle stream ...
- if (m_type == mpeg_ts) {
- if (m_streams[video].GetCount()) {
- if (!m_bIsHdmv && m_streams[subpic].GetCount()) {
- stream s;
- s.pid = NO_SUBTITLE_PID;
- s.mt.majortype = m_streams[subpic].GetHead().mt.majortype;
- s.mt.subtype = m_streams[subpic].GetHead().mt.subtype;
- s.mt.formattype = m_streams[subpic].GetHead().mt.formattype;
- m_streams[subpic].Insert(s, this);
- } else {
- AddHdmvPGStream(NO_SUBTITLE_PID, "---");
- }
- }
- } else {
- if (m_streams[video].GetCount() && m_streams[subpic].GetCount()) {
+ // Add fake subtitle stream...
+ if (m_streams[video].GetCount() && m_streams[subpic].GetCount()) {
+ if (m_type == mpeg_ts && m_bIsHdmv) {
+ AddHdmvPGStream(NO_SUBTITLE_PID, "---");
+ } else {
stream s;
s.pid = NO_SUBTITLE_PID;
s.mt.majortype = m_streams[subpic].GetHead().mt.majortype;
|