Search Unity

Question Background transparent webm video that works well in Unity 2018 doesn't work in Unity 2019

Discussion in 'Audio & Video' started by QuilloGames, Aug 7, 2020.

  1. QuilloGames

    QuilloGames

    Joined:
    Jul 31, 2017
    Posts:
    17
    I have a background transparent webm video that has to be played using a Video Player Component.

    The video was imported (with Keep Alpha) and played without problem in Unity 2018.1.4f1. But when I upgraded the project to 2019.4.6f1, the import shows the errors:

    VideoClip import error for Assets/Ricky/Resources/SaveableData/VideoClips/effect_BatsFlyBy 2.webm
    UnityEditorInternal.InternalEditorUtility: ProjectWindowDrag(HierarchyProperty, Boolean)
    UnityEngine.GUIUtility: ProcessEvent(Int32, IntPtr)

    VideoClip import error for Assets/Ricky/Resources/SaveableData/VideoClips/effect_BatsFlyBy 2.webm
    UnityEngine.GUIUtility: ProcessEvent(Int32, IntPtr)

    And it cannot be dragged into the Video Player's Video Clip field. Then I tried to use the Transcode property, set it to the VP8 codec. It is then able to be dragged into the Video Clip field.

    Since the video has to be played in front of any game object, so the Render Mode has to be Camera Near Plane. The video can now be played. But when it plays, every game object in & in front of the Default sorting layer disappear, and reappear after the clip is finished.

    I have tried different codecs, bitrate mode, spatial quality, deinterface, but none works. Please help.
     
  2. DominiqueLrx

    DominiqueLrx

    Unity Technologies

    Joined:
    Dec 14, 2016
    Posts:
    260
    Hi!

    Can you tell us what platform this is for? Unless this is for Android (in which case transcoding to H.264 is needed to get transparency), you should not need to transcode at all, especially given you are saying this used to work fine.

    It could be useful to see what the actual import error is (should be in the log, or in the details of the console message). When transcoding, do make sure that the "Keep Alpha" importer property is enabled (it defaults to off).

    If none of these basic checks help you get a properly transparent clip, then please submit a bug report so we can have a look.

    Dominique Leroux
    A/V developer at Unity
     
  3. QuilloGames

    QuilloGames

    Joined:
    Jul 31, 2017
    Posts:
    17
    Sorry for the late follow-up. After remaking the video, I managed to import the video without transcode, and the transparency is kept. But when the video is played at Camera Near Plane, the problem of every game object in & in front of the Default sorting layer disappear stil exist, and reappear after the clip is finished.

    It might be because of I switched to use the Universal Rendering Pipeline. Any help is appreciated. Thanks.