Skills

Gsy Subtitle And Preview

外挂/内嵌字幕(SRT/VTT)、Exo 内嵌字幕轨、Seek 悬浮预览缩略图(VTT thumbnails)。

Install

npx skills add CarGuo/GSYVideoPlayer --skill gsy-subtitle-and-preview -g -a claude-code -y
Repository
CarGuo/GSYVideoPlayer21.5k
Category
Engineering
Updated
25d ago
License
Apache-2.0
Context cost
Lightabout 1,016 tokens
Runs scripts
No, instructions only

What it does

外挂/内嵌字幕(SRT/VTT)、Exo 内嵌字幕轨、Seek 悬浮预览缩略图(VTT thumbnails)。

gsy-subtitle-and-preview

字幕 API

顶层控制器:GSYSubtitleController。视图:GSYSubtitleView。

方法说明
new GSYSubtitleController(context, subtitleView)绑定 UI
setSources(List<GSYSubtitleSource>)一次注入多轨字幕
setSource(GSYSubtitleSource)只有一条
getSources()只读 List
selectSubtitle(String id)按 id 切换字幕,"" 或 null 关闭
setStyle(GSYSubtitleStyle)字体/描边/背景/颜色
setOffsetMs(long)音画/字幕 offset
setEnabled(boolean)开关
updatePosition(long positionMs)由 player 进度驱动
release()释放

GSYSubtitleSource 字段

见 GSYSubtitleSource:

字段说明
id唯一 id
label显示名
languageISO code
mime见 GSYSubtitleMime:text/vtt、application/x-subrip(srt)、text/plain
urihttp 或 file uri
embedded是否内嵌轨(Exo 场景)

内置解析器

Exo 内嵌字幕

Read the whole SKILL.md on GitHub

More in Engineering