-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Feat/media3 newarch #2478
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
base: main
Are you sure you want to change the base?
Feat/media3 newarch #2478
Conversation
Node 22 has entered LTS as of October 2024
example: fix
Brings in media3 & android-auto functionalities from https://github.com/lovegaoshi/react-native-track-player, leaving out widget & audio fading functionalities
- show jump backward & forward buttons in notification - remove compactCapabilities - rename BaseAudioPlayer#player to BaseAudioPlayer#forwardingPlayer
when can we expect this pr to be approved? |
It's working for me, i had to remove
|
Ok, yeah I can also reproduce the same crash when calling |
Checked out a few different streaming radios and some seem to not be working on android. Example of streams that work : https://icecast.walmradio.com:8443/classic, https://mangoradio.stream.laut.fm/mangoradio Example of streams that don't : https://airhlspush.pc.cdn.bitgravity.com/httppush/hlspbaudio005/hlspbaudio005_Auto.m3u8, http://stream.live.vc.bbcmedia.co.uk/bbc_world_service |
Alright, used these steps, and now the streams load except for the m3u stream. await TrackPlayer.reset();
await TrackPlayer.load(track);
await TrackPlayer.play(); |
I have a strange issue with notification center on Android. It works perfect with I used the same options await TrackPlayer.updateOptions({
android: {
appKilledPlaybackBehavior: DefaultAudioServiceBehaviour,
},
capabilities: [
Capability.Play,
Capability.Pause,
Capability.SkipToNext,
Capability.SkipToPrevious,
Capability.JumpForward,
Capability.JumpBackward,
],
compactCapabilities: [
Capability.Play,
Capability.Pause,
Capability.SkipToNext,
],
progressUpdateEventInterval: 10,
}); |
Hello Guys, I would like to help and test it on expo custom dev, but the only way i know to install a library is with npm install or npx expo install.. ..any clue how to replace my RNTP 4 by this what seems to be a nice update ? ;) |
I've created an npm lib to use till next update, here url https://www.npmjs.com/package/@vmsilva/react-native-track-player |
Using this in my app running Expo 53 and works great with the new architecture, great work! I have one question about this commit though: b11736b It removes both the code emitting
I believe this might have been an unintended change, but not sure :) |
Thanks a lot for the npm, Obrigado ;) !!! I have installed it without problem... ...altought I use the event "playback-metadata-received" Is there a reason why it hasn't been implemented in this package ? Or did I miss something ? => Ok, i understand "playback-metadata-received" was already deprecated in RNTP 4.. ..but was still working on Expo51, but not anymore on 53 ?!?! For my program, not getting metadata (artist, song, artwork) makes it useless... :( Any idea how to get these information ?? I use :
|
Is it intended, that |
Hi ! It seems great !! Not sure to fully understand what you have done. I have the same problem... |
Incase it helps someone else... Spent hours working out why I couldn't pause from the android system bar drawer. Got AI involved. We made a mess of it. Got there in the end though - I needed to add an event for RemotePlayPause which I don't see in the docs or codebase anywhere. service.js
This MAY not be specific to this new media3-newarch patch, but it's the one I'm using... |
|
@ngambmicheal @doughsay , I've confirmed the issue with EDIT: the issue seems to be related to the custom |
Hi, I noticed that the following event listeners are not working as expected: TrackPlayer.addEventListener(Event.RemotePause, () => { ... }); They don't seem to be triggered when interacting with the system media controls. (play/pause buttons) |
See my message above. I think you need to use PlayPause |
@ngambmicheal @doughsay I believe that 349eff0 should fix your issue. Please test and LMK. |
@deveshp , I think there's likely some errors with your streams. All the streams we have configured in the test app are working like they have prior to this change. You might try debugging the sources themselves for issues, and also testing them in the |
Events on playback service doesn't work anymore, i used Event.PlaybackActiveTrackChanged.
|
...also doesn't work. I'm using react native CLI and tested it on Android 15 |
a3528d2
to
f3fc4d5
Compare
Unfortunately no, it seems to still crash for me when using caching. I get I've also since noticed that several of the remote events no longer fire (on Android; iOS untested). Specifically I'm seeing |
If you're getting the crash still I'd recommend double checking that you've pull down the latest version of the branch (it's been rebased so you'll need to do a reset). I'm no longer able to reproduce this issue after my recent changes, so further investigation will require new information.
I'll take a look at this. EDIT: I've confirmed the issue with Remote events not firing. |
TODO:
[email protected]