UnityPlugin-AVProVideo
UnityPlugin-AVProVideo copied to clipboard
When using MediaFoundation API to play a HAP video, the video proportion is displayed incorrectly
When using MediaFoundation API to play a video, the video proportion is displayed incorrectly
Your Setup (please complete the following information):
-
Unity version: Unity: v2019.4.26f1c1 WindowsEditor
-
AVPro Video version (number and edition (trial/core/ultra/enterprise)): v2.6.6 (plugin v2.6.3f1-ultra)
-
Operating system version: Windows 10 (10.0.22621) 64bit
-
Device model:
-
Video specs (resolution, frame-rate, codec, file size): 128*128 ;25;Hap Alpha mov ;1M
To Reproduce
- The same video is played on UGUI, and Scale Mode uses Scale To Fit.
- When using DirectShow Api to play, the screen ratio is displayed normally; when using MediaFoundation Api to play, the screen ratio is displayed incorrectly.
- In the WindowsMediaPlayer - GetTexturePixelAspectRatio method, the two APIs have different return values, which may be the key to this problem.
Can you upgrade to the latest version of AVPro Video and retest please.
Any luck?
Well, I tested the same video on the latest version and the problem persists. Could there be something wrong with my video?
Any luck?
Could you see how it works in Directshow? Could you email the video to [email protected] please
Could you see how it works in Directshow? Could you email the video to [email protected] please
Testing using: BigBuckBunny-360p30-HAP.mov (640x360, 30FPS, 20Mb/s) Cones-2D-1080p60-HAP.mov (1920x1080, 60 FPS, 300Mb/s)
DirectShow: Correct proportion MediaFoundation + Use HAP/NotchLC enabled: Correct proportion MediaFoundation + Use HAP/NotchLC enabled + Use Custom MOV parser enabled: Incorrect proportion
4kHAP.mov (3840x2160, 60FPS, 263Mb/s)
DirectShow: Correct proportion MediaFoundation + Use HAP/NotchLC enabled: Doesn't play MediaFoundation + Use HAP/NotchLC enabled + Use Custom MOV parser enabled: Incorrect proportion
Hap_Alpha_16384x8640.mov (16384x8640, 24FPS, 1 328 Mb/s)
DirectShow: Correct proportion MediaFoundation + Use HAP/NotchLC enabled: Correct proportion MediaFoundation + Use HAP/NotchLC enabled + Use Custom MOV parser enabled: Incorrect proportion
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
I had a look into why the Custom MOV Parser was returning incorrect video aspects and found it was using a pixel aspect ratio (PAR) of 2 by default, instead of 1.
Fixed for the next release.
AVPro Video version 3.0.5 has been released. Please let us know if it has not fixed your issue.