Search Unity

Video Error while reading movie, Manjaro Linux

Discussion in 'Audio & Video' started by drsalvation, Mar 19, 2023.

  1. drsalvation

    drsalvation

    Joined:
    May 2, 2014
    Posts:
    48
    I'm not sure if I'm missing any sorts of configurations, video codecs, or whatever, but I've been getting "Error while reading movie" whenever I try to import video files.
    I've been looking into this error but all answers I find are unrelated, usually people trying to import unsupported and uncommon video formats, or like trying to stream urls and such, my case is simple. Maybe MP4 isn't supported in linux?

    1. I'm using Manjaro
    2. I'm in Unity 2021.3.20f1
    3. It's an HDRP project
    4. I'm trying to import a video clip, it's an MP4
    5. I can't even try to play it, the video player component won't take it as a valid clip.
    Full error message: Error while reading movie: /home/username/Game Projects/unityproject/Assets/Videos/introCredits.mp4

    I have no clue where to start looking into this issue, does it come from all 7 different clips I tried to use? Does it come from possibly not having some codecs installed on Manjaro? Does it come from Unity being flakey in Linux distros?

    I usually don't have issues like this on windows, but again, I don't have any ideas what might be causing the issue.
     
  2. The_Island

    The_Island

    Unity Technologies

    Joined:
    Jun 1, 2021
    Posts:
    502
    Exactly. MP4 uses either H264 or H265. Both codecs are heavily patented, so to support MP4, we are getting the codecs from the platform. When we made the Linux implementations, every distro had its own foundation which I think is different today but anyway, the result is we couldn't easily support MP4 on Linux. Contrary to MP4, we do support webm VP8 on all Unity platforms and that is what I would recommend you use instead.
    Something we could do today is to support GStreamer on Linux. If I am not wrong, most distros support or come with it now. Improving our support of containers is definitely something on our radar. You can see on our roadmap, the Extensible Codec Framework which is part of what you are looking for. Make sure to vote on it and submit any other feedback.
    https://unity.com/roadmap/unity-platform/audio-video
     
    Last edited: Mar 20, 2023
  3. drsalvation

    drsalvation

    Joined:
    May 2, 2014
    Posts:
    48
    Thank you! That makes a lot of sense and my work a whole lot easier! I appreciate the help!