WebServer HTTP API (HttpApi): for PocketPC and Web-client Remote Control Apps - Printable Version
+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Development (/forumdisplay.php?fid=93)
+--- Thread: WebServer HTTP API (HttpApi): for PocketPC and Web-client Remote Control Apps (/showthread.php?tid=8760)
- TeknoJuce - 2006-01-13 09:33
Quote:technojuce: setplaylistsong takes an integer parameter which is the position or the required media within the current active play list.yup i knew that was just asking if you could added a secondary function to it how it says in the apidoc no biggy found away around my problem by specifying the count from my listbox control to = the playlist item number subtracted by 1 cuz apperently playlist start at 0
Quote:there is an addtoplaylist command.ummm yup... quote:i know you can add del and clear so far ...
Quote:have you seen the api docs which is on the sourceforge xbmc download page?i acaully just quoted directly from it in my post
and was pointing out with my:
Quote:!hmm--> or the file name of the song at position position within the current playlist.that it kinda states right there the funtion i was requesting at the time :thumbsup: just that it doesnt acually work...
Quote:you can't create a play list file itself through the api. however, most play list file syntax is very straightforward so you should be able to do this yourself through some client code and then use the api to upload the file, fileupload.thats unfortunate can you atleast make so you can trigger a virtualplaylist or something to that degree ?
anyways awesome job with the httpapi keep it up! :o
- kraqh3d - 2006-01-13 22:12
Quote:is there anyway to create a playlist and save it throught the httpapi?
what do you want to do exactly? do you just want to be able to save a running playlist to the xbox hard drive like "save" button does when at the now playing window?
- Cosworth - 2006-01-15 10:23
i might have missed this over the last 17 pages in the thread, but is this ppc bug known?:
"when a video is running on xbox, xbmccontrol crashes on startup."
i have a trailer python script running on startup, so this happens frequently for me. only way to avoid it (besides the obvious solution to stop the video first) is to press stop in xbmccontrol before it starts "refreshing"
- TeknoJuce - 2006-01-16 13:11
** edit **
sorry!!! i editted your post by accident and my reply overwrote your post.
- kraqh3d - 2006-01-16 15:59
it looks like addtoplaylist will work without an existing playlist if you provide the playlist number as a parameter like this:
this sort of requires knowledge of the xbmc source code, so i'll try to explain... xbmc has four internal playlists:
playlist_music = 0
playlist_music_temp = 1
playlist_video = 2
playlist_video_temp = 3
playlist_music and playlist_video coorespond to whats in the music and video now playing windows. they are visible playlists. users can queue items into them and see what they've queued.
playlist_music_temp and playlist_video_temp are invisible to the user. they are completely internal to xbmc. they are temporary adhoc playlists. this is what's used when you use "play" on a folder in music or video. the items are queued up into the appropiate temp playlist and played. there's one big difference between the two. as soon as the user uses "play" an another folder, the previous temp playlist is deleted and the new items are immediately added.
looking further ar the code, all the playlists related commands take a playlist parameter, but whenever the playlist parameter is missing, it'll default to the current playlist. you could use setcurrentplaylist first.
take a look at the docs. it looks like nad put alot of time into it.
and i'll try to get saveplaylist added in a few days.
- TeknoJuce - 2006-01-17 08:32
okay thanks kraqh3d for the nfo and yes as ive stated before ive used the doc.. only way i would have got as far as i am now if you viewed the screenshot in my above post
soooo... ive tried the:
tried 0 to 3 all came up with error:unknown command
so then i tried setcurrentplaylist it said ok but didnt seem to do anything and still wouldnt let me add stuff to a play list
then i acidently tried setcurrentplaylist while i had a song going and that apperently starts a playlist with the current song running.. imagine :lol: then i did a bunch more testing and found out the routine you must:
1.) play a song with playfile:
2.) add file to playlist:
3.) set the current playlist to 1:
4.) grab the playlist content:
^---hopefully this routine is correct if not please post correct order (or if theres an easier way)---^
unfortunatly you cant additemtoplaylist directories cuz you cant play one of the songs in the directory while adding.. so you have to add a single song first to the playlist and then you can add a directory which is kinda tedious :tear:
seems to do it now just need that save option :thumbsup:
- Drongo - 2006-01-17 12:10
also have i got the syntax correct for the setresponseformat command as it does not seem to work at all.
- kraqh3d - 2006-01-17 14:28
i dont know why you would have to do "playfile" before "additemtoplaylist" to get it to work. that makes no sense. yes, "setcurrentplaylist" tells xbmc to start playing that playlist. but i would expect that you should be able to do "getplaylistcontents" regardless of if the playlist is the current playlist or not. i'll check this all out on the weekend.
- TeknoJuce - 2006-01-17 16:08
alright great stuff kraqh3d yeah i have no clue why a song has to be playing... its only on a freshboot.. if you already have a playlist up then its not needed.. its strange.. just like how the playfile cant play a m3u file on fresh boot but playmedia exteral can.. and playfile can only if you had a playlist loaded before hand ie not fresh boot
anyway to get to view inside of rars kinda like how the webface does it
10-01-2004 23:06:28 debug rardirectory::getdirectory() retrieved file: rar://z:\,1,,smb://192.168.1.104/f/z-music/soundtracks/ost - human traffic(1999.128kbps).rar,\ost - human traffic\cd1\
10-01-2004 23:06:40 debug cplayercorefactor::getplayers(rar://z:\,1,,smb://192.168.1.104/f/z-music/soundtracks/ost - human traffic(1999.128kbps).rar,\ost - human traffic\cd1\02 - cj bolland - it ain't gonna be me.mp3)
maybe with getmedialocation & playfile support or something unless this is already there but i think the webface has more access to internal controls then the common commands beacuase i tried with getdirectory no go there?
- TeknoJuce - 2006-01-25 14:45
kraqh3d did you die on me budday!?
- kraqh3d - 2006-01-26 16:50
been busy. havent had much time to even visit the forums. rar's and zips are a special case. they are implemented as hidden on-the-fly shares that are added as they are opened and deleted when closed. the current getdirectory function doesnt handle this special case, yet. i'm not sure when i'll have the time to look into it.
- TeknoJuce - 2006-01-26 16:57
what are you busy doing anything intresting?
- kraqh3d - 2006-01-26 17:08
life. it takes precedence over this.
- TeknoJuce - 2006-01-29 17:18
so is there no way for rar browsing/playing being availible to getmedialocation?
- kraqh3d - 2006-01-30 01:08
not without the code to support it.