弹幕文件
弹幕文件可以在
https://api.bilibili.com/x/v1/dm/list.so?oid={oid/cid}https://comment.bilibili.com/{oid/cid}.xmlhttps://api.bilibili.com/x/v2/dm/history?type=1&oid={oid/cid}&date={yyyy-mm-dd}
下载
注:cid 可以在 https://www.bilibili.com/widget/getPageList?aid={aid/mid} 获取
弹幕文件格式为 xml,结构如下:
1 | Xml |
弹幕类型
弹幕类型由 type 和 pool 决定type 取值为 [14-79],pool 取值为 [0-2]
弹幕类型如下:
| pool\type | 1 | 4 | 5 | 6 | 7 | 9 |
|---|---|---|---|---|---|---|
| 0 | 滚动弹幕 | 底部弹幕 | 顶部弹幕 | 逆向弹幕 | 特殊弹幕 (1) | / |
| 1 | / | / | / | / | 精确弹幕 (2) | / |
| 2 | / | / | / | / | / | BAS 弹幕 (3) |
特殊弹幕格式
[{x1(0-1)|(px)},{y1},"{Aplha0(0-1)}-{Alpha1}",{Lifetime},"{Text}",{Z_Rotation},{Y_Rotation},{x2},{y2},{Move_Time(ms)},{Delay_Time(ms)},{Outline[01]},"{Fontname}",{Linear_Speedup[01]}[,"SVG_Path"]][{x1(0-1)|(px)},{y1},"{Aplha0(0-1)}-{Alpha1}",{Lifetime},"{Text}",{Z_Rotation},{Y_Rotation},{x2},{y2},{Move_Time(ms)},{Delay_Time(ms)},{Outline[01]},"{Fontname}",{Linear_Speedup(Bool)}]- B 站官方 BAS 文档