react-native-video: onLoad method return wrong naturalSize and I can not get correct orientation of video
onVideoLoad = (payload) => {
console.log('payload', payload)
const { naturalSize = {} } = payload
// const isLandscape = naturalSize.height < naturalSize.width
const isLandscape = naturalSize.orientation === 'landscape'
const video = {
isLandscape
}
this.props.updateVideoListIsLandscape(video)
}
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 4
- Comments: 23
Same problem on both iOS and Android.
@freeboub Hi, I noticed that now android has the same wrong natural size problem
width: 1280 (wrong), height: 720 (wrong), https://bn-dev.fra1.digitaloceanspaces.com/km-tournament/uploads/rn_image_picker_lib_temp_2ee86a27_9312_4548_84af_7fd75d9ad4dd_ad8b20587a.mp4
"react-native": "0.74.1","react-native-video": "6.1.2"it works on 6.1.1