Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

[Released] AVPro Video - complete video playback solution

Discussion in 'Assets and Asset Store' started by AndrewRH, Feb 12, 2016.

  1. LostPanda

    LostPanda

    Joined:
    Apr 5, 2013
    Posts:
    173
    @NathanRH How much does it cost to upgrade from 1.x to 2.x? Thank you
     
  2. twotokki

    twotokki

    Joined:
    Dec 15, 2020
    Posts:
    1
    Google Cardboard XR Plugin for Unity
    I find error with Google Cardboard XR Plugin for Unity.
    I can play video but I can't see video Left/Right properly.
    I can only see Left/Left and Right/Right in cardboard + android phone(gallexy s10, s8).


     
  3. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
  4. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    LostPanda likes this.
  5. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    145
    As above...please submit a report on the github issues, or alternatively you can email unitysupport@renderheads.com.

    I have tested Google Cardboard in our Stereo360 demo scene and it works as you would expect. My hunch is that there is stereo metadata in your video. We describe how to remove this in the PDF manual, Appendix A (FAQ), question 8.

    We will require your video sent over for us to investigate if you would prefer.

    Thanks!
     
    Last edited: Dec 15, 2020
  6. RiccardoAxed

    RiccardoAxed

    Joined:
    Aug 29, 2017
    Posts:
    119
    Hi, I'm sure it's already been asked and answered but I can't find any reference about it.

    The question is: does AVPro Video support URP and HDRP?
     
  7. BriceVayne

    BriceVayne

    Joined:
    Jan 9, 2020
    Posts:
    1
    Hi,

    Problem description:

    I have some questions about rtsp stream and Unity.
    I had look the last user manual and check some forums about these questions and I found nothing conclusive.

    My problem is: I want to display an RTSP stream from UI in Unity 2019.
    I had create a Media Player set like that:
    Absolute path or URL, with and internal URL format like this: rtsp://ipv4/id
    Choosen Windows in Plateform Specific and set to Direct Show api like the user manual recommand.
    Add 2 filters: LAV Video Decoder and Microsoft DTV-DVD Video Decoder like the user manual suggest and unity propose.
    I had add a Display uGUI component to display it.
    When I start the scene in editor, theses logs are print:
    [AVProVideo] Initialising AVPro Video (script v1.11.4 plugin v1.11.4) on NVIDIA GeForce GTX 1060 6GB/Direct3D 11.0 [level 11.1] (MT True) on WindowsEditor Windows 10 (10.0.0) 64bit
    [AVProVideo] Opening rtsp://ipv4/id (offset 0) with API DirectShow
    [AVProVideo] Failed to open rtsp://ipv4/id
    [AVProVideo] Shutdown

    Device (which devices are you having the issue with - model, OS version number):



    Media (tell us about your videos - number of videos, resolution, codec, frame-rate, example URLs):



    System Information:

    AVPro Video: plugin v1.11.4 scripts v1.11.4
    Target Platform: Standalone
    Unity: v2019.4.13f1 WindowsEditor
    OS: Desktop - MS-7978 (MSI) - Windows 10 (10.0.0) 64bit - French
    CPU: Intel(R) Core(TM) i5-6600 CPU @ 3.30GHz - 4 threads - 24450KB
     
  8. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53

    There is no "UpdateStereoMaterial" script in 2.0. Your documentation sends us to the "Demo_360SphereVideo" demo scene to see how things are setup, but it does not exist. There is no documentation on how to use 2.0 to play VR videos in 3D. It does not work and there is no resources. I hope you guys will fix this before discontinuing 1.x...... I'm very disapointed....
     
  9. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    The documentation is not complete yet - some of it is still the old notes and is in the process of being replaced. We will be adding demo scenes and quickstart guides very soon. I have replied to your issue on GitHub regarding stereo video playback.
     
  10. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Are you able to play that same URL in another player (eg VLC)?

    Thanks,
     
  11. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Yes it does support it.
     
    RiccardoAxed likes this.
  12. iLyxa3D

    iLyxa3D

    Joined:
    Sep 25, 2013
    Posts:
    31
    Hi, RH developers!

    Please, give me an advice:

    I have old project where Avpro Video 1.9.2 in use, and I see error while playing 3840x3840 panoramic videos on Android (Samsung Galaxy S7)
    Code (CSharp):
    1. MediaCodec: Codec reported err 0xffffec77, actionCode 0, while in state 3
    2. ExoPlayerImplInternal: Caused by: com.google.android.exoplayer2.mediacodec.MediaCodecRenderer$DecoderInitializationException: Decoder init failed: OMX.Exynos.avc.dec, Format(1, null, video/avc, -1, null, [3840, 3840, -1.0], [-1, -1])
    Video 2048x2048 playing well.

    Is there a way to check video size support on the device before playing?
    What if I will update it to last 1.x version, it will solve problem? I can not find information about it in Release Notes.
    Should I wait for 2.x version and use it? When it will be released?

    Thanks!
     
  13. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Yes that resolution is too high the for S7. I'm afraid there isn't a way to check video size - even on Android low-level the results for codec checks are often inaccurate - especially as it's not just a simple question of resolution, it can depend on other factors too such as bitrate, frame rate, profile level etc.
    The best way is to simply try to load the video and see whether it can play. A blank dummy video is often useful for this. Otherwise using an adaptive streaming system like HLS can be used if you need to target a wide range of devices.

    I don't think upgrading to the latest version (or version 2) will solve this problem as I believe it's just a limitation of the S7. Version 2 will be released very soon - it's currently in review at the Asset Store, but there is a RC1 trial version available here:
    https://github.com/RenderHeads/UnityPlugin-AVProVideo/releases/tag/2.0.0rc1

    Thanks,
     
    iLyxa3D likes this.
  14. jbolton

    jbolton

    Joined:
    Aug 24, 2019
    Posts:
    4
    Hi RenderHeads,

    Fantastic asset. We've been doing some testing with the version 2.0 Beta for a project that requires quick switching between multiple video tracks. While the media player is playing everything is great but we're looking to have the texture displaying the video update when the track is switched while the media player is paused as well. We've been digging through the documentation but haven't seen anything that would force the player to update the texture until we trigger play again.

    Thanks!
     
  15. draky

    draky

    Joined:
    Nov 24, 2016
    Posts:
    12
    Hey,

    Just curious, we had an issue where we installed our application on a new PC but could not play back a video due to a missing codec (HEVC codec), and was wondering if this is expected with AVPro and we'd need to download the codecs separately?

    Thanks!
     
  16. Ikaro88

    Ikaro88

    Joined:
    Jun 6, 2016
    Posts:
    296
    with the 1.10 version after high use of the phone i get this error:
    Error: Loading failed. File not found, codec not supported, video resolution too high or insufficient system resources

    But when the resource usage go down the problem still occour...why?
     
  17. Wulf-Games

    Wulf-Games

    Joined:
    Apr 5, 2016
    Posts:
    9
    Looking for help from the community or the AVpro team, we filed an issue on github:

    https://github.com/RenderHeads/UnityPlugin-AVProVideo/issues/557

    If there's anyone here that can help we'd really appreciate it!

    Describe the bug

    When trying to reproduce a live video from vimeo having a premium account and using
    their SDK https://github.com/vimeo/vimeo-unity-sdk we get the following error:
    [AVProVideo] Error: Loading failed. File not found, codec not supported, video resolution too high or insufficient system resources.
    UnityEngine.Debug:LogError(Object)

    Not sure if there's an additional step in order to get it working, seems like the codec is not supported.

    Thanks!

    Your Setup (please complete the following information):

    • Unity version: 2020.1.9
    • AVPro Video version: 1.11.7
    • Operating system version: Windows 10
    • Device model:
    • Video specs (resolution, frame-rate, codec, file size): 1280x720, 30fps, mpd, live
    To Reproduce

    1. Create live streaming on vimeo
    2. Using vimeo SDK
    3. Select live video and hit play


    Any ideas to what might be happening?


    Thanks!
     
    Last edited: Dec 23, 2020
  18. cihad_unity

    cihad_unity

    Joined:
    Dec 27, 2019
    Posts:
    35
    Hi @NathanRH, I have some questions about ffmpeg and your asset.
    When I try to integrate ffmpeg in my unity project, it works fine without your asset.
    Your asset works fine without ffmpeg too.

    So it seems like either you use ffmpeg library under the hood or use the same libraries ffmpeg uses.
    As far as I learned, ffmpeg uses following libraries:
    libavcodec
    libavdevice
    libavfilter
    libavformat
    libavutil
    libswresample
    libswscale

    How to troubleshoot this problem?

    Never mind, it was not related to your player :)
     
    Last edited: Dec 29, 2020
    NathanRH likes this.
  19. DaniilGalahow

    DaniilGalahow

    Joined:
    Dec 2, 2013
    Posts:
    12
    Hello! I'm have a trouble with AVPro Video Player. It can't play video on Android, at all. After loading video it doesn't show preview image, also it doesn't start to play video after
    player.Control.Play();
    command. I'm tried to change Main and Platform Specific settings, but nothing helped - no image on uGUI Display at all.

    In debug log player reports:

    In Unity Editor on Windows all works perfectly.

    My setup:
    - Unity version: 2019.4.12f1
    - AVPro Video version: 1.11.5t (Trial)
    - Operating system version: Android 10, 9, 8
    - Device model: ASUS ZS620KL and other
    - Video specs: 1920x1080, 30fps, mpeg4 (H264), 29.0Mb

    What's going on and where can be an error? I spent 3 days to fix this already, but can't fix it yet, and can't find any solution in internet.
     
  20. Pourya-MDP

    Pourya-MDP

    Joined:
    May 18, 2017
    Posts:
    145
    Hi there any timeline support with this asset?
    Playable track to drag and drop videos in timeline to scrub and playback?
     
  21. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53
    It's not something that it can do out of the box. It has the primitive functions that allow you to program this, though.
     
  22. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Does it work if you use our sample videos instead? Or our demo scenes?

    You can also check the android log via adb log cat for more information in case there is an internal problem. If you share it here we can take a look.

    You might also want to upgrade to the latest version (1.11.7) of the plugin.

    Let us know,

    Thanks,
     
  23. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    No there is no built-in support, but it could be extended to do that. In AVPro Video 2.0 we are shipping it with some built-in Playables/Timeline support so you can take a look at that perhaps.

    Thanks,
     
  24. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Do you mean that you want the previous video texture to display while the new video is loading so that it's seamless? If so, this is something we're working on. IF you select WinRT Video API on Windows (under Platform Specific) then it should be a lot more seamless as we have added this feature to this API. We hope to roll it out of the other APIs soon. Otherwise you have 2 other options: Use the PlaylistMediaPlayer component that is designed to playlist multiple videos seamlessly, or roll your own solution where the last frame is displayed while the next video loads.

    Thanks,
     
  25. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    I'm afraid we can't do much with this little information. Please report the details of your issue here:
    https://github.com/RenderHeads/UnityPlugin-AVProVideo/issues

    Then our developers will be able to investigate.

    Thanks,
     
  26. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    AVPro Video doesn't ship with any included codecs (except for Hap) (and NotchLC in version 2.0), so it uses the operating system codecs. On Windows they removed the HEVC codec by default, so now it requires a free download to install it:
    https://www.microsoft.com/en-us/p/hevc-video-extensions-from-device-manufacturer/9n4wgh0z6vhq

    I just had a look though and it seems that Microsoft have now made this free option unavailable, so only the 99 cent option is left:
    https://www.microsoft.com/en-us/p/hevc-video-extensions/9nmzlz57r3t7?activetab=pivot:overviewtab

    This is very annoying but there's not much we can do about this. It seems like H.264 is still the best for compatiblity.
     
  27. DigitalIPete2

    DigitalIPete2

    Joined:
    Aug 28, 2013
    Posts:
    44
    Hi,
    did you ever solve this? I can't believe there are no other Oculus Quest users using AV Pro?
     
  28. Ikaro88

    Ikaro88

    Joined:
    Jun 6, 2016
    Posts:
    296
    There is a way to use this with Metal instead of opengl on IOS?
     
  29. Juanola_

    Juanola_

    Joined:
    Sep 29, 2015
    Posts:
    38
    Hello!

    According to your experience with the Asset Store, when do you think V2.0 is going to be released?

    Thanks!
     
  30. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Yes, simply go to Player Settings - Auto Graphics API for IOS - and remove OpenGL from the list.
     
    Ikaro88 likes this.
  31. jbolton

    jbolton

    Joined:
    Aug 24, 2019
    Posts:
    4
    Thanks for the reply. I should have provided more detail. We're playing a single video file with approximately 60 individual video tracks (no audio tracks) with each track representing a different camera position. What we're looking to do is switch the camera track while the video is paused using
    Code (CSharp):
    1.  m_mediaPlayer.VideoTracks.SetActiveVideoTrack()
    and have the playback texture update to match the camera position from the newly active video track prior to resuming playback. We've been looking through the documentation to see if there's a way to trigger the media player to load the track and update the texture outside of calling Play but haven't seen anything yet.
     
  32. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    We're hoping tomorrow :)
     
    LostPanda likes this.
  33. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Ahh I understand now.

    Which platform is this on? (there can be different behaviour per-platform in some cases).

    Am I understand you right, that right now, if you switch track while paused, you don't get an image update until you hit Play? And if you call Play() and then Pause() straight away does that help?

    Thanks,
     
  34. jbolton

    jbolton

    Joined:
    Aug 24, 2019
    Posts:
    4
    It's Windows and MediaFoundation as the Video API. Yes, that's correct, no image update until we hit Play. Unfortunately, calling Play and then Pause straight away doesn't seem to make a difference. Thanks!
     
  35. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Okay interesting, I'll take a look.
     
  36. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Okay, we have replicated the issue. In 2.0-RC2 version we have corrected the behaviour, however you must select the Video API "WinRT". This new version should be available in a few hours. Let me know how that works for you.

    Thanks,
     
  37. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53
    Nathan, how do we upgrade our version to 2.0? Do we do it on the AssetStore or directly with Renderheads?
     
  38. jbolton

    jbolton

    Joined:
    Aug 24, 2019
    Posts:
    4
    Works perfectly, thanks for taking a look at it and the quick turnaround is very much appreciated!
     
    AndrewRH likes this.
  39. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,806
    Via the asset store - it just became live today.
    Thanks,
     
  40. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,806
    Hi All,

    AVPro Video version 2.0 has just been released!

    AVPro Video.png

    Rocket32.png DOWNLOAD THE FREE TRIAL VERSION HERE
    Rocket32.png

    Links: Webpage | Documentation | Support

    New Features
    • Direct3D 12 support
    • WinRT API for better Streaming on Windows
    • Windows support for videos with stereo metadata
    • macOS and iOS more performant and using less memory
    • Latest Android ExoPlayer
    • Android support for audio piping to Unity
    • Auto-detection of stereo videos
    • & much more - see documentation here for details
    General Features
    • Easy to use
    • Fast and powerful video playback
    • Based on 8 years of Unity video plugin development
    • Battle tested in professional productions
    • Native support for Windows, macOS, iOS, tvOS, Android and UWP
    • No huge dependent libraries (eg FFMPEG)
    • Unity 2018.x - 2020.x supported
    • Easy to use drag and drop components
    • Free watermarked trial version available
    • Strong documentation and developer support
    Playback Features
    • Play local, remote and adaptive (HLS/DASH) videos
    • VR, 360, 180, Mono and Stereo videos supported
    • 8K+ video decoding (on supported systems)
    • Transparent videos
    • Subtitles
    • Audio piping to Unity
    Workflow Features
    • In editor preview and playback
    • Asset type for easily defining video content
    Ultra Edition Features
    • Custom HTTP headers
    • AES-128 HLS
    • Decoding to 10-Bit textures (Windows only)
    • Hap codec (Windows and macOS only)
    • 10-Bit NotchLC codec (Windows only)
    • Spatial 360 audio

    Download Links


    Editions
    On the Unity Asset Store we've made several editions of AVPro Video available so you can pick the one that's best for your project:
    Core Edition
    Ultra Edition
    • Enterprise Edition (contact us for multi-site licensing / support options)
    You can read this page to learn more about the features, pricing and upgrades for the different editions.

    Rocket32.png DOWNLOAD THE FREE TRIAL VERSION HERE Rocket32.png

    Thanks to everyone who helped testing the beta releases! We're looking forward continuing to support this product into the future and adding more features.

    Thanks,
     
    Last edited: Jan 8, 2021
  41. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53
    After importing the AVPRO 2.0 in my project, I get the following:

    upload_2021-1-8_8-55-24.png
     
  42. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Oh dear - hmmm I wonder what could be causing that...Did you download the trial version or from the asset store? Which version of Unity are you using, and on which platform?
    Did you remove any previous BETA versions before upgrading?
     
  43. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53
    I am using Unity 2019.4.0f1.

    I'm using the trial version from your GitHub repository here: https://github.com/RenderHeads/UnityPlugin-AVProVideo/releases

    I updated my project as you described: Restart Unity, then Assets/ImportPackage/CustomPackage and select overwrite whenever asked.

    Also another interesting one: I cannot expand the Media Player in my project. I'm getting "Object reference not set to an instance of an object" MediaPlayerEditor_source.cs:315 which gives me this result:

    upload_2021-1-8_16-43-9.png

    I had to add " if (mediaPath != null) { on line 310 and } line 362 to make it work.
     
    Last edited: Jan 8, 2021
  44. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    Thanks, I guess it was an upgrade issue if you had a previous version of AVPro Video Beta/RC..
     
  45. LostPanda

    LostPanda

    Joined:
    Apr 5, 2013
    Posts:
    173
    @NathanRH
    I suggest that version 2.0 provide a Window AVPro Video-Ultra Edition, because I don’t need andriod and ios. I think other people also have this need.
     
  46. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53
    Hi Nathan,

    You guys have done a great work with version 2.0. However what keeps me swearing at it, even after puchasing the full version, is the lack of documetation for the API.

    Yes, you do have a reference to the API here: Namespace RenderHeads.Media.AVProVideo | AVPro Video - Documentation but aside from listing the functions, this does not do much to get us started. Version 1 had a better, though limited, introduction in the PDF manual. For example, right now I struggle to force eye mode on a stereo video to render only left eye when the UI appears, which makes it easier for user to click and select UI options. It used to be available through the UpdateStereoMaterial. StereoScript.ForceEyeMode = StereoEye.Left or StereoEye.Both. But now, I have no idea where to find this functionality, the search function of the API reference does not work well and the only thing I can find is the StereoEye enum, and not where it is being used....

    Another example: there are three places where you can choose the stereo packing of a video: in the MediaPlayer itself (under MediaSource and Stereo Packing), in the Apply to Mesh script (select Automatic Stereo Packing or override) and in the shader itself (AVPRO/VR/InsideSphere, choose "Stereo Mode"). If you try to change it from the Apply to Mesh, it does not work. The one that works is under the MediaPlayer itself, but you can't access it from script (or at least, it's not clear how). And the Force Eye Mode from the Shader is not accessible through script. Can you see how much a coder can become crazy?

    Another example, I'm looking to change the video mapping programatically from Equi_Rectangular_180 to Equi_Rectangular_360 for 360 videos, no idea where to find this.

    You have a really great asset, but this lack of documentation really makes it much less valued because of the time required to fiddle with it and, maybe, finally find, through trial and error and sometime brute force method, the functionality of the scripting API.

    After spending good money on this, I would have hoped this to be more complete and much clearer. I am an experienced coder, so I'm not looking to be spoon fed. But minimal documentation for an asset worth $600-$800 is expected.
     
    Last edited: Jan 11, 2021
    Ste-RH and NathanRH like this.
  47. NathanRH

    NathanRH

    Joined:
    Oct 24, 2012
    Posts:
    447
    I hear you, and thanks for the feedback. It's a pretty huge new release, and there are certainly some teething problems and we're working fast to fix them.

    We will improve the API for forcing stereo eye mode. For now you have to do it via the material itself usin the VideoRender helper static class:
    Code (CSharp):
    1. VideoRender.SetupStereoEyeModeMaterial(material, StereoEye.Left);
    We will expose this in the MediaPlayer itself though in the next update.

    Yes there are currently a few places where the stereo packing mode is set - this is a mistake. It should only be set either in the MediaPlayer itself, or in the MediaReference. In the MediaPlayer you can set it:
    Code (CSharp):
    1. MediaHints hints = mediaPlayer.FallbackMediaHints;
    2. hints.stereoPacking = StereoPacking.TopBottom;
    3. mediaPlayer.FallbackMediaHints = hints;
    For the layout you should be able to set it via:
    Code (CSharp):
    1. mediaPlayer.VideoLayoutMapping = VideoMapping.EquiRectangular180;
    The documentation system has greatly improved but we're still populating it with script examples, common user-case guides etc, which you should see starting to appear this week.

    I hope that above is helpful.

    Please do keep up the good comms with us so we can make sure that these issues get fixed.

    Thanks,
     
    Ste-RH likes this.
  48. Dmitry-Kuz

    Dmitry-Kuz

    Joined:
    Nov 15, 2016
    Posts:
    6

    Attached Files:

  49. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    53

    The hints you gave above seem to work. However, noteworthy: after changing the StereoPacking, you need to reload the video, while before you could simply stop and restart it.

    Code snippets would be very useful, as well as the "scriptlets" you had in the previous version. However nothing replaces a good search function that works on the web page, as well as clear description of the functons (for e.g. GetCurrentTimeMS does not work anymore, does this mean that all the seek functions and other time dependant functions now work in seconds?)

    Thanks for your reply. If you want me to keep them comming, I will.... Careful what you wish for! :p
     
    Last edited: Jan 11, 2021
    Ste-RH likes this.
  50. amata_kuroyangi

    amata_kuroyangi

    Joined:
    Oct 14, 2020
    Posts:
    3
    Hello,

    I was able to stream m3u8 using AVPro.

    Is it possible to seek streaming m3u8 with AVPro?

    Also, I want you to teach me how to do it.