mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-03 06:18:28 +01:00
added subtitle parsing stubs
This commit is contained in:
9
MediaBrowser.MediaEncoding/Subtitles/ISubtitleParser.cs
Normal file
9
MediaBrowser.MediaEncoding/Subtitles/ISubtitleParser.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
using System.IO;
|
||||
|
||||
namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
public interface ISubtitleParser
|
||||
{
|
||||
SubtitleInfo Parse(Stream stream);
|
||||
}
|
||||
}
|
||||
17
MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs
Normal file
17
MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
public class SrtParser
|
||||
{
|
||||
public SubtitleInfo Parse(Stream stream)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
17
MediaBrowser.MediaEncoding/Subtitles/SsaParser.cs
Normal file
17
MediaBrowser.MediaEncoding/Subtitles/SsaParser.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
public class SsaParser
|
||||
{
|
||||
public SubtitleInfo Parse(Stream stream)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
22
MediaBrowser.MediaEncoding/Subtitles/SubtitleInfo.cs
Normal file
22
MediaBrowser.MediaEncoding/Subtitles/SubtitleInfo.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
public class SubtitleInfo
|
||||
{
|
||||
public List<SubtitleTrackEvent> TrackEvents { get; set; }
|
||||
|
||||
public SubtitleInfo()
|
||||
{
|
||||
TrackEvents = new List<SubtitleTrackEvent>();
|
||||
}
|
||||
}
|
||||
|
||||
public class SubtitleTrackEvent
|
||||
{
|
||||
public string Id { get; set; }
|
||||
public string Text { get; set; }
|
||||
public long StartPositionTicks { get; set; }
|
||||
public long EndPositionTicks { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user