Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

[Released] AVPro Video - complete video playback solution

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

  1. cecarlsen

    cecarlsen

    Joined:
    Jun 30, 2006
    Posts:
    574
    Hi @AndresRH

    The latest Asset Store version of AVPro Video (Windows) is 1.8.9 and it says that the package has been submitted using Unity 4.6.8, and 5.2.2.

    Does it support Unity 2018.2?

    And ... I don't expect the demo materials be compatible with HDRP, but are the core functionality compatible? Is it possible to play a video and get access to the RenderTexture in HDRP?
     
    Last edited: Jul 31, 2018
  2. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hi,

    Yes it is compatible with all Unity versions above 4.6. We test with the latest versions such as 2018.2 and even the beta versions.

    Thanks,
     
    cecarlsen likes this.
  3. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    What are the specs of your video?
    What version of Windows are you using? Is there a reason you've switched to DirectShow as the Video API instead of the default Media Foundation? Hardware decoding is only available when using Media Foundation.
     
  4. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Seeking should work just fine on all platforms. Are you using the latest version of AVPro Video (version 1.8.9)? Another thing you can try to Android is to switch the Video API to ExoPlayer (in MediaPlayer > Platform Specific > Android). Thanks,
     
  5. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
    Hello! I tried the trial version before buying and that's the problem when I get RTSP stream from IP camera (in 4k) on some machines it runs fine, and on some kind of error the error "Loading failed." Codec not supported or video resolution too high or insufficient system resources. " And the machines are powerful 36 gigabytes of RAM, i7 7 generation GTX-1050. We found out some regularity, on machines with WIn 10 collection 1703 this error is, and on machines with assembly 1803 everything works perfectly. FYI also i test this stream in VLC player, on all machines works fine.
     
  6. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hi,
    What codec is the RTSP stream using?
    Is it possible that you could share the URL for us to test? (can email us at http://www.renderheads.com/contact/)

    Thanks,
     
  7. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
  8. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
    Any ideas? :)
     
  9. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    So AVPro Video doesn't really have good support for RTSP currently. You can see this in the PDF documentation where we have a table showing supported formats. On Windows desktop we do support it, but only when using the Directshow video API (selectable in MediaPlayer > Platform Specific > Windows) and using a 3rd party codec installed, such as LAV Filters. Android has some support for it, but maybe only for lower resolutions.
     
  10. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
    Thx, Android not interested, only Windows. But strange, why this works on some Win machines and not work on other (with same hardware). Now i change Video API to DS, how to enable LAV in plugin? Also as I say before, Media Foundation works fine on some machines (hardware decoding)
     
    Last edited: Jul 31, 2018
  11. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    For LAV Filters you just download and install it.

    Can you try this link?
    rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mov

    Is your video using HEVC/H265? Because I know different versions of Windows have different abilities to decode this. If your video is using H264 then I'm not sure of the issue... Hard to say without the URL
     
  12. Brathnann

    Brathnann

    Joined:
    Aug 12, 2014
    Posts:
    5,213
    We are trying to display an animation while the video is paused and seeking.We have set up code to respond to
    MediaPlayerEvent.EventType.StartedSeeking and MediaPlayerEvent.EventType.FinishedSeeking

    In editor, the code works perfectly fine. But when built out to mobile (I'm testing on Android currently) the events are only called once at the start of the video player but then when I pause the video and try to seek, the event doesn't trigger so I don't get any animation. Is there something I'm missing on mobile?

    Oh, and we are calling PlayingPlayer.Control.Seek(float value) to trigger the seek.
     
  13. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
    Watch my second post to you :) this link first that I try after issue :)
     
  14. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
  15. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    1,939
    FYI After updating Windows to build 1803, RTSP stream on these machines starts working without error.
     
    AndrewRH likes this.
  16. MarkHenryC

    MarkHenryC

    Joined:
    Nov 30, 2009
    Posts:
    63
    Problem description:

    When I'm switching between MediaPlayer an Exo Player in code (depending on the video I'm loading) it doesn't reinitialise. Dos this mean I have to create a new MediaPlayer for each video format I support?
    This would not be ideal, as I bind the player to a sphere for 360 video. What's the recommended way to handle this? The main two formats I need to support are those handled by MediaPlayer (H264 etc) and
    Facebook Audio 360 which requires Exo Player. I can set the PlatformOptionsAndroid.videoApi field at runtime but this field only seems to be used for initialisation at the MediaPlayer's creation.

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

    Oculus Go

    System Information:

    AVPro Video: plugin v1.8.9 scripts v1.8.9
    Target Platform: Android
    Unity: v2017.4.1f1 WindowsEditor
    OS: Desktop - MS-7816 (MSI) - Windows 10 (10.0.0) 64bit - English
    CPU: Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz - 8 threads - 16069KB
    GPU: Emulated GPU running OpenGL ES 3.0 - Emulated - OpenGL ES 3.0 [emulated] - 8088KB - 4096

    UPDATE:

    I'll make the question simpler: I can use Exo Player for all formats I require. But how do I change the format at runtime? I can set Audio Mode and Channel Mode in the Inspector, but only the Channel Mode seems available in the API. But changing these fields doesn't initiate any re-initialisation, so I'm stuck with the same format as when the MediaPlayer component is first created (when the Initialize() method is first called. There must be a way around this but I can't find it in the source code or the API docs.
     
    Last edited: Aug 3, 2018
  17. jungduksu

    jungduksu

    Joined:
    Mar 6, 2018
    Posts:
    1
    Problem description:
    We are a licensee of AVProVideo the latest unity version and Use the latest version of Unity 2018 2.1f1
    Not compatible on some Android devices.
    For example, in an app installed on Lenovo Tab 4 Pro,
    the slider is abnormal when playing a video. Please tell me how to fix it!



    Email : iwa14master@gmail.com
    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.8.9 scripts v1.8.9
    Target Platform: Android
    Unity: v2018.2.1f1 WindowsEditor
    OS: Desktop - GL62 6QE (Micro-Star International Co., Ltd.) - Windows 7 (6.1.0) 64bit - Korean
    CPU: Intel(R) Core(TM) i7-6700HQ CPU @ 2.60GHz - 8 threads - 16260KB
    GPU: Emulated GPU running OpenGL ES 3.0 - Emulated - OpenGL ES 3.0 [emulated] - 1995KB - 4096
     
  18. Idlepenguin

    Idlepenguin

    Joined:
    Jan 27, 2013
    Posts:
    2
    Hey Guys,

    I'm using AVPro at the moment for a HTC Vive project with Facbook 360 Audio. I noticed that if I use Media Foundation the video splits in half only giving me one of the eyes. If I turn of Top and Bottom in the video packing it then gives me one half of the image per eye. Using Direct Show fixes this, as does removing the VR MetaData from the video.

    My current issue, which may or may not be related to the above one, is that when using the Facbook360 Audio I have to use Media Foundation and the video needs the meta data for sound. Even with the meta data (and half an image) at the moment it is not specializing the sound. I've tried just about everything I can think of and I'm at a loss. I've triple checked that the video is working with the audio perfectly in other media players (Vive Cinema for example), but I cannot seem to get anything out of it using AVPro.

    Any advice on how I can solve this issue? Or why the issue would be occurring?

    Thanks.
     
    tufeixp likes this.
  19. MarkHenryC

    MarkHenryC

    Joined:
    Nov 30, 2009
    Posts:
    63
    This is the only link I could find that references VideoApi. Good to know that runtime switching is supposed to be supported but it doesn't work on Android switching from MediaPlayer to ExoPlayer - at least when the Exo Player is set up for FB 360
     
  20. sharjahtourism

    sharjahtourism

    Joined:
    May 19, 2017
    Posts:
    24
    ExoPlayer supports DRM?
     
  21. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    ExoPlayer does, but we haven't implemented any of the DRM features yet in our player.
     
  22. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hi,

    On Android did you try switching to the ExoPlayer API? This can be found in MediaPlayer > Platform Specific > Android. It may give you matching events. Otherwise, perhaps you also need to listen for the Buffering and Stalled events, and only hide your animation when all of the Seeking, Buffering and Stalled events have completed.

    I hope this helps you. Let me know if you have any more questions.
     
  23. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    What do you mean exactly by "the slider is abnormal when playing a video"?
    Perhaps try switching to the ExoPlayer API option (in MediaPlayer > Platform Specific > Android) to see if that helps?

    Thanks,
     
  24. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Yes currently in our Windows implementation if there is any stereo metadata embedded in the video then our player will only decode the left eye. So we require videos without this metadata embedded.

    Using the FB Audio 360 tools you should be able to generate a MKV video file that doesn't contain any of the stereo metadata, but still contains the audio 360 metadata. The MKV audio channels should be in the Opus format. We list all of the requirements for this in the PDF documentation.

    I hope this helps you. In the future we plan to fix the issue with stereo metadata, and also plan to include a demo scene (and video) of the FB Audio 360 feature - probably in the next release (v1.9.0).

    Thanks,
     
  25. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Yes you are correct. Some of the MediaPlayer options aren't adjustable once the MediaPlayer is created. The best thing you can do is to destroy the MediaPlayer and create it again with the settings that you need. In the future I hope we can make more of these options switchable. We have this on our roadmap.

    Thanks,
     
  26. dmahajan_chicmic

    dmahajan_chicmic

    Joined:
    Aug 10, 2018
    Posts:
    1
    Hi Team, I am trying your trial version for AVPro Video. I am getting issue while streaming .mp4 video, It is playing audio only and displaying black texture. Here is the link for video displaying issue: https://www.dropbox.com/s/tmh1aois57gihw4/BlackTexture.mp4?dl=0,
    Please look into this and let me know how can I resolve this issue. Looking for your reply.

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

    Device Model : Galaxy S9 SM-G960F, Android Version: 8.0.0

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

    Here are the links for videos: http://52.17.12.187/uploads/2018/Jun/Empire.mp4, http://52.17.12.187/uploads/2018/Jun/Reactions.mp4

    System Information:

    AVPro Video: plugin v1.8.8t scripts v1.8.9
    Target Platform: Android
    Unity: v2017.4.8f1 OSXEditor
    OS: Desktop - Macmini7,1 - Mac OS X 10.12.6 - English
    CPU: Intel(R) Core(TM) i5-4278U CPU @ 2.60GHz - 4 threads - 8192KB
    GPU: Emulated GPU running OpenGL ES 3.0 - Emulated - OpenGL ES 3.0 [emulated] - 1536KB - 4096
     
  27. wurzelmedien

    wurzelmedien

    Joined:
    Jun 21, 2013
    Posts:
    4
    Hi,

    I am trying to get HLS Streaming on Android to work and it is working only partially.
    The problem:

    The video is playing correctly if internet is available, but after the internet connection was interrupted and video stopped playing, it is never starting again, although internet is available again. Only way to get it to run again is to restart it completely. On iOS HLS streaming is working correctly and video starts automatically again after internet reconnection.

    Unity: 2017.4.5f1
    AVProVideo: 1.8.9 (current version of Asset store)

    I tested it with the demo scene 02_Demo_imGui.
    it is not working with exoplayer api and not working with mediaplayer api.

    can someone help me to get it running on android or is this just not possible?
     
  28. Labmda

    Labmda

    Joined:
    Oct 21, 2016
    Posts:
    3
    hi all, please how i can simulate the button Load from interface avpro, i have try function play() but that do nothing when i use url for path
     
  29. pitt_unity

    pitt_unity

    Joined:
    May 9, 2018
    Posts:
    3
    Hi, I have a same problem. Is this bug fixed?
    1) AVPro Version: 1.8.9
    2) 2017.4.5f1
    3) Windows 10 - 1803
     
  30. Roycemedia

    Roycemedia

    Joined:
    Jun 26, 2018
    Posts:
    1
    Hi,

    We are using AVPro Video Trial to play live CCTV camera stream (HTTP stream and HLS stream). The live stream is hosted internally using a media server.

    Both streams (HLS & HTTP) work perfectly fine in Unity Editor, but not on WebGL (Edge browser). Thus, we are wondering if the plugin supports live stream on WebGL.

    Scene: 02_Demo_imGui
    Target Platform: WebGL
    AVPro Trial Version 1.8.9
    Unity Version 5.6.4f1
    Windows 10

    In addition, can AVPro support PTZ control of CCTV, as well as playback of CCTV stream?

    Lastly, will there be any updates on supporting HLS (.m3u8) on other browsers (E.g. Firefox and Chrome)?

    Thank you.
     
  31. toripopo

    toripopo

    Joined:
    Sep 15, 2017
    Posts:
    6
    Hi.

    I want to know how do I get http error response code while playing HLS streaming.
    Stalled event does not fired in AVProVideo windows 1.8.9, but in 1.7.3, stalled event fired when 50x http response received.
How do I know http error after start playing HLS in latest version of AVProVideo windows?

    Thanks,
     
  32. jpienbro_apollojourney

    jpienbro_apollojourney

    Joined:
    Jul 20, 2017
    Posts:
    11
    Hello

    We are currently developing a video recording app and using this plugin for the video playback but on multiple Android devices it seems to keep buffering forever. It mainly happens with videos with high framerates. Is that a limitation of the device or can I increase the buffer size somewhere?
    For example on my Nexus 6P the buffering gets stuck at 36% on a highspeed video. On my Galaxy S7 it can fully buffer that video.
    We need precise control of the video frame/time, that's why we're buffering everything first.
     
  33. spxyz

    spxyz

    Joined:
    Feb 7, 2014
    Posts:
    10
    Hello.

    I want to switch the audio mode runtime. How is it better to do this? Looks like this way does not work:

    Code (CSharp):
    1. if (multiChannel)
    2.         {
    3.             MP.PlatformOptionsAndroid.enableAudio360 = true;
    4.             MP.PlatformOptionsAndroid.audio360ChannelMode = Audio360ChannelMode.AMBIX_4;
    5.         }
    6. else
    7.         {
    8.             MP.PlatformOptionsAndroid.enableAudio360 = false;
    9.         }
     
  34. willisp

    willisp

    Joined:
    Sep 29, 2016
    Posts:
    2
    Hello @AndrewRH ,

    I'm curious, when is the next version of AVPro is going to come up?
    Is it going to support live subtitle tracks?

    Thanks a lot for you answer!
     
  35. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Version 1.9.0 will be released this week...Maybe even today.

    Thanks,
     
  36. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Currently you have to destroy and recreate the MediaPlayer component if you want to toggle the audio 360 option. An alternative could be to have two MediaPlayers, each with a different audio setting and toggle between them based on the file you want to play, and calling CloseVideo() on the other Mediaplayer. We hope to make this feature toggleable in the near future. Thanks,
     
  37. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Did you try setting the option in Global Settings: TimeScale support? This option is there to help video capture/recording of apps with video in (non real-time).

    We don't have any way to increase buffering size. What sort of high frame-rate videos you are talking about? 60hz or above? Perhaps you can send us more information and a sample file/code via email? (www.renderheads.com/contact/)

    Thanks,
     
  38. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hmm.. That's strange - the stalling behaviour should be improved in the new version. There is an error event...you could use that to detect an error...

    Is there an example you could send me (www.renderheads.com/contact/) so that we can test this?

    Thanks,
     
  39. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    In the last version (1.8.9) we just relied on the Web Browsers ability. In the upcoming version (1.9.0) we have added support for 3rd party Javascript libraries, like HLS.JS. The new version should be released this week and I think it will improve the HLS support, as these libraries are usually ahead of the browser implementations.

    AVPro Video has no support for PTZ.

    Again, in the new version we have support for HLS.JS, which will give support for HLS in Firefox and Chrome which don't have native support for HLS (unlike Edge).

    Thanks,
     
  40. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Take a look at the ChangeVideoExample.cs example script that is included in the package.

    Otherwise, try something like this to reload the current video:

    _mediaPlayer.OpenVideoFromFile(_mediaPlayer.m_VideoLocation, _mediaPlayer.m_VideoPath, true);

    Thanks,
     
  41. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    I presume it's working in the editor, but not on Android?

    This is strange.. Did you try using the ExoPlayer API (in MediaPlayer > Platform Specific > Video API)?

    I had a look at the video files, and they appear to contain very strange metadata...Perhaps there is sometihng in there that Android doesn't like - try reencoding the videos with something like Handbrake or FFMPEG.

    Thanks,
     
  42. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hmm...It should throw the Stall event, and then when the connection is restored throw the Unstalled event. At which point either the playback should resume, or you should have to send Play() command..Or maybe Pauses() and then Play() if there is a bug..

    Are you using the ExoPlayer or MediaPLayer video API? (in MediaPlayer > Platform Specific > Android > Video API)?

    Thanks,
     
  43. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Hmm..We will have to investigate this... Do you have a test URL? Please get in touch via email (www.renderheads.com/contact/)

    Thanks,
     
  44. pitt_unity

    pitt_unity

    Joined:
    May 9, 2018
    Posts:
    3
  45. jpienbro_apollojourney

    jpienbro_apollojourney

    Joined:
    Jul 20, 2017
    Posts:
    11
    The videos are 120fps and 240fps. The 240fps videos can't be buffered completely more often on some devices, probably because on the buffer size limit.
    Maybe we need to find a workaround for our app (if we can't change the buffer size), like limit the max fps for a recording.
     
  46. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    Thanks, we're investigating and will get back to you.
     
  47. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,634
    120 and 240fps videos are very much edge cases. A lot of decoders aren't designed to handle frame rates up to that high. Could you possibly record at 120fps but set the video to 30fps...then you can use PlaybackRate to play it faster, or even pause and scrub it...
     
  48. AndrewRH

    AndrewRH

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

    AVPro Video version 1.9.0 has just been released!

    You can find the updated version on the Asset Store and the free trial version on our website.

    Changes include:

    Android
    • Upgraded Facebook Audio 360 to version 1.6.0 from 1.5.0
    • Upgraded ExoPlayer to 2.8.4 from 2.8.2
    • ExoPlayer is now the default video API instead of MediaPlayer
    • Changed Android API level requirement to 15 from 16 when using MediaPlayer API (ExoPlayer still requires 16)
    Windows Desktop
    • Upgraded Facebook Audio 360 to version 1.6.0 from 1.5.0
    WebGL
    • Added support for 3rd party decoder libraries such as dash.js and hls.js, see documentation for details
    • Added warning for unsupported WebGL 2.0
    General
    • Added new (beta) PlaylistMediaPlayer component which allows seamless playlist progression and has a number of optional transitions, and a new demo scene using it
    • Added a new demo scene and video showing stereo 360 playback with spatial audio (on Windows and Android only)
    Minor
    • Resampler now has some support for videos with unknown frame rate
    • Sphere demo no longer has camera affected by VR positional head tracking
    • Added demo scriptlet to show how to toggle stereo mode via script
    Please report any issues here on the forum, or to our customer support email.

    Thanks,
     
  49. jpienbro_apollojourney

    jpienbro_apollojourney

    Joined:
    Jul 20, 2017
    Posts:
    11
    Thank you for the response
    We'll try that option.
     
  50. Jeeva1803

    Jeeva1803

    Joined:
    Aug 25, 2018
    Posts:
    2
    Hi,
    I want to play the video simultaneously while it is downloading via unitywebrequest. Will AVPro video support this? If so please provide me some guidance, as i am new to unity and avpro video.
    I can able to play the video which is downloaded fully through FullscreenVideo.prefab.
    Any help will be much appreciated!!!
     
unityunity