Search Issue Tracker

By Design

Votes

14

Found in

2019.1.5f1

2020.1

Issue ID

1163390

Regression

No

[Android] Video is not being rendered when using URL on some Android devices

Mobile

-

To reproduce:
1. Open attached project VideoPlayerAndroidQ.zip
2. Build and run to android device

Actual result: Video is not playing in application
Expected result: video should play normally

Reproduced on: 2017.4.32f1; 2020.1.0a1

Tested and reproduced:
VLNQA00173, Xiaomi Redmi 6Pro (Redmi 6 Pro), Android 9, CPU: Snapdragon 625 MSM8953, GPU: Adreno (TM) 506
VLNQA00022, Xiaomi Redmi Note 3 (Redmi Note 3), Android 5.1.1, CPU: Snapdragon 617 MSM8952, GPU: Adreno (TM) 510
VLNQA00054, Xiaomi MI 4LTE (MI 4LTE), Android 6.0.1, CPU: Snapdragon 801 MSM8974AC, GPU: Adreno (TM) 330
VLNQA00262, Sony Xperia XZ Premium (G8141), Android 9, CPU: Snapdragon 835 MSM8998, GPU: Adreno (TM) 540

Tested and not reproduced:
VLNQA00277, Asus ROG Phone (ASUS_Z01QD), Android 8.1.0, CPU: Snapdragon 845 SDM845, GPU: Adreno (TM) 630
----------, Xiaomi Mi 5 (MI 5), Android 6.0.1, CPU: Snapdragon 820 MSM8996, GPU: Adreno (TM) 530
VLNQA00219, Samsung Galaxy Note9 (SM-N960U), Android 8.1.0, CPU: Snapdragon 845 SDM845, GPU: Adreno (TM) 630
VLNQA00125, Google Pixel 2 (Pixel 2), Android 8.1.0, CPU: Snapdragon 835 MSM8998, GPU: Adreno (TM) 540
VLNQA00286, Meizu - (PRO 5), Android 7.0, CPU: Exynos 7 Octa 7420, GPU: Mali-T760

Note: no repro on standalone
Note: User gets error line with W/Unity: AndroidVideoMedia: Error opening extractor: -10000

  1. Resolution Note (2020.1.X):

    The critical thing is in the Player Settings. If the "Target API Level" is Android 9 or later, then this bug seems to happen.

    In the AndroidManifest.xml file, which Unity generates for you, you can add stuff if necessary. There are some instructions on how to do this here: https://docs.unity3d.com/Manual/android-manifest.html. The problem is that when targeting Android 9 or later, cleartext network traffic is no longer allowed by default. So, "http" URLs are no longer allowed by default. "https" should be fine. You can change this by modifying the following in your AndroidManifest.xml:
    <application android:isGame="true" android:usesCleartextTraffic="true">

Comments (13)

  1. KevinSFH

    Feb 24, 2022 14:48

    Not working on 2020.3.29f1, still the same issue with Target API Level 27 (Oreo 8.1) so it's not beyond API level 9 as stated. Tested on Nvidia Shield Tablet with Android 7 and some recent Android 10 phones : AndroidVideoMedia: Error opening extractor: -10000

  2. NitinAltran

    Dec 16, 2021 09:00

    Still not working in 2020.3.16f1 for android 10

  3. Rodolfomachado

    Apr 16, 2020 22:58

    I think it is a problem in the snapdragon 855.... when rendering to android using even examples of unity, it does not work.

  4. anujsaini

    Mar 25, 2020 09:31

    Videos are playing fine in 2019.1.14 but not in 2019.2.5.
    What is this...?

  5. Brad-Newman

    Jan 10, 2020 05:35

    I'm not using URLs, just loading videos from an uncompressed local Asset Bundle, and I get this error in 2019.2.7f2. Some videos work, others don't. Can't determine a pattern:

    Warn MediaExtractor: FAILED to autodetect media content.
    Error MediaExtractor: Trace connect 0x0 0xbf955600
    Error NdkMediaExtractor: sf error code: -1010
    Warn Unity: AndroidVideoMedia: Error opening extractor: -10000
    Warn Unity: (Filename: ./PlatformDependent/AndroidPlayer/Modules/Video/Private/AndroidVideoMedia.cpp Line: 457)

  6. fiachradunn

    Nov 05, 2019 15:59

    Reproduced in 2019.1.8f1 after changing target API level to Android 8.0

    Fix doesn't work for my device (Lenovo Phab 2 Pro) still receive error;
    AndroidVideoMedia: Error opening extractor: -10000

    Https links are not okay as the fix suggested. (Using Azure media service progressive download URLs)

  7. danyruibal

    Oct 10, 2019 10:47

    Video is not playing on Android Q / Pixel 2 when using a local filesystem url. Remote URLs are working just fine. Permissions are correctly set, and videos are playing on any other device/OS.

    W/Unity: AndroidVideoMedia: Error opening extractor: -10002

  8. wintermuute

    Oct 09, 2019 21:55

    Having this issue with Unity 2019.2.8 in Android 10/Q. Added the suggested changes to the Android Manifest but the problem still persists...

    E/NdkMediaExtractor: can't create http service
    W/Unity: AndroidVideoMedia: Error opening extractor: -10002

  9. RobAtJam

    Sep 24, 2019 09:49

    Also reproduced in 2019.1.11f1

  10. RobAtJam

    Sep 24, 2019 09:42

    We have a similar issue using a Google Pixel (first generation) on Android 10.

    E/NdkMediaExtractor: can't create http service
    W/Unity: AndroidVideoMedia: Error opening extractor: -10002

    We're using a persistent data video file using the URL as the source for the video player.

    videoPlayer.source = VideoSource.Url;
    videoPlayer.url = Path.Combine(Application.persistentDataPath, videoToOpen.video_src);

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.