forked from MediaBrowser/Emby
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixes MediaBrowser#674 - Support converting subtitles to webvtt
- Loading branch information
1 parent
67ae275
commit a47912e
Showing
18 changed files
with
726 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,21 @@ | ||
using System; | ||
using System.IO; | ||
using System.IO; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
|
||
namespace MediaBrowser.Controller.MediaEncoding | ||
{ | ||
public interface ISubtitleEncoder | ||
{ | ||
Task<Stream> ConvertTextSubtitle(String stream, | ||
Task<Stream> ConvertSubtitles( | ||
Stream stream, | ||
string inputFormat, | ||
string outputFormat, | ||
CancellationToken cancellationToken); | ||
|
||
Task<Stream> GetSubtitles(string itemId, | ||
string mediaSourceId, | ||
int subtitleStreamIndex, | ||
string outputFormat, | ||
CancellationToken cancellationToken); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,16 @@ | ||
using System.IO; | ||
using System.Threading; | ||
|
||
namespace MediaBrowser.MediaEncoding.Subtitles | ||
{ | ||
public interface ISubtitleParser | ||
{ | ||
SubtitleTrackInfo Parse(Stream stream); | ||
/// <summary> | ||
/// Parses the specified stream. | ||
/// </summary> | ||
/// <param name="stream">The stream.</param> | ||
/// <param name="cancellationToken">The cancellation token.</param> | ||
/// <returns>SubtitleTrackInfo.</returns> | ||
SubtitleTrackInfo Parse(Stream stream, CancellationToken cancellationToken); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.