Problem with height and width when decoding H264 with FFMPEG
It seems that when decoding h264 with FFMPEG, avcodec_decode_video2 turns height into width and visa versa. So if I call from IMSdroid with SVGA (800 * 600), I can trace that the engine sets the decoder defaults to 800 * 600 in h264->decoder.context, but when the first frame is received h264->decoder.context.width is set to 600 and h264->decoder.context.height is set to 800.
Any idea why?
Also if I call from one boghe client to another in Full HD 1920 / 1080, the screen on both clients is in 4/3 and not 16/9.
A camera from a mobile device (Android, iOS, WP...) is oriented at 90° on portrait and 0° on landscape. This is why on portrait the height and width are reverted.