Loading ios/RCTVideo.h +1 −0 Changes for ios/RCTVideo.h: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ @property (nonatomic, copy) RCTBubblingEventBlock onVideoBuffer; @property (nonatomic, copy) RCTBubblingEventBlock onVideoError; @property (nonatomic, copy) RCTBubblingEventBlock onVideoProgress; @property (nonatomic, copy) RCTBubblingEventBlock onBandwidthUpdate; @property (nonatomic, copy) RCTBubblingEventBlock onVideoSeek; @property (nonatomic, copy) RCTBubblingEventBlock onVideoEnd; @property (nonatomic, copy) RCTBubblingEventBlock onTimedMetadata; Loading ios/RCTVideo.m +4 −2 Changes for ios/RCTVideo.m: 4 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -592,8 +592,10 @@ static int const RCTVideoUnset = -1; - (void)handleAVPlayerAccess:(NSNotification *)notification { AVPlayerItemAccessLog *accessLog = [((AVPlayerItem *)notification.object) accessLog]; AVPlayerItemAccessLogEvent *lastEvent = accessLog.events.lastObject; float lastEventNumber = lastEvent.indicatedBitrate; RCTLog(@"Switch indicatedBitrate from: %f to: %f", lastEvent.observedBitrate, lastEvent.indicatedBitrate); if (self.onBandwidthUpdate) { self.onBandwidthUpdate(@{@"bitrateEstimate": [NSNumber numberWithFloat:(lastEvent.observedBitrate/1000)]}); } } - (void)playbackStalled:(NSNotification *)notification Loading ios/RCTVideoManager.m +1 −0 Changes for ios/RCTVideoManager.m: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ RCT_EXPORT_VIEW_PROPERTY(onVideoLoad, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoBuffer, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoError, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoProgress, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onBandwidthUpdate, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoSeek, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoEnd, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onTimedMetadata, RCTBubblingEventBlock); Loading Loading
ios/RCTVideo.h +1 −0 Changes for ios/RCTVideo.h: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ @property (nonatomic, copy) RCTBubblingEventBlock onVideoBuffer; @property (nonatomic, copy) RCTBubblingEventBlock onVideoError; @property (nonatomic, copy) RCTBubblingEventBlock onVideoProgress; @property (nonatomic, copy) RCTBubblingEventBlock onBandwidthUpdate; @property (nonatomic, copy) RCTBubblingEventBlock onVideoSeek; @property (nonatomic, copy) RCTBubblingEventBlock onVideoEnd; @property (nonatomic, copy) RCTBubblingEventBlock onTimedMetadata; Loading
ios/RCTVideo.m +4 −2 Changes for ios/RCTVideo.m: 4 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -592,8 +592,10 @@ static int const RCTVideoUnset = -1; - (void)handleAVPlayerAccess:(NSNotification *)notification { AVPlayerItemAccessLog *accessLog = [((AVPlayerItem *)notification.object) accessLog]; AVPlayerItemAccessLogEvent *lastEvent = accessLog.events.lastObject; float lastEventNumber = lastEvent.indicatedBitrate; RCTLog(@"Switch indicatedBitrate from: %f to: %f", lastEvent.observedBitrate, lastEvent.indicatedBitrate); if (self.onBandwidthUpdate) { self.onBandwidthUpdate(@{@"bitrateEstimate": [NSNumber numberWithFloat:(lastEvent.observedBitrate/1000)]}); } } - (void)playbackStalled:(NSNotification *)notification Loading
ios/RCTVideoManager.m +1 −0 Changes for ios/RCTVideoManager.m: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ RCT_EXPORT_VIEW_PROPERTY(onVideoLoad, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoBuffer, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoError, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoProgress, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onBandwidthUpdate, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoSeek, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onVideoEnd, RCTBubblingEventBlock); RCT_EXPORT_VIEW_PROPERTY(onTimedMetadata, RCTBubblingEventBlock); Loading