151 Commits

Author SHA1 Message Date
Krzysztof Moch 9eb5502076 chore: rework examples (#4225)
* remove unused examples

* init bare example with test app

* add react-native-video

* add test app suport in expo plugin

* expo plugin: skip keys that are already in pod file

* fix podfile

* add src files

* fix metro config

* finalize react native test app configuration

* init expo example

* remove old examples

* add guide for example

* Add link to examples apps in docs

* adopt bare example to CI tests

* update CI workflows

* CI build lib after node_modules install

* fix examples readme

* fix iOS CI

* Add Example for DRM

* Update examples/README.md

* fix links

* update examples README

* sync example code

* update README
2024-10-20 20:04:02 +02:00
Olivier Bouillet d86adc52f3 Chore: rework ad props (#4220)
* fix: move ad configuration in source
2024-10-10 23:53:39 +02:00
Olivier Bouillet 9a3fcda3b8 feat: add setSource API function fix ads playback (#4185)
* feat: add setSource API function fix ads playback
2024-10-10 22:59:41 +02:00
Seyed Mostafa Hasani 149924ffcb feat(android): add live video label configuration (#4190) 2024-10-02 23:37:18 +02:00
Olivier Bouillet 3ecf324bb3 fix(android): bad rotation handling (#4205) 2024-09-29 20:48:44 +02:00
Olivier Bouillet 0c6b47f42c docs: remove desugaring section as no more need on media3 1.4.1 (#4206) 2024-09-29 20:46:11 +02:00
Krzysztof Moch b11f05f175 fix(tvos): typo (#4204)
* fix(tvos): typo

* lint
2024-09-28 16:39:09 +02:00
Olivier Bouillet c96f7d41f3 chore(sample): fix default track identification and add audio tracks selection option (#4184) 2024-09-20 16:26:20 +02:00
Olivier Bouillet 6fedca0df7 chore(sample): upgrade sample expo version (#4179) 2024-09-19 13:51:24 +02:00
Olivier Bouillet 835186a321 fix(JS): improve loader api to allow function call instead of component (#4171) 2024-09-17 15:58:47 +02:00
Olivier Bouillet 24d90e9ec8 chore(android): move contentStartTime into source prop (#4160) 2024-09-14 19:53:54 +02:00
Olivier Bouillet 84a27f3d9f fix: refactor side loaded text tracks management (#4158)
* fix: refactor side loaded text tracks management

More textTracks in source.
android/ios: ensure text tracks are not selected by default
android/ios make textTrack field not nullable
clean up doc
check compatibility with the old api
Add comments on deprecated JS apis
Apply API change on basic sample

* chore: fix linter

* fix(ios): fix build with caching & remove warnings
2024-09-13 10:50:33 +02:00
Olivier Bouillet 809a730198 fix(ios): ensure onBandwidthUpdate is reported only when value change (#4149)
* fix(ios): ensure onBandwidthUpdate is reported only when value change

* chore: fix PodFile.lock
2024-09-06 15:11:12 +02:00
Olivier Bouillet e18769ab3a fix(sample): remove warning on ios with NavigationBar (#4148)
* fix(sample): remove warning on ios with NavigationBar
2024-09-06 09:45:24 +02:00
Olivier Bouillet 9707081ab9 Chore/rework fullscreen configuration (#4142)
* feat(android): handle navigation bar status in full-screen mode
* chore: update default value of prop
* chore(android): rework fullscreen configuration

---------

Co-authored-by: mostafahasani <seyedmostafahassani@gmail.com>
2024-09-04 09:53:30 +02:00
Olivier Bouillet d6bae3cd07 fix(ios): fix onBandwidth update event (old ios api is deprecated and doens't work) (#4140) 2024-09-03 15:33:43 +02:00
Olivier Bouillet 308447a5ba Fix/track selection by title (#4129)
* chore(sample): make track selection by title possible

* fix(android): fix test for track selection by title
2024-09-02 19:10:39 +02:00
Olivier Bouillet fbe570d62f Fix/allow text track selection by index (#4124)
* fix(ios): ensure behavior is correct with empty text track list
* fix(ios): add index to text tracks reported
2024-09-02 17:01:39 +02:00
Olivier Bouillet 2fa6c43615 fix(android): add subtitleStyle.subtitlesFollowVideo prop to control subtitles positionning (#4133)
* fix(android): add subtitleStyle.subtitlesFollowVideo prop to control subtitles positionning
* docs: add new prop description
* docs: add supported platform for subtitleStyle
* chore: use constructor instead of parse
2024-09-02 16:13:06 +02:00
Olivier Bouillet 3a32d67087 fix(ios): ensure behavior is correct with empty text track list (#4123)
* fix(ios): ensure behavior is correct with empty text track list
2024-09-02 15:40:38 +02:00
Olivier Bouillet 7a2b4014f4 fix(sample): update dependencies to fix local asset playback (#4121)
* fix(sample): align dependencies and fix local asset playback
2024-09-02 15:40:10 +02:00
Olivier Bouillet fb3c0da6af chore(sample): additionnal sample cleanup (#4122)
* chore: move MultiValueControl & toggleControl to component
* fix(sample): fix import / export to avoid circular deps
* chore(sample): fix warning
2024-08-31 18:32:32 +02:00
Krzysztof Moch 38aa2b057a fix(ios): override source metadata with custom metadata (#4050)
* fix(ios): override source metadata with custom metadata

* lint code
2024-08-05 11:59:49 +02:00
Kamil Moskała adbd06e2df feat: add ability to define poster props as Image type and render poster as custom component (#3972) 2024-07-22 22:38:35 +02:00
Olivier Bouillet ffbc977ff9 fix(sample): boot failure on emulator (#4016)
* fix: disable coreLibraryDesugaringEnabled by default
2024-07-18 22:22:58 +02:00
Kamil Moskała 7611da155f chore(sample): refactor sample code to follow rn best practices (#3990)
Co-authored-by: Olivier Bouillet <62574056+freeboub@users.noreply.github.com>
2024-07-15 23:29:23 +02:00
Kamil Moskała 38bcfa2f6a chore(example): update MultiValueControl types (#4003) 2024-07-15 10:13:21 +02:00
Seyed Mostafa Hasani 39cf477ceb fix(example/basic): select resizeMode (#3989)
* fix(example/basic): select resizeMode

* chore: refactor the onResizeModeSelected function
2024-07-12 13:42:36 +02:00
Olivier Bouillet 66dcf32b56 refactor: move view type and drm in source (#3867)
* perf: ensure we do not provide callback to native if no callback provided from app

* chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size

* chore: improve issue template

* fix(android): avoid video view flickering at playback startup

* chore(android): refactor DRM props into a dedicated class

* Update android/src/main/java/com/brentvatne/exoplayer/ReactExoplayerView.java

* chore: fix linter

* fix: ensure drm prop is correctly cleaned

* feat(android): move viewType (secure texture) & drm inside the source

The origianl behavior has been kept for interoperability, but marked as deprecated in doc

* chore: fix linter

* chore(ios): move drm prop in source like on android

* chore: fix linter

* chore: clean log

* fix: allow to disable secure View

* chore: fix viewType resolution (source value was not handled)

* chore: use contentDeepEquals instead of manual checks

* chore: fix linter

* fix: ensure player doesn't start when view is unmounted

* Fix/ensure view drop stop playback startup (#3875)

* fix: ensure player doesn't start when view is unmounted

* chore: revert change

* chore: add warning in case of invalid Surface configuration

* chore: code clean

* fix: simplify surface management

* chore: restore previous code

* chore: fix typo

* chore: code cleanup

* feat(android): add multiDrm flag support

* docs: update docs

* chore: fix ios build

* chore: fix deprecated declaration

---------

Co-authored-by: Krzysztof Moch <krzysmoch.programs@gmail.com>
2024-07-10 12:17:22 +02:00
Seyed Mostafa Hasani a3ecc0108c chore(example/basic): refactor state variable (#3949)
* refactor: basic example from class component to functional component

* refactor: toast component path

* refactor: bufferConfig prop

* refacotr: import component path

* fix: seekbar issue on iOS

* refactor: state variable

* chore: refactor overlay component according to new state structure
2024-07-08 09:54:32 +02:00
Seyed Mostafa Hasani 01a00b12ae chore: upgrade react-native & expo version in the basic example app (#3964)
* chore: upgrade react-native & expo version

* chore: update Podfile.lock
2024-07-04 14:02:05 +02:00
yungblud df29c2310d feat(fabric): updated ios podspec for implementing new architecture (#3961)
* chore: 🔥 updated FabricExample/Gemfile.lock (bundle install)

* feat: updated react-native-video.podspec for implementing new architecture

* feat: updated FabricExample/ios/Podfile.lock (pod install)

* chore: updated examples/basic Gemfile.lock (bundle install)

* chore:  updated examples/basic ios Podfile.lock (pod install)
2024-07-02 10:56:14 +02:00
Seyed Mostafa Hasani d4f1648681 refactor: basic example from class component to functional component (#3934)
* refactor: basic example from class component to functional component

* refactor: toast component path

* refactor: bufferConfig prop

* refacotr: import component path

* fix: seekbar issue on iOS
2024-06-28 11:33:10 +02:00
Olivier Bouillet a7d834a80a feat(android): allow building exoplayer from source (#3932)
* feat(android): allow to build from source code

* fix(android): allow to build plugin from source
2024-06-25 13:20:12 +02:00
Olivier Bouillet 91d27a6009 feat: add plugins management (#3909) 2024-06-25 08:55:32 +02:00
Olivier Bouillet c1c7a056f1 chore: move sample to expo (#3880)
* perf: ensure we do not provide callback to native if no callback provided from app

* chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size

* chore: improve issue template

* fix(android): avoid video view flickering at playback startup

* fix: ensure player doesn't start when view is unmounted

* chore: move basic sample to expo

* Update examples/basic/package.json

Co-authored-by: Krzysztof Moch <krzysmoch.programs@gmail.com>

* chore: use last expo version

* chore: fix podfile

---------

Co-authored-by: Krzysztof Moch <krzysmoch.programs@gmail.com>
2024-06-20 11:58:55 +02:00
Olivier Bouillet 264b57aa2e fix(android): allow chunk less preparation (#3913) 2024-06-20 11:19:35 +02:00
Krzysztof Moch 2d793dbde1 fix(ios): missing notification controls when enabled from start (#3898) 2024-06-12 11:54:22 +02:00
Seyed Mostafa Hasani 3a4a13011a chore: add setFullScreen to component's ref (#3855)
* chore: add setFullScreen to component's ref and remove presentFullscreenPlayer & dismissFullscreenPlayer
2024-06-10 22:41:26 +02:00
Olivier Bouillet a604cd750a chore(sample): clean log in sample (#3868) 2024-05-31 23:32:20 +02:00
Olivier Bouillet bdf3e556d8 fix(android): refactor source, fix random DRM issue and crop start on local asset (#3835)
* fix: refactor source parameter parsing

Also fix a side issue when using a local file cropping props were not applied
Also fix random DRM issue by refactoring initializePlayerSource https://github.com/TheWidlarzGroup/react-native-video/issues/3082

* chore: restore metadata checks before appling them
2024-05-30 08:53:49 +02:00
Olivier Bouillet e23e02b359 chore(sample): review seeker in sample (#3787) 2024-05-28 09:33:21 +02:00
lovegaoshi c2a14240ad fix(android): android cache header (#3832)
* fix: android cache header
2024-05-28 09:29:21 +02:00
Krzysztof Moch cd28d370d2 fix(ios): don't crash app if view wasn't found (#3841)
* fix(ios): don't crash app if view wasn't found

* lint code
2024-05-27 09:22:22 +02:00
Olivier Bouillet cad5c4624c fix(android)!: rework video tracks management (#3778)
* fix: fix crash when invalid index type is provided and minor clean up
* fix: review video track management. Fix index support and rework string vs int in tracks management
* fix: ABR track selection check
* fix: split track selector in sample and lint code
* fix: ensure we don't report null fields
* chore: improve tracks displayed
* chore: start moving to selection by index only
2024-05-22 14:01:55 +02:00
Olivier Bouillet dbd7d7aa2c chore(example/basic): add mute state button (#3809) 2024-05-22 13:58:47 +02:00
Olivier Bouillet e16730de11 fix(android): implement live configuration management (#3792)
* perf: ensure we do not provide callback to native if no callback provided from app

* chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size

* chore: improve issue template

* fix(android): avoid video view flickering at playback startup

* feat(android): implement live buffer configuration

* chore: fix linter
2024-05-20 16:18:20 +02:00
Olivier Bouillet d716e1ab2a chore(android): improve exoplayer logs (#3780)
* perf: ensure we do not provide callback to native if no callback provided from app

* chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size

* chore: improve issue template

* fix(android): avoid video view flickering at playback startup

* fix: improve debuging display and enable it in the sample
2024-05-17 15:10:37 +02:00
Olivier Bouillet 8a57b127d0 chore(example/basic): upgrade sample react native version (#3776)
* perf: ensure we do not provide callback to native if no callback provided from app

* chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size

* chore: improve issue template

* fix(android): avoid video view flickering at playback startup

* chore: upgrade sample react native version and dependancies
2024-05-17 15:09:42 +02:00
Krzysztof Moch b3f08f6c99 fix(ios): call onLoadStart earlier (#3750) 2024-05-13 21:32:51 +02:00