Does anyone know of a way to detect whether a video has been shot in portrait or landscape orientation?
I've tried using the MetaData listener but the values don't seem to be reliable.
Also checking _videoPlayer.nativeWidth and _videoPlayer.nativeHeight, all videos show the width as the longest dimension even if the video has been shot in portrait mode.
I did come across this post regarding trackHeaderBoxMatrix. Although this appears to be only usable with a flash.Video component the data does seem to be the only element that could be a differentiator.
https://blogs.adobe.com/flashplayer/tag/app#sthash.xeGnU3aG.dpbs
Thanks,
Mark
Here are the metadata details for both orientations:
LANDSCAPE OUTPUT
audiochannels: 1
audiocodecid: mp4a
avclevel: 42
seekpoints: [object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
height: 4294966217
moovposition: 28
avcprofile: 100
trackHeaderBoxMatrix: (a=-1, b=0, c=0, d=-1, tx=1920, ty=1080)
trackinfo: [object Object],[object Object],[object Object],[object Object]
videocodecid: avc1
width: 4294965377
audiosamplerate: 44100
movieHeaderBoxMatrix: (a=1, b=0, c=0, d=1, tx=0, ty=0)
aacaot: 2
duration: 3.900952380952381
videoframerate: 60
_movieLength 3.9
_videoPlayer.nativeWidth 1920
_videoPlayer.nativeHeight 1088
PORTRAIT OUTPUT
audiochannels: 1
audiocodecid: mp4a
avclevel: 42
seekpoints: [object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
height: 4294966218
moovposition: 28
avcprofile: 100
trackHeaderBoxMatrix: (a=0, b=1, c=-1, d=0, tx=1080, ty=0)
trackinfo: [object Object],[object Object],[object Object],[object Object]
videocodecid: avc1
width: 4294966217
audiosamplerate: 44100
movieHeaderBoxMatrix: (a=1, b=0, c=0, d=1, tx=0, ty=0)
aacaot: 2
duration: 3.7848526077097504
videoframerate: 60
_movieLength 3.78
_videoPlayer.nativeWidth 1920
_videoPlayer.nativeHeight 1088