SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Customizations
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI.

Reply
 
Thread Tools Search this Thread Display Modes
  #161  
Old 08-03-2009, 03:40 PM
tmiranda's Avatar
tmiranda tmiranda is offline
SageTVaholic
 
Join Date: Jul 2005
Location: Central Florida, USA
Posts: 5,851
Dumb question #1 - Where are the javadocs for the Phoenix API? I saw a mention of them somewhere but I can't find them.

Dumb question #2 - Is there a way to tell if the .jpg file returned by one of the phoenix APIs is 0 bytes in size? Sometimes phoenix returns a good file name (so the .jpg file exists) but the file is 0 bytes in size. I am specifically referring to the phoenix_api_GetFanartxxx() methods. If there is no way to tell directly from the API is there a java method that can be called to check for 0 byte files?
__________________

Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders.
Reply With Quote
  #162  
Old 08-03-2009, 04:21 PM
razrsharpe razrsharpe is offline
Sage Icon
 
Join Date: Sep 2008
Location: Boston, MA
Posts: 2,111
Quote:
Originally Posted by tmiranda View Post
Dumb question #1 - Where are the javadocs for the Phoenix API? I saw a mention of them somewhere but I can't find them.
don't know where the docs are but Sean comments his code very well. So i usually browse the source when i'm looking for and explanation of something.

http://code.google.com/p/sagephoenix...n/java/phoenix
__________________
Server 2003 r2 32bit, SageTV9 (finally!)
2x Dual HDHR (OTA), 1x HD-PVR (Comcast), 1x HDHR-3CC via SageDCT (Comcast)
2x HD300, 1x SageClient (Win10 Test/Development)
Check out TVExplorer
Reply With Quote
  #163  
Old 08-03-2009, 04:32 PM
MeInMaui's Avatar
MeInMaui MeInMaui is offline
SageTVaholic
 
Join Date: Feb 2005
Location: Maui. HI
Posts: 4,203
There is a ...Documentation/api subdirectory in the Phoenix API download. Find it and open index.html.

Aloha,
Mike
__________________
"Everything doesn't exist. I'm thirsty." ...later... "No, it's real!!! I'm full."
- Nikolaus (4yrs old)
Reply With Quote
  #164  
Old 08-03-2009, 08:41 PM
jreichen's Avatar
jreichen jreichen is offline
Sage Icon
 
Join Date: Jul 2004
Posts: 1,192
Quote:
Originally Posted by tmiranda View Post
If there is no way to tell directly from the API is there a java method that can be called to check for 0 byte files?
If you're still looking for a java method:
Code:
File file = new File(fileName);
long fileLength = file.length();
or to see if the file exists:
Code:
boolean fileExists = file.exists();
Sun's JavaDoc for the File api: http://java.sun.com/j2se/1.5.0/docs/...a/io/File.html
__________________
Server: Intel Core i5 760 Quad, Gigabyte GA-H57M-USB3, 4GB RAM, Gigabyte GeForce 210, 120GB SSD (OS), 1TB SATA, HD HomeRun.
Extender: STP-HD300, Harmony 550 Remote,
Netgear MCA1001 Ethernet over Coax.
SageTV: SageTV Server 7.1.8 on Ubuntu Linux 11.04, SageTV Placeshifter for Mac 6.6.2, SageTV Client 7.0.15 for Windows, Linux Placeshifter 7.1.8 on Server and Client
, Java 1.6.
Plugins: Jetty, Nielm's Web Server, Mobile Web Interface.

Reply With Quote
  #165  
Old 08-03-2009, 09:21 PM
tmiranda's Avatar
tmiranda tmiranda is offline
SageTVaholic
 
Join Date: Jul 2005
Location: Central Florida, USA
Posts: 5,851
Thanks to all.

@jreichen (or any other of you gurus!) How do I call these methods directly from Studio? There are only 1 or two sentences in the manual that seem to say you can call some java functions directly by substituting _ for . (or something like that.)
__________________

Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders.
Reply With Quote
  #166  
Old 08-03-2009, 10:41 PM
jreichen's Avatar
jreichen jreichen is offline
Sage Icon
 
Join Date: Jul 2004
Posts: 1,192
I do very little coding in Studio so I don't know how you would do it. I'm sure somebody else has done a lot of it and could show you. You might also try searching the forums for posts by other members - Opus4 and gkusnick come to mind.
__________________
Server: Intel Core i5 760 Quad, Gigabyte GA-H57M-USB3, 4GB RAM, Gigabyte GeForce 210, 120GB SSD (OS), 1TB SATA, HD HomeRun.
Extender: STP-HD300, Harmony 550 Remote,
Netgear MCA1001 Ethernet over Coax.
SageTV: SageTV Server 7.1.8 on Ubuntu Linux 11.04, SageTV Placeshifter for Mac 6.6.2, SageTV Client 7.0.15 for Windows, Linux Placeshifter 7.1.8 on Server and Client
, Java 1.6.
Plugins: Jetty, Nielm's Web Server, Mobile Web Interface.

Reply With Quote
  #167  
Old 08-03-2009, 11:22 PM
MeInMaui's Avatar
MeInMaui MeInMaui is offline
SageTVaholic
 
Join Date: Feb 2005
Location: Maui. HI
Posts: 4,203
They should look like this in studio:

Code:
java_io_File_length( filepath )
java_io_File_exists( filepath )
Aloha,
Mike
__________________
"Everything doesn't exist. I'm thirsty." ...later... "No, it's real!!! I'm full."
- Nikolaus (4yrs old)
Reply With Quote
  #168  
Old 08-04-2009, 05:32 AM
tmiranda's Avatar
tmiranda tmiranda is offline
SageTVaholic
 
Join Date: Jul 2005
Location: Central Florida, USA
Posts: 5,851
Thanks Mike.
__________________

Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders.
Reply With Quote
  #169  
Old 08-04-2009, 05:44 AM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
I am curious why you have any 0k files in your fanart folders? I believe there is a setting in BMI to not download 0k files. Then all you need is the hasfanart calls.
Reply With Quote
  #170  
Old 08-04-2009, 12:54 PM
tmiranda's Avatar
tmiranda tmiranda is offline
SageTVaholic
 
Join Date: Jul 2005
Location: Central Florida, USA
Posts: 5,851
Plucky,

I have not found that setting, where is it?

I also generally like to program as much error checking as possible. With the code I've written in the past "failure is not an option."

Tom
__________________

Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders.
Reply With Quote
  #171  
Old 08-05-2009, 07:18 AM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
Mike,

Have you used the gradient call. Is it not support to make a gradient of the fanart that is passed to it? I get a gradient but it it just a white to transparanent not the fanart to transparent Like I would expect.
Reply With Quote
  #172  
Old 08-05-2009, 10:53 AM
MeInMaui's Avatar
MeInMaui MeInMaui is offline
SageTVaholic
 
Join Date: Feb 2005
Location: Maui. HI
Posts: 4,203
Quote:
Originally Posted by PLUCKYHD View Post
Mike,

Have you used the gradient call. Is it not support to make a gradient of the fanart that is passed to it? I get a gradient but it it just a white to transparanent not the fanart to transparent Like I would expect.
That call probably shouldn't have been exposed. It is used to make the transparency mask that is used in the creation of reflections.

Aloha,
Mike
__________________
"Everything doesn't exist. I'm thirsty." ...later... "No, it's real!!! I'm full."
- Nikolaus (4yrs old)
Reply With Quote
  #173  
Old 08-09-2009, 04:25 PM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
How exactly are you suppose to pull poster based on seasons? I see it created the different season posters but everytime I pull the poster for on item under that season it just pulls the same poster regardless of the season.
Reply With Quote
  #174  
Old 08-09-2009, 06:07 PM
dblaine2 dblaine2 is offline
Sage Aficionado
 
Join Date: Jan 2005
Posts: 307
It seems Genres haven't been thought out yet in the API.

Although I am not a programmer and maybe this is already decided but I have a suggestion for how the Genres should be organized (basically following the same structure as TV and Movies).

Central Folder - Genres - Name of Genre - Backgrounds
------------------------------------------------- Posters
------------------------------------------------- Banners

Dave
Reply With Quote
  #175  
Old 08-09-2009, 06:08 PM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
Quote:
Originally Posted by dblaine2 View Post
It seems Genres haven't been thought out yet in the API.

Although I am not a programmer and maybe this is already decided but I have a suggestion for how the Genres should be organized (basically following the same structure as TV and Movies).

Central Folder - Genres - Name of Genre - Backgrounds
- Posters
- Banners

Dave
If you read back this has been discussed and will be added.
Reply With Quote
  #176  
Old 08-10-2009, 07:49 AM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
Quote:
Originally Posted by PLUCKYHD View Post
How exactly are you suppose to pull poster based on seasons? I see it created the different season posters but everytime I pull the poster for on item under that season it just pulls the same poster regardless of the season.
Stuckless to elaborate on this a bit

GetFanartPosterPath returns the correct Season 1, Season 2 etc folders for fanart

but when calling getfanartposter it is always returning the poster from season 1.
Reply With Quote
  #177  
Old 08-10-2009, 10:37 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by PLUCKYHD View Post
Stuckless to elaborate on this a bit

GetFanartPosterPath returns the correct Season 1, Season 2 etc folders for fanart

but when calling getfanartposter it is always returning the poster from season 1.
Plucky, you can add an issue for this in the BMT issue site... I'm using that to track both phoenix and bmt issues for now. If you add it there, then I won't forget about it
Reply With Quote
  #178  
Old 08-10-2009, 11:46 AM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
Quote:
Originally Posted by stuckless View Post
Plucky, you can add an issue for this in the BMT issue site... I'm using that to track both phoenix and bmt issues for now. If you add it there, then I won't forget about it
Done thanks didn't know about that will submit further issues on there. Thanks for submitting my other request as well.

Now get back to vacation
Reply With Quote
  #179  
Old 08-10-2009, 01:34 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by PLUCKYHD View Post
Done thanks didn't know about that will submit further issues on there. Thanks for submitting my other request as well.

Now get back to vacation
Unfortunately, vacation is done... until the last week of august... then I'm off again
Reply With Quote
  #180  
Old 08-12-2009, 01:41 PM
PLUCKYHD PLUCKYHD is offline
SageTVaholic
 
Join Date: Dec 2007
Posts: 6,257
Stuckless,

Excuse the newbie questions but trying to look at the java docs for the phoenix api and see how you are getting pictures in a folder regardless of the name. Is there an exposed call anywhere to send a path and get a .jpg?

thanks
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Phoenix card reader gravis12 Hardware Support 0 03-30-2008 01:38 PM
Missing API? GKusnick SageTV Studio 0 01-16-2007 08:48 PM
API Changes in 5.0 ? dflachbart SageTV Studio 11 05-09-2006 03:21 PM


All times are GMT -6. The time now is 02:23 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.