spoyser / spoyser-repo

XBMC Addons
15 stars 26 forks source link

WCO and animeuploads #49

Open bjgood opened 7 years ago

bjgood commented 7 years ago

Hi Sean, Great to see you back. I sort of knew you would return mainly because you're a great coder.

Anyway, my issue. It appears when a video host is selected that contains WatchCartoonOnline #1 576p HD....WCO can not play it. But, the second selection, WatchCartoonOnline #2 720p HD, will play. This is with AUTOPLAY enabled. Any way to discard/ignore the stream that contains 576p?

The Kodi log shows this when the 576p stream attempts to play...

[Code]09:43:21 3136.186768 T:1962688512 NOTICE: DVDPlayer: Opening: https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js 09:43:21 3136.187012 T:1962688512 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED 09:43:21 3136.187744 T:1578099616 NOTICE: Creating InputStream 09:43:22 3136.596191 T:1578099616 NOTICE: Creating Demuxer 09:43:22 3136.602783 T:1578099616 ERROR: Open - error probing input format, https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js 09:43:22 3136.602783 T:1578099616 ERROR: OpenDemuxStream - Error creating demuxer 09:43:22 3136.603027 T:1578099616 NOTICE: CDVDPlayer::OnExit() 09:43:22 3136.603516 T:1962688512 ERROR: Playlist Player: skipping unplayable item: 0, path [https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js][/Code]

The default.py>def GetLinkIndex seems to be the section that sorts the streams into individual selections.

Once again, glad to see you back. :).

I'm Trespasser from Kodi forum.

Best regards, Bob

bjgood commented 7 years ago

Hi Sean, I discovered that if you add "resolved.reverse()" to "def PlayVideo(_url, select):", such as follows... [Code] def PlayVideo(_url, select): resolved = resolve.ResolveURL(_url)

if len(resolved) == 0:
    url = None
    msg = 'Unidentified Video Host'
else:
    index = GetLinkIndex(resolved, select)
    if index == None:
        xbmcplugin.setResolvedUrl(int(sys.argv[1]), False, xbmcgui.ListItem(''))
        return

    resolved.reverse() # added by me

    resolver = resolved[index][0]
    url      = resolved[index][1]
    msg      = resolved[index][2]

[/Code]

all non-functioning links now play. As you know that code that I added just switched position of the bogus url (https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js) with the 720p HD url that does work. This problem that I mentioned in my first post only applies to episodes of a series that contain HD links. I'm sure you could find a far better solution than the one I came up with. But, for now, this seems to be working for me.

If you want to check it out yourself then try Garfield and Friends (the problem shows up really bad with this one...all links are 720p HD).

Just trying to help.

With greatest respect, Bob