All Projects → asticode → Go Astisub

asticode / Go Astisub

Licence: mit
Manipulate subtitles in GO (.srt, .ssa/.ass, .stl, .ttml, .vtt (webvtt), teletext, etc.)

Programming Languages

go
31211 projects - #10 most used programming language
golang
3204 projects

Projects that are alternatives of or similar to Go Astisub

VTT-to-SRT-Converter
Convert WebVTT subtitles to SubRip.
Stars: ✭ 29 (-90.49%)
Mutual labels:  subtitle, srt
Translate Subtitle File
🤖 字幕组机翻小助手 - 【功能1:翻译字幕文件】 .srt .ass .vtt 【功能2:语音转文字】(拖入视频或音频识别出字幕) (最新版 v4.1.0 更新时间2021年2月23号) 可配置12家翻译服务商,如谷歌,百度,腾讯,彩云,IBM,Azure,Amazon等(可配置6家语音服务商:阿里云,讯飞,腾讯云,IBM,Azure,Amazon )优点:1. 可以用多家服务商,2. 自己配 API Key 用自己账户的免费额度,比如腾讯每月有500万字符的免费翻译额度,IBM 500分钟的语音转文字免费额度(tern.best 那个域名过期了我不想续费了)
Stars: ✭ 579 (+89.84%)
Mutual labels:  srt, subtitle
Netflix To Srt
Rip, extract and convert subtitles to .srt closed captions from .xml/dfxp/ttml and .vtt/WebVTT (e.g. Netflix, YouTube)
Stars: ✭ 387 (+26.89%)
Mutual labels:  srt, subtitle
Subplayer
📝 SubPlayer is a online subtitle editor
Stars: ✭ 517 (+69.51%)
Mutual labels:  srt, subtitle
Srt
A simple library for parsing, modifying, and composing SRT files.
Stars: ✭ 210 (-31.15%)
Mutual labels:  srt, subtitle
Fasubrip
FaSubrip autodetects and converts encoding of farsi (persian) subrip files. with additional functionalities.
Stars: ✭ 22 (-92.79%)
Mutual labels:  srt, subtitle
Ffsubsync
Automagically synchronize subtitles with video.
Stars: ✭ 5,167 (+1594.1%)
Mutual labels:  srt, subtitle
pysub-parser
Library for extracting text and timestamps from multiple subtitle files (.ass, .ssa, .srt, .sub, .txt).
Stars: ✭ 40 (-86.89%)
Mutual labels:  subtitle, srt
Captioning
A collection of tools made to help you create and edit subtitles in different formats (Subrip, WebVTT, Substation Alpha...)
Stars: ✭ 197 (-35.41%)
Mutual labels:  srt, subtitle
Penguin Subtitle Player
An open-source, cross-platform standalone subtitle player
Stars: ✭ 194 (-36.39%)
Mutual labels:  srt, subtitle
Subtitle.js
Stream-based library for parsing and manipulating subtitle files
Stars: ✭ 234 (-23.28%)
Mutual labels:  srt, subtitle
quickSRT
generating .srt(subtitles) in After Effects
Stars: ✭ 24 (-92.13%)
Mutual labels:  subtitle, srt
iptvx
IPTV player and streamer for Linux that allows to play any stream that LibVLC can play, offers an overlay based on WebKit using HTML5, JavaScript and CSS and uses XMLTV data for EPG information. It allows the playback of URLs, files and can grab URLs from shell scripts. XMLTV EPG data can be downloaded from URLs or grabbed from shell scripts.
Stars: ✭ 65 (-78.69%)
Mutual labels:  subtitle
streamdelay
A delay + dump button for live streams, allowing screening and redaction of explict content.
Stars: ✭ 31 (-89.84%)
Mutual labels:  srt
stlkrn
C++ STL in the Windows Kernel with C++ Exception Support
Stars: ✭ 216 (-29.18%)
Mutual labels:  stl
Subsync
Automatically download subtitles for your movies
Stars: ✭ 270 (-11.48%)
Mutual labels:  subtitle
OOP-In-CPlusPlus
An Awesome Repository On Object Oriented Programming In C++ Language. Ideal For Computer Science Undergraduates, This Repository Holds All The Resources Created And Used By Me - Code & Theory For One To Master Object Oriented Programming. Filled With Theory Slides, Number Of Programs, Concept-Clearing Projects And Beautifully Explained, Well Doc…
Stars: ✭ 27 (-91.15%)
Mutual labels:  stl
sgi-stl-docs
Standard template library (STL) documentation from SGI. (Mirror)
Stars: ✭ 36 (-88.2%)
Mutual labels:  stl
yangwebrtc
Webrtc SDK for C++
Stars: ✭ 257 (-15.74%)
Mutual labels:  srt
HandySub
Download Subtitle from Subscene and other sources
Stars: ✭ 42 (-86.23%)
Mutual labels:  subtitle

GoReportCard GoDoc Travis Coveralls

This is a Golang library to manipulate subtitles.

It allows you to manipulate srt, stl, ttml, ssa/ass, webvtt and teletext files for now.

Available operations are parsing, writing, syncing, fragmenting, unfragmenting, merging and optimizing.

Installation

To install the library and command line program, use the following:

go get -u github.com/asticode/go-astisub/...

Using the library in your code

WARNING: the code below doesn't handle errors for readibility purposes. However you SHOULD!

// Open subtitles
s1, _ := astisub.OpenFile("/path/to/example.ttml")
s2, _ := astisub.ReadFromSRT(bytes.NewReader([]byte("00:01:00.000 --> 00:02:00.000\nCredits")))

// Add a duration to every subtitles (syncing)
s1.Add(-2*time.Second)

// Fragment the subtitles
s1.Fragment(2*time.Second)

// Merge subtitles
s1.Merge(s2)

// Optimize subtitles
s1.Optimize()

// Unfragment the subtitles
s1.Unfragment()

// Write subtitles
s1.Write("/path/to/example.srt")
var buf = &bytes.Buffer{}
s2.WriteToTTML(buf)

Using the CLI

If astisub has been installed properly you can:

  • convert any type of subtitle to any other type of subtitle:

      astisub convert -i example.srt -o example.ttml
    
  • fragment any type of subtitle:

      astisub fragment -i example.srt -f 2s -o example.out.srt
    
  • merge any type of subtitle into any other type of subtitle:

      astisub merge -i example.srt -i example.ttml -o example.out.srt
    
  • optimize any type of subtitle:

      astisub optimize -i example.srt -o example.out.srt
    
  • unfragment any type of subtitle:

      astisub unfragment -i example.srt -o example.out.srt
    
  • sync any type of subtitle:

      astisub sync -i example.srt -s "-2s" -o example.out.srt
    

Features and roadmap

  • [x] parsing
  • [x] writing
  • [x] syncing
  • [x] fragmenting/unfragmenting
  • [x] merging
  • [x] ordering
  • [x] optimizing
  • [x] .srt
  • [x] .ttml
  • [x] .vtt
  • [x] .stl
  • [x] .ssa/.ass
  • [x] .teletext
  • [ ] .smi
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].