Open adgang opened 1 year ago
tested on V6.0.0-akpha.8, issue still reproduced. can see audio track in VLC, no audio track in RNV sample ios
@freeboub is there any solution cause i am having the same issue for same video url.
@programmer1zero1 I checked again, I am not able to read the tracks from AVPlayer API... I don't have any easy solution for now. Maybe it is simply an AVPlayer issue :/
both : return try await asset.loadMediaSelectionGroup(for: mediaCharacteristic) and return asset?.mediaSelectionGroup(forMediaCharacteristic: mediaCharacteristic)
returns empty audio track list ... I tried:
let group = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .audible)
if #available(iOS 17.0, *) {
let group2 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .carriesVideoStereoMetadata)
} else {
// Fallback on earlier versions
}
let group3 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .describesMusicAndSoundForAccessibility)
let group4 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .dubbedTranslation)
if #available(iOS 17.0, *) {
let group5 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .enhancesSpeechIntelligibility)
} else {
// Fallback on earlier versions
}
let group6 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .languageTranslation)
let group7 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .voiceOverTranslation)
let group8 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .transcribesSpokenDialogForAccessibility)
let group9 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .visual)
let group10 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .usesWideGamutColorSpace)
let group11 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .isOriginalContent)
let group12 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .isAuxiliaryContent)
let group13 = await RCTVideoAssetsUtils.getMediaSelectionGroup(asset: asset, for: .frameBased)
I may have found an issue in the code, let me triple check (rewrite audio track management in fact...)
I can see the 2 audio tracks with :
let audioTr = asset.tracks(withMediaType: .audio)
But I am not able to restore ''full feature", mainly identify which track is selected ...
@freeboub Thank you! While I'm not entirely sure what the main issue was, it seems to be related to formatting. I've successfully created a video with multiple audio tracks, and it's working well on both Android and iOS.
@freeboub could you please implementing a track selection option in the full-screen mode of the React Native video player? I currently have this feature on iOS, but it's not available on Android. Additionally, I'm also looking for a way to add speed control for the video in full-screen mode, as this feature is present on iOS but not on Android. Your help would be greatly appreciated!
@freeboub could you please implementing a track selection option in the full-screen mode of the React Native video player? I currently have this feature on iOS, but it's not available on Android. Additionally, I'm also looking for a way to add speed control for the video in full-screen mode, as this feature is present on iOS but not on Android. Your help would be greatly appreciated!
I think another ticket already exists for this issue...
Bug
In iOS, when a video with multiple audio tracks is played and if both audio tracks are set as disposition default, then only one audio track is being considered by react-native-video for playing.
Platform
Which player are you experiencing the problem on:
In safari, the video plays fine with both audio tracks shown as options. So the issue is likely to be in this codebase.
Environment info
React native info output: FWIW we noticed the issue on older react-native(0.68) also
Library version: 5.2.1
Steps To Reproduce
Expected behaviour
Reproducible sample code
The log showed only one audio track.
Video sample
https://d3bm2z03a5d1kp.cloudfront.net/narrations/0d4197b0-7fc3-45b2-858b-05fd8977eb38/test.mp4
ffprobe of the sample:
Notice that both the audio tracks have default set at the end.
After I did
The reordered.mp4 plays fine in iOS.
PS: This issue is not happening in Android.