Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug反馈:开启load more danmaku后弹幕重复 及两个功能建议 #31

Closed
Think0508 opened this issue Oct 25, 2024 · 9 comments · Fixed by #89
Closed

bug反馈:开启load more danmaku后弹幕重复 及两个功能建议 #31

Think0508 opened this issue Oct 25, 2024 · 9 comments · Fixed by #89
Assignees
Labels
enhancement New feature or request

Comments

@Think0508
Copy link

例如:开启load more danmaku后,《监狱学园》的第一集就会出现类似问题,如截图。
c9bfb674-671f-4fd2-a058-2bd7c55f90c1
这种问题并非总能复现。
例如:同样设置下,《孤独摇滚》就没有出现弹幕重复问题。
猜测原因:第三方弹幕库 与 弹弹play的弹幕库 会有重复,需要考虑进一步去重。

另外,有两个特性不知是否方便支持?

1.“通过url加载弹幕”功能,不知是否方便加一个“下载xml弹幕到本地”及“自动下载弹幕到本地”的功能。
这是因为,假设用户每次都要看某个视频,那么现在他每次都要去找那个url并导入。
特别是对于《哈利·波特》电影这样的系列视频,每次观看都需一个个手动导入。
对于无法自动匹配弹幕的视频,在手动加载url后,能下载弹幕到本地、自动下载并加载,应当体验更好。

2.自动简繁转换弹幕。
来自巴哈的弹幕多数为繁体,当弹幕多时,简繁混杂,十分累眼睛。
在弹弹play上有类似功能。
是否可以考虑,设置一个类似功能,将弹幕的xml加载后,若开关为simplified/traditional,则转换弹幕为简体/繁体?

Tony15246 added a commit that referenced this issue Oct 25, 2024
@Tony15246
Copy link
Owner

Tony15246 commented Oct 25, 2024

我添加了了一个可配置选项,在uosc_danmaku.conf配置文件中添加如下配置,重复弹幕将不会重复显示

blockmode=REPEAT

可以克隆最新代码试一下,看看弹幕重复问题是否还存在

@Think0508
Copy link
Author

我添加了了一个可配置选项,在uosc_danmaku.conf配置文件中添加如下配置,重复弹幕将不会重复显示

blockmode=REPEAT

可以克隆最新代码试一下,看看弹幕重复问题是否还存在

反馈:问题已解决,已用几集试看,均无重复弹幕。非常感谢。

@Tony15246
Copy link
Owner

2.自动简繁转换弹幕。

这个功能不是完全没法实现,但是实现效果会很鸡肋😂,因为支持简繁转换要依赖弹弹play本身的api。而弹弹play本身也只有/api/v2/comment/{episodeId}这个弹幕获取api支持简繁转换功能。也就是说所有使用了的弹弹play的其他api获取弹幕的功能都没法进行简繁转换。比如说开启load more danmaku后,就无法进行简繁转换。

如果不依赖弹弹play的api的话,倒是可以为所有弹幕实现统一的简繁转换。但是需要依赖其他第三方工具或者lua原生实现简繁转换功能,感觉一时半会儿之内不是很容易研究出来。

@Tony15246
Copy link
Owner

1.“通过url加载弹幕”功能,不知是否方便加一个“下载xml弹幕到本地”及“自动下载弹幕到本地”的功能。

可以更具体地描述一下使用情形吗?我没有太看明白这个需求是什么意思。

去找那个url并导入是指使用从弹幕源向当前弹幕添加新弹幕内容功能,通过url导入弹幕是吗?所以,你的意思是希望通过url源添加的弹幕和视频能够关联起来,每次播放这个视频的时候都自动加载之前添加过的url源的弹幕是吗?

@Think0508
Copy link
Author

1.“通过url加载弹幕”功能,不知是否方便加一个“下载xml弹幕到本地”及“自动下载弹幕到本地”的功能。

可以更具体地描述一下使用情形吗?我没有太看明白这个需求是什么意思。

去找那个url并导入是指使用从弹幕源向当前弹幕添加新弹幕内容功能,通过url导入弹幕是吗?所以,你的意思是希望通过url源添加的弹幕和视频能够关联起来,每次播放这个视频的时候都自动加载之前添加过的url源的弹幕是吗?

感谢回复,辛苦。2我没有问题了。

1的情形正如您所描述的,是 从弹幕源向当前弹幕添加新弹幕内容 的功能。

使用实例:

我下载了哈利波特系列的七部电影,想要在弹幕环境下观看。
它不会与Bilibili的网址自动关联。
于是,我的观看体验就变成了:

打开第一部;
点击从弹幕源添加弹幕,手动寻找网址回mpv粘贴;
看完,播放第二部;
再次手动寻找另一个网址,回来粘贴;
……
重复七次。

问题的核心是,由于手动一个个寻找粘贴的弹幕xml不会(自动)保存到本地,当用户做完一轮后,下次想看电影,就不得不重复进行上述流程,再次手动寻找并导入网址。

考虑到这个,我猜想合理的解决方案是:
在“从弹幕源向当前弹幕添加新弹幕内容”的已有功能上,增加“下载该弹幕到本地”及“自动下载找到的弹幕”的开关。

这样,使用体验就会变成:只需手动寻找一次网址。之后再打开电影,就能自动加载已取回本地的、此前手动匹配的弹幕。

@Tony15246
Copy link
Owner

这样,使用体验就会变成:只需手动寻找一次网址。之后再打开电影,就能自动加载已取回本地的、此前手动匹配的弹幕。

我明白你的需求了。我计划把这个功能做成对自动弹幕加载功能的补充,当用户使用从弹幕源向当前弹幕添加新弹幕内容功能时,记录本地视频文件名以及弹幕源的url并进行关联。下次播放同一个视频的时候将会搜索记录中相关联的弹幕源,并自动加载该弹幕源的弹幕。

我找时间实现一下这个功能。

@Tony15246 Tony15246 added the enhancement New feature or request label Oct 25, 2024
@Tony15246 Tony15246 self-assigned this Oct 25, 2024
Tony15246 added a commit that referenced this issue Oct 26, 2024
Tony15246 added a commit that referenced this issue Oct 26, 2024
@Tony15246
Copy link
Owner

Tony15246 commented Oct 26, 2024

关联弹幕源并自动加载功能已实现,使用方法是在uosc_danmaku.conf配置文件中添加如下配置

add_from_source=yes

可以克隆最新代码试一下,如无问题此issue将关闭

@Think0508
Copy link
Author

关联弹幕源并自动加载功能已实现,使用方法是在uosc_danmaku.conf配置文件中添加如下配置

add_from_source=yes

可以克隆最新代码试一下,如无问题此issue将关闭

反馈:无问题,可以正常实现功能。

@Tony15246
Copy link
Owner

OK👌

@Tony15246 Tony15246 pinned this issue Nov 3, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
Tony15246 added a commit that referenced this issue Dec 7, 2024
@Tony15246 Tony15246 linked a pull request Dec 8, 2024 that will close this issue
Tony15246 added a commit that referenced this issue Dec 8, 2024
@Tony15246 Tony15246 unpinned this issue Dec 8, 2024
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
dyphire pushed a commit to dyphire/uosc_danmaku that referenced this issue Jan 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants