"Play next song automatically" in plugin - doable?

  Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
mbetter Offline
Member
Posts: 62
Joined: Nov 2010
Reputation: 0
Post: #16
mbetter Wrote:I got it working by using SetResolvedURL.

I would like to know if it's possible to do it without SetResolvedURL as my current plugin doesn't really need it (AFAIK) and it introduces a redundant plugin call in between songs.

Can I bump this? SetResolvedURL adds like five seconds to the gap between songs and it's really starting to bother me.
find quote
jmarshall Offline
Team-XBMC Developer
Posts: 26,181
Joined: Oct 2003
Reputation: 175
Post: #17
Do a debug log - you should not require SetResolvedUrl at all.

Cheers,
Jonathan

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


[Image: badge.gif]
find quote
divingmule Offline
Skilled Python Coder
Posts: 1,297
Joined: Oct 2008
Reputation: 61
Post: #18
Hi, I'm working on the internet archive add-on and I can't seem to get this to work either.

Here is the current code I'm working with ->http://code.google.com/p/audio-archive-x...default.py

Here is a log ->http://pastebin.com/W3vMnnDN

Any help is much appreciated.
find quote
SniperCharlie Offline
Junior Member
Posts: 23
Joined: Mar 2008
Reputation: 0
Post: #19
I'm also having trouble auto-playing the next track in a plugin I'm developing.

The URL gets redirected to the media file - perhaps that is the error we are getting, and the reason setresolvedurl is a workaround.

I'm using the following to add the links:

Code:
def addLink(name,url,iconimage):
    ok=True
    liz=xbmcgui.ListItem(label=name,thumbnailImage=iconimage)
    liz.setProperty("mimetype", 'audio/mpeg')
    liz.setInfo("music", {"title": name,})
    liz.setProperty("IsPlayable", "true")
    xbmcplugin.setResolvedUrl(handle=int(sys.argv[1]), succeeded=True, listitem=liz)
    return ok
find quote
jmarshall Offline
Team-XBMC Developer
Posts: 26,181
Joined: Oct 2003
Reputation: 175
Post: #20
It works only for audio plugins. That is, plugins that set their provides attribute to include "audio".

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


[Image: badge.gif]
find quote
SniperCharlie Offline
Junior Member
Posts: 23
Joined: Mar 2008
Reputation: 0
Post: #21
Am I missing something?

Thanks for your help!

Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="plugin.audio.hypem"
       name="Hype Machine"
       version="0.0.1"
       provider-name="Snipercharlie">
  <requires>
    <import addon="xbmc.python" version="1.0"/>
  </requires>
  <extension point="xbmc.python.pluginsource"
            library="default.py">
        <provides>audio</provides>
  </extension>
  <extension point="xbmc.addon.metadata">
    <platform>all</platform>
    <summary lang="en">Hype Machine</summary>
    <description lang="en">The Hype Machine is a music blog aggregator, that can provide you with your own customized playlist feeds, and expose you to new music - ad free!</description>
  </extension>
</addon>
find quote
jmarshall Offline
Team-XBMC Developer
Posts: 26,181
Joined: Oct 2003
Reputation: 175
Post: #22
In addition, it was only working after about b2.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


[Image: badge.gif]
find quote
SniperCharlie Offline
Junior Member
Posts: 23
Joined: Mar 2008
Reputation: 0
Post: #23
Is that Beta2 for Eden?

Sorry - I didn't mean to hijack this thread. But the auto-play next works in Dharma 10.1 for other audio plugins such as the Soundcloud plugin.

However - I went through their code - they are using the xbmcplugin.setResolvedUrl parameter - which has been documented as a work around. From my limited understanding, this would necessitate two calls to the plugin for each item, rather than the current form of just listing it once. Was this the only way to auto-play an item pre Eden B2?

I'll install the most recent Eden Beta and see if its working there.

Thanks for your help!!!
find quote
SniperCharlie Offline
Junior Member
Posts: 23
Joined: Mar 2008
Reputation: 0
Post: #24
Just installed my plugin in Eden B3. Auto play next item works great!!!!

Thanks so much for this awesome app guys - Eden is looking INCREDIBLE! So glad I can finally contribute something to the group - should have my plugin out within the week.
find quote
Post Reply