ratwithacompiler / OBS-captions-plugin

Closed Captioning OBS plugin using Google Speech Recognition
GNU General Public License v2.0
1.02k stars 69 forks source link

Caption stream starts but no text is displayed in Youtube/Facebook Live #16

Open CymaSpace opened 4 years ago

CymaSpace commented 4 years ago

First off, wow! Thank you so much for taking on this plugin. We have been waiting for years for someone to connect the dots and apply Google Voice to Text API to an OBS plugin for live streaming. The implementation is done well and will help many, many people in the Deaf & Hard-of-Hearing community!

Unfortunately we have not been able to actually get the captions to display in a Youtube or Facebook Live stream yet. Facebook Live preview appears to acknowledge that it is receiving a caption stream (when we toggle the captioning plugin on and off, the Facebook "Closed caption on/off" button in settings appears and goes away as expected) but no captions are actually displayed in the video stream.

We do get the captions working beautifully in the plugin preview, we also had no problems getting the 0.0.12 beta open captions to display as a source overlay.

Anything we can to do further help troubleshoot this?

alexdean commented 4 years ago

I would also like to see this plugin made compatible with YouTube live streaming. I have the plugin working locally, and the caption preview window shows my speech being transcribed correctly. However, when I test streaming to YouTube I do not see any subtitle options displayed in the YouTube player.

I'm unsure how to troubleshoot further. The requirements I found in YouTube documentation are here: https://support.google.com/youtube/answer/3068031

linksith commented 4 years ago

I would also like to see this implemented for YouTube and Facebook Live. It's such a simple concept and I love how it works. It worked for me when I was test streaming to Twitch, but just won't work for YouTube or Facebook. Would love to see it work with multiple platforms!

RobGibbens commented 4 years ago

I've tried using this with YouTube as well. It appears to work for a few seconds, but then the closed captioned text on YouTube stops updating. Is there anything we can do to help diagnose the problems?

CymaSpace commented 4 years ago

Developer unfortunately seems not interested in supporting anything other than Twitch despite us asking and even offering to pay for development time on this feature.

We notice that closed captions appear in the top of the video frame for Twitch and sometimes on Youtube. Unsure why this is happening.

On Tue, Jul 28, 2020 at 10:16 AM Rob Gibbens notifications@github.com wrote:

I've tried using this with YouTube as well. It appears to work for a few seconds, but then the closed captioned text on YouTube stops updating. Is there anything we can do to help diagnose the problems?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ratwithacompiler/OBS-captions-plugin/issues/16#issuecomment-665157180, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABVRPYCIMB7GRJRULHPHX6DR537TXANCNFSM4LVM3SNQ .

-- Myles de Bastion President, Board of Directors CymaSpace

Web http://www.cymaspace.org/ | Facebook http://www.facebook.com/cymaspace | Instagram http://www.instagram.com/cymaspace | Twitter http://www.twitter.com/cymaspace | Youtube http://www.youtube.com/user/CymaSpace/videos

lylebarrere commented 4 years ago

We are also having issues making it work with YouTube, but I am unsure if it is on the plugin side as both YouTube and Twitch require the same CEA-608/708 standard format so if it works on Twitch, it should work on YouTube. Has anyone had success getting YouTube to accept other sources of 608/708 captions?

lylebarrere commented 3 years ago

@ratwithacompiler I am wondering if this issue is related to the hardcoded caption display duration of two seconds that you were talking about here: https://github.com/ratwithacompiler/OBS-captions-plugin/issues/10#issuecomment-565213896.

It looks like OBS added obs_output_output_caption_text2 without that limit after your PR to expose obs_output_output_caption_text1 to scripting. Is your plugin still using obs_output_output_caption_text1? https://github.com/obsproject/obs-studio/pull/1767

I'd be happy to contribute to supporting YouTube, Facebook/Instagram and Vimeo.

jperryheun commented 3 years ago

Hi all!

I've been trying to get a captioner to work for my church's weekly livestreams of worship. While trying this, I too found that YouTube does not accept something about this plug-ins form of CEA 708/"Line 21" captions. I imagine it might be a paywall agreement with the compatible captioner softwares that YouTube list on their site.

In the last few weeks, I've found WebCaptioner to work well over YouTube's alternative captioning stream: HTTP Posts.

https://webcaptioner.com/

Currently, it's in the "experimental" phase on their site, but I've tried it for a few Sundays now. It works competently and provides transcripts at the end.

P.S. For livestreams, keep in mind it helps to add an additional 30 second delay via the YouTube Live dashboard.

Cheers,

Perry

alexdean commented 3 years ago

i've also been using webcaptioner. i put together a ruby script which receives webhooks from webcaptioner, reformats the captions into the format required by YouTube, and sends the captions along. we've used this for our streaming broadcasts for several months. https://github.com/alexdean/webcaptioner_for_youtube

jeffchittenden commented 3 years ago

i've also been using webcaptioner. i put together a ruby script which receives webhooks from webcaptioner, reformats the captions into the format required by YouTube, and sends the captions along. we've used this for our streaming broadcasts for several months. https://github.com/alexdean/webcaptioner_for_youtube

@alexdean how does one implement this solution?

jperryheun commented 3 years ago

@jeffchittenden You don't even need to code anything. YouTube allows captions over HTTP POST commands. Webcaptioner has the feature in the "Experiments" menu. You just need to provide Webcaptioner the link generated by YouTube.

YouTube Studio > Go Live > Manage > Schedule Stream > Stream Settings:

webcaptioner.com/captioner > Settings > Experiments:

I find it best to lock down the YouTube Live settings to keep the stream key and Caption Ingest URL the same.

My Settings:

Hope this helps!

jeffchittenden commented 3 years ago

@jperryheun I have been experimenting with that, also. I was a little put off by the warning it gave me when i enabled the experiment, saying it's unstable and may be discontinued, etc. Also, the translations are sometimes missing spaces, and are sometimes missing the last few words of a block. Have you experienced any issues?

I assume you're adding a 30 second delay so the text translations at least somewhat match the video?

jperryheun commented 3 years ago

I was too, but it has been stable for the 2-3 months I've worked with it. The missing spaces are a bit annoying but still readable, in my experience. I imagine that could be fixed with a few lines if we emailed support. All in all, though, It's been a solid option for my needs, as we have congregants with hearing impairments.

Yes, the normal latency and added 30 secs is for the text stream to match the video with minimal latency. I have not tried 60 seconds, but I imagine that's even better. However, the issue I found with larger added latency (even 30 seconds) is the participation element, as the pastor interacts with the congregation via Live Chat; 30 seconds seemed like a nice compromise.

x3rud commented 3 years ago

Hello there, any update on why is not working on facebook live?

willlllllio commented 3 years ago

@x3rud the captions OBS outputs are apparently not really compliant with the CEA captions spec https://github.com/obsproject/obs-studio/issues/4006, which FB and YT need and requires pretty low level knowledge to fix from what I got from the discord discussion about that

jperryheun commented 3 years ago

From what I've found, Facebook has auto-generated captions built-in. You just need to toggle a switch when scheduling. No need to deal with an external source.

In my opinion, CEA captions are not worth dealing with when streaming. YouTube can collect captions over HTTP POSTs and has done so with only one hiccough in the 6 months I have used WebCaptioner.

Thank you,

J Perry Heun Production & Post-Production Sound • • • (503) 805-5184 jperryheun.com

On Wed, Mar 31, 2021 at 8:41 AM willlllllio @.***> wrote:

@x3rud https://github.com/x3rud the captions OBS outputs are apparently not really compliant with the CEA captions spec obsproject/obs-studio#4006 https://github.com/obsproject/obs-studio/issues/4006, which FB and YT need and requires pretty low level knowledge to fix from what I got from the discord discussion about that

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ratwithacompiler/OBS-captions-plugin/issues/16#issuecomment-811166543, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQ3E34VOKFVQRUOTSF2CDT3TGM7DNANCNFSM4LVM3SNQ .

tvadi commented 2 years ago

Hi, trying to find a way to get good CEA captions out of OBS with the captions plug in.. I can stream to MPV and captions show but not sure they work anywhere else. I have ffmpeg built with libklvanc and can load the SRT stream but it continually gives: Illegal cc_count received error.. Is there anyway to fix this, CEA captions are actually crucial for us. Thanks!

tvadi commented 2 years ago

Maybe the fix is FIFO and vf_ccrepack? @ratwithacompiler , any way to add those to your plug in or is this for sure an OBS issue? I do not get the errors with the caption plug in off..

https://github.com/obsproject/obs-studio/issues/4006

ratwithacompiler commented 2 years ago

@tvadi My plugin basically just regularly calls obs_output_output_caption_text2("latest caption lines") and all the actual creating and embedding CEA captions into the video stream is fully done by OBS itself so any fixes like that would have to go into OBS itself.

tvadi commented 2 years ago

Thats kind of what I figured, thanks for confirming! I will bug devs on discord, hoping to find a fix