SebastianRask / Pocket-Plays-for-Twitch

Open source Twitch client for Android
GNU General Public License v3.0
62 stars 14 forks source link

No longer blocking ad's #34

Open sh0wst0pper opened 3 years ago

sh0wst0pper commented 3 years ago

Hi - thanks for this app, and i hope you are still developing it! For a few days now, when you load a stream you get a 'Commercial Break' at the start and then (for me at least) the video freezes, but the audio is OK. Any chance you can update the app please?

Ismaw34 commented 3 years ago

Same here, i have Turbo and sometimes im a sub on a channel, same behaviour. Please explain this.

SebastianRask commented 3 years ago

I think I messaged OP on Reddit. But basicly Twitch is injecting stream directly into the HLS stream, so filtering out the ads is very difficult. It should be possible, as the stream segments are marked, but I don't know enough about HLS streaming to actually remove/skip these segments programmatically. If you feel like you can do this, please make a fork and create a pull request. That is the power of open source.

Disqu3-mirOir-qt commented 3 years ago

idk if this can help

twitch.tv#%#(function(){if("function"==typeof fetch){var e=window.fetch;window.fetch=(a,f,...c)=>{if("string"==typeof a)if(a.includes("/access_token"))a=a.replace("player_type=site","player_type=embed");else if(a.includes("/gql")&&f&&"string"==typeof f.body&&f.body.includes("PlaybackAccessToken")){var b=JSON.parse(f.body);(null===b||void 0===b?void 0:b.variables)&&(b.variables.playerType="embed",f.body=JSON.stringify(b))}return e(a,f,...c)}}})();