vimeo / vimeo-unity-sdk

Easily stream your Vimeo videos into Unity or record and publish out to Vimeo.
MIT License
210 stars 48 forks source link

Vimeo live stream, ArgumentOutOfRangeException #115

Open HVossi92 opened 4 years ago

HVossi92 commented 4 years ago

Describe the issue

Hello, I'm trying to access my vimeo live stream inside Unity, but all I get from the Vimeo Player is:

ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index System.ThrowHelper.ThrowArgumentOutOfRangeException (System.ExceptionArgument argument, System.ExceptionResource resource) (at <599589bf4ce248909b8a14cbe4a2034e>:0) System.ThrowHelper.ThrowArgumentOutOfRangeException () (at <599589bf4ce248909b8a14cbe4a2034e>:0) System.Collections.Generic.List`1[T].get_Item (System.Int32 index) (at <599589bf4ce248909b8a14cbe4a2034e>:0) Vimeo.VimeoVideo.GetVideoFileByResolution (Vimeo.Player.StreamingResolution resolution) (at Assets/Vimeo/Scripts/Config/VimeoVideo.cs:217) Vimeo.VimeoVideo.GetVideoFileUrlByResolution (Vimeo.Player.StreamingResolution resolution) (at Assets/Vimeo/Scripts/Config/VimeoVideo.cs:193) Vimeo.Player.VideoController.PlayVideo (Vimeo.VimeoVideo _vimeoVideo, Vimeo.Player.StreamingResolution resolution) (at Assets/Vimeo/Scripts/Player/VideoController.cs:110) Vimeo.Player.VimeoPlayer+d50.MoveNext () (at Assets/Vimeo/Scripts/Player/VimeoPlayer.cs:207) UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at C:/buildslave/unity/build/Runtime/Export/Scripting/Coroutines.cs:17) UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator) Vimeo.Player.VimeoPlayer:Play() (at Assets/Vimeo/Scripts/Player/VimeoPlayer.cs:196) Vimeo.Player.VimeoPlayer:VideoMetadataLoad(String) (at Assets/Vimeo/Scripts/Player/VimeoPlayer.cs:377) Vimeo.VimeoApi:ResponseHandler(UnityWebRequest) (at Assets/Vimeo/Scripts/Services/VimeoApi.cs:217) Vimeo.d37:MoveNext() (at Assets/Vimeo/Scripts/Services/VimeoApi.cs:236) UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr) (at C:/buildslave/unity/build/Runtime/Export/Scripting/Coroutines.cs:17)

I've also tried using the AVPro Mediaplayer (free trial), which just tells me:

[AVProVideo] Error: Loading failed. File not found, codec not supported, video resolution too high or insufficient system resources. UnityEngine.Debug:LogError(Object) RenderHeads.Media.AVProVideo.MediaPlayer:UpdateErrors() (at Assets/AVProVideo/Scripts/Components/MediaPlayer.cs:1791) RenderHeads.Media.AVProVideo.MediaPlayer:Update() (at Assets/AVProVideo/Scripts/Components/MediaPlayer.cs:1109)

If I mistype the link on purpose, the Vimeo Player tells me, that it couldn't find the video. So that I am getting theArgumentOutOfRangeException feels like it at least found the stream? If I am missing something obvious, I apologize. Thank you in advance for any help.

Steps to reproduce the problem

Create Vimeo Player Get video by ID or URL Start vimeo live stream Copy link and paste into Vimeo Video Url

Unity version

2019.2.8f1

Operating system

Win10

WeAppU commented 4 years ago

Same here... So Bad :-(

jonasfehr commented 4 years ago

Same here

OscarGutierrezT commented 4 years ago

Same here...

DiegoAyalaE commented 4 years ago

Same here.

mikeskydev commented 4 years ago

Same here

WaltzBinaire commented 4 years ago

Hi there, any plan on working on live streams for this sdk? Thanks

thomasvanta commented 4 years ago

Is there a plan to fix this or should we look into other alternatives?

BenjaminKeating1986 commented 4 years ago

Do the devs even look at this?

DragontaleStudio commented 3 years ago

Whenever we select a fixed resolution eg X360p, and not the "adaptive" choice, we get the aforementioned ArgumentOutOfRangeException.

Looking into it, it seems like the JSON response doesn't include the "progressive" attribute and thus the progressiveFiles array has 0 length.

chalise94 commented 3 years ago

Hello I am also getting the same issue. Please let me know if there is a way to run live streams for this sdk?

muthuselva commented 3 years ago

I fixed it using avpro and adaptive resolution.

Just replace the isHlsPlatform() function in VimeoVideo.cs with following ,

public bool isHlsPlatform() { return Application.platform == RuntimePlatform.OSXPlayer || Application.platform == RuntimePlatform.OSXEditor || Application.platform == RuntimePlatform.IPhonePlayer || Application.platform == RuntimePlatform.tvOS|| Application.platform == RuntimePlatform.WindowsEditor|| Application.platform == RuntimePlatform.Android; }

milkywaystars commented 1 year ago

Gefting same error 2023?? I got the premium Tier. Contacted Support and they don't know what Unity3D is. So had to give up. Its a shame. I wonder if I need to install another 3rd party tool called "avpro"?? Viewing normal videos work fine. ie from your own Business account. Won't work with "Basic Account".