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
  #1  
Old 11-04-2005, 10:31 AM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Arrow STV: GermSage -- Default STV enabling external players and more (v1.7 / 2006-Apr-03)

GermSage
Version 1.7 - 2006.Apr.03
Staying true to SageTV's default v4.0.0 and inspired by Cayars
With code assistance from MLBDude and Stanger89

Summary and Purpose:
This STV is designed to be very close to the original uncluttered default Sage v4.0.0 STV, but with added feature functionality found only in various add-on STVs without breaking STV import capability.

I designed this edit primarily to enable the use of external video players within Sage. Like a few other users, I have been encoding my DVD collection into MP4 AVC files, which currently and absolutely cannot be played inside of SageTV's media player. Cayars STV introduced the ability to play media files with an external player, and has allowed myself and others to use our MP4's (as well as Quicktime MOVs, etc) with Sage. With this update, the new Sage v4 family can use external players. Various other "toys" have been added to the back-end of the STV, allowing the use of external metadata with your video library (*.my or collection.xml files)

File:

LINK DOWN DUE TO WEBSITE AND HOSTING ISSUES...

Download v1.7

Features:
  • All the features of SageTV v4.1.3, including STVi Imports.
  • Ability to use external video players.
  • Ability to use external DVD players rather than the Sage one.
  • Reads .my files and DVD Profiler XML files to display movie metadata for any encoded media found in the import library.
  • Can create .my files from broadcast recordings, in the event you want to re-encode them and bring them back into your import library with episode information intact.
  • Tweaks the delete behavior a bit. When deleting episodes of a show which you have many episodes, I've adjusted the behaviour of the delete action so that it doesn't return you to the "main" Recorded Programs list. It will keep you in the folder of episodes you are working with.
  • Allows you to turn on/off the SageTV "Autorun" feature which pops up a message when you insert a new disk drive or USB storage device.


Prerequisites:
  • GermSage 1.7 uses features found in SageTV 4.1.3. Compatability with earlier versions or later versions is NOT assured.
  • A basic knowledge of using 3rd party STV's is recommended.
  • Users of earlier versions of GermSage may need to manually edit their .properties files in order to activate GermSage 1.7

Installation:

DISCLAIMER: I cannot be held responsible for any damage to your SageTV installation OR your video and media libraries that may result from you using this STV. I would recommend backing up your data and information (eg: use test media directories) to insure this STV will function in your environment.

  • Shut down SageTV
  • Unzip the archive into your C:\Program Files\SageTV\SageTV\ directory, or to the equivilant directory on your computer. Maintain the folder structure, as there are some files which need to populate out to their specific areas. (If you happen to see this after installing, doublecheck the location of your install.)
  • Start Sage, and browse to Setup > Detailed Setup > Advanced - Select the GermSage_v1.7.xml to be used. If you are using GermSage 1.6, you will need to edit your sage.properties/sageclient.properties file manually to find the newer XML formatted STV.
  • Installed!

Setting up for external video players

Using external players can be a very useful feature. In my case, I have encoded all my DVD's to NeroDigital using their MP4 / AVC method - unfortunately, while it is a very effective compression, it cannot be played in SageTV. By using an external player, I can watch my movies in the import library without having to leave Sage!
  • Exit Sage once more, and search your Sage.properties or SageClient.properties file for the following line...

    seeker/video_library_import_filename_extensions=

    ...and add any extensions you need that aren't listed. I had to add the .mp4 extension for my NeroDigital AVC's in order to make them visible in my Media Library.
  • If you've used Cayars17 and have customized the external player .cmd files, you can copy them into the \Externals directory - they are the same files. Otherwise, you will probably want to edit the included .cmd files to suit your external player needs. You will need to refer to the .cmd files to see how it's done.
  • In Setup > Detailed Setup > GermSage - Set the options as you require, and exit the options area.
  • Use External Video Players - Makes SageTV launch an external video player when launching media.
  • Use Exernal Players for Non-Native Only - When turned ON, this will not play MPEGs or other "native" media types externally. When turned OFF, *ALL* media, including pre-recorded material, will play externally. Turning this ON is the default, but some of you with AC3 audio in an MPG container may prefer this to be off.
  • Use External DVD player - Makes SageTV launch an external DVD program when playing DVD movies.
  • External video players may not be used for live TV or any TV programming which is still being recorded. This is due to either A.) a limitation in the way Sage handles such programs, or B.) a limitation in my understanding of the way things work. Could be either. If you have set the Non-Native Only option to false, the system will force the use of the SageTV media player when watching live or still-recording television.

Setting up for XML file reading

If you use the video library like I do, you will have a plethora of files with NO information associated to them. Using DVD Profiler, you can create a collection.xml file that contains a movie overview, picture, and actors list. This STV will look at the XML information and use it to give you more details on your imported movie media!
  • If you have a collection.xml file, place it in the \STVs\SageTV3\Externals directory. Using a collection file is the preferred method, because you have a single file with all your movie's information within it as opposed to one file per movie or show. You may customize this location by editing your .properties file if you wish.
  • If you have individual XMLs for each media file, they should be placed along side the media. You must be sure that the individual XML file AND the title property inside it is spelled exactly like the media file name.
  • To use DVD Profiler cover art, browse to Setup > Detailed Setup > GermSage and set the option for your images directory. I'd recommend moving your image files to the server, and declaring it from there - perhaps using UNC paths would be good here!
  • When using XML files, insure that your media's file name, and the "Title" XML field are identical!! If not, it will not be recognized.

Setting up for .my file reading

.My files work very similarly to the XML files, although they are much more accessable! You can read more about .my files in a section below. GermSage is set up to read .my's right out of the box.
  • .My files only need to be installed along side your media files. All .my files must be named EXACTLY the same as the media file they are describing. .my files will automatically be read if found.
  • I've placed some basic information on creating .my files to the bottom of this post.

Setting up to WRITE .my files

When using Sage, you've noticed that it contains all the information on your program at your fingertips - but what happens if you take one of your MPEG recordings and turn it into a XVID, AVI, or MP4? All that data goes away... until now!
  • Head over to Setup > Detailed Setup > GermSage and turn on the "Create MY files" option. This will create a .my file for EVERY recorded television show in your TV directories.
  • When you take a file out to re-encode it, just keep the .my file along for the ride.
  • If you put the video file back into your Imported Video library, the .my file will be read, and it will populate the detailed info screen with much of the same information you had when it was native to Sage!

Maintenance and Cleanup Features

With .my files being created, it's important to keep things clean. As you delete MPEG recordings in Sage, any created .my files won't automatically delete themselves. I've brought over the abilility to delete "orphan" files - files which no longer are associated with existing media.
  • Head to Setup > Detailed Setup > GermSage and choose the "Delete Orphans" option. It will search your Television directories for lonely files, and ask you if they should be deleted. Say yes, and say goodbye! Say no, and they're kept.

Also, a nice feature of some STVs was the ability to delete "partial" recordings. Maybe you stopped taping something midstream, but the file is still there. The other cleanup option available to you is to remove these partial files.
  • Head to Setup > Detailed Setup > GermSage and as you might imagine, choose the "Delete Partials" option. It will search your Television directories for incomplete files, and ask you if they should be deleted. Say yes, and say goodbye! Say no, and they're kept.

Turning off the SageTV Autorun Feature

If you're anything like me, you hate intrusions into your GUI when inserting CD's, USB2 drives, or any other storage media. This goes for SageTV too! Version 4.0.0 added the feature that will pop a menu up when you insert a new drive - I was ticked off at that, so I made a switch for it!
  • Head to Setup > Detailed Setup > GermSage and toggle the "autorun" selection to your choosing!

The code that makes this possible is the result of Carlos Ayars, MLBDude, and Stanger89 - all thanks go to them! Cayars for giving me the ideas and the source for the basics, MLB for his XML integration example, and Stanger for his java expertise.

Additionally, the XML and .my file reading/writing features were encouraged by DVD_Maniac - without his interest, I probably would have stopped development a while ago.

The next thing I'd like to figure out is how to modularize the changes I made into an STVi. I couldn't figure that out - ideally speaking, the ability to package my changes into a smaller importable module would be perfect. I guess I'll have some more reading to do before I can succeed at that!

====-----About .my files....-----====

This STV can read media library .my files. They are simple text files which contain information about your videos. I use .my files to give more information about my MP4 movies. A sample .my file is below...

This is for "Almost Famous.mp4" - The .my file must be named the same, except for the extension...

"Almost Famous.my"
Code:
title=Almost Famous
released=1999
overview=A movie about sex, drugs, and rock n' roll.
actors=Jane Doe, John Doe, Doe John, Doe Jane
The STV will read what follows the = sign and populate a field on the Detailed Information screen for that particular movie. Simple as that! It's a neat little way of adding some descriptive information to your media library.

The .MY files I am creating for the Television Programs use a different set of variable names - you can look inside of them to see what they are (almost all are prefaced by TV)

====-----V e r s i o n H i s t o r y-----====

1.7 - Been a while! Added code to play nicer with current stable version 4.1.3
- Detailed Setup > Advanced - Now sees XML STV's.
- Detailed Setup > Customize - Added some items found in the stable version (fade option, alt movie category...)

1.6 - Bugfix to enable .my files reading/writing of OriginalAiringDate field
1.5 - Switched from .xml creation to .my creation of recordings due to technical issues beyond my knowledge.
1.4 - Creates .xml files of recordings.
1.3 - Now reads .my and .xml files.
1.2 - Bugfix for reentrancy and "LiveTV" errors with external players.
1.1 - Tweaked the GUI back to defaults to keep within project goals.
1.0 - Brand spankin' new!

Last edited by greggerm; 01-17-2007 at 07:59 AM.
Reply With Quote
  #2  
Old 11-04-2005, 10:51 AM
jzaman jzaman is offline
Sage User
 
Join Date: Jan 2005
Posts: 10
Greg,

Downloaded your mod. Will test it out. Thanks for all your efforts.

Last edited by jzaman; 11-04-2005 at 05:42 PM.
Reply With Quote
  #3  
Old 11-04-2005, 03:07 PM
dvd_maniac's Avatar
dvd_maniac dvd_maniac is offline
Sage Icon
 
Join Date: Mar 2004
Location: New England
Posts: 1,899
As I said before "Greg, You Da Man!"

Thanx.
__________________
If this doesn't work right, Then:
"I'm going to blow up the Earth!"
Reply With Quote
  #4  
Old 11-04-2005, 03:27 PM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Quote:
As I said before "Greg, You Da Man!"
Only if it works!
Reply With Quote
  #5  
Old 11-04-2005, 03:32 PM
ToxMox's Avatar
ToxMox ToxMox is offline
Sage Icon
 
Join Date: Oct 2003
Location: NJ
Posts: 1,980
Pretty cool. I hate to be a nitpicker but it should be Cayars not Cayers.
Reply With Quote
  #6  
Old 11-04-2005, 04:03 PM
Humanzee's Avatar
Humanzee Humanzee is offline
Sage Fanatic
 
Join Date: Sep 2004
Location: North Idaho
Posts: 752
Is it possible to build this into an STVI file so that we can import it into any STV?
Reply With Quote
  #7  
Old 11-04-2005, 04:46 PM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
ToxMox - Duly noted and changed! And to think I've been referring to him with that spelling for a loooong time

Quote:
Originally Posted by Humanzee
Is it possible to build this into an STVI file so that we can import it into any STV?
I couldn't tell 'ya, although that would probably be the next place I'd take this. I'll have to spend some time looking at Neilm's imports over the next few weeks (and the just posted info) to see if I can mimic the way they are written.

But before I even think about that, I am off to play with my own HTPC!
-Greg
Reply With Quote
  #8  
Old 11-04-2005, 04:47 PM
mlbdude's Avatar
mlbdude mlbdude is offline
Moderator
 
Join Date: May 2003
Location: Melbourne, Florida
Posts: 4,174
Quote:
Originally Posted by Humanzee
Is it possible to build this into an STVI file so that we can import it into any STV?
Not any STV, but any STV that had the same code as the Origional. So it could work any on that are based on the standrd STV.
Reply With Quote
  #9  
Old 11-04-2005, 07:07 PM
jzaman jzaman is offline
Sage User
 
Join Date: Jan 2005
Posts: 10
Greg,
Your mod does the trick with a few changes for my use. Since I play mpg files in Powerdvd the VideoPlayer.cmd is:

"C:\Program Files\CyberLink\PowerDVD\PowerDVD.exe" %1

Also in this case the Sage properties file must have Non_Native_Types set to false. No changes in the seeker section required.

External/External_Players_Non_Native_Types_Only=false
External/External_Video_Player=true
External/External_DVD_Player=true

Thanks again for making v4 even better.
Reply With Quote
  #10  
Old 11-04-2005, 09:59 PM
mkanet's Avatar
mkanet mkanet is offline
SageTVaholic
 
Join Date: Feb 2004
Posts: 3,359
Can somebody explain to me how this works?

How do the external players interact with SageTV? How does the external player know to exit correctly and return to SageTV to the menu where it launched from?
__________________
Upgraded to Comcast X1 + Netflix/Amazon Video streaming

***RIP SageTV***
Reply With Quote
  #11  
Old 11-05-2005, 12:19 AM
Ryokurin's Avatar
Ryokurin Ryokurin is offline
Sage Aficionado
 
Join Date: May 2004
Posts: 455
Send a message via ICQ to Ryokurin Send a message via AIM to Ryokurin Send a message via Yahoo to Ryokurin
Has anyone had the issues of some files (mpegs in partitular) play with the sage player as well as the external player? Depending on the speed of which one launches it echos or you pause the external player and you still hear sage's running in the background.
Reply With Quote
  #12  
Old 11-05-2005, 09:06 AM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Quote:
Originally Posted by Ryokurin
Has anyone had the issues of some files (mpegs in partitular) play with the sage player as well as the external player? Depending on the speed of which one launches it echos or you pause the external player and you still hear sage's running in the background.
As I launch MP4's not playble in Sage, I haven't noticed this - BUT, I HAVE noticed what looks like Sage TRYING to play my MP4 in the background, even though it was put to sleep. This pops an error on Sage, but it is quickly removed when the player comes out of sleep - but sometimes I see the error on the screen just before the main menu. It also seemed to cause my SageClient machine to hang if I didn't watch enough of the MP4, while the internal player negotiates then finally times out with the error.

Looks as though there is a hiccup in the coding when it switches out to the external player.

I am pretty tied up today, but I'll be looking at it hopefully late tonight or tomorrow morning.

yay! my first bug!
-Greg
Reply With Quote
  #13  
Old 11-05-2005, 10:56 AM
jzaman jzaman is offline
Sage User
 
Join Date: Jan 2005
Posts: 10
Greg,

I am confirming that there is a small reentrancy bug:
When exiting out of an external player (in my case powerdvd 6) the audio stream will continue to play. However, it is still a big improvement over the Sage default Video viewer.

I have also been toying with MC2005, Meedio and BTV over the last sixteen months. Since I want to stick with the mpeg format not dvr-ms or wmv and I also want media player functionality I still look to Sage for satisfaction.

I was running with Cayars 18E for a while but I was hoping that the unmodified version 4 would natively build in support for external players. The default Video viewer will not let you select the specific audio stream. Obviously I can use Sage only as a PVR and relegate the viewing of my mpegs outside of the Sage front end. But that would be cheating..

Last edited by jzaman; 11-05-2005 at 12:41 PM.
Reply With Quote
  #14  
Old 11-05-2005, 11:46 PM
dvd_maniac's Avatar
dvd_maniac dvd_maniac is offline
Sage Icon
 
Join Date: Mar 2004
Location: New England
Posts: 1,899
Hi Greg,

What happens when you go to the LiveTV guide and hit Watch Now? For me it opens up Zoom Player, then doesn't play anything. Kinda the same problem Cayar's had.
__________________
If this doesn't work right, Then:
"I'm going to blow up the Earth!"
Reply With Quote
  #15  
Old 11-06-2005, 12:34 PM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Both problems seem fixed! Try out the new download at the top of the thread...

Thanks for testing this out, guys!
-Greg
Reply With Quote
  #16  
Old 11-06-2005, 12:45 PM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Quote:
Originally Posted by mkanet
Can somebody explain to me how this works?
Ok -

Using External Players, with DVD as the example:

When you request to watch a DVD, Sage checks to see if you have the exernal DVD player option set in your .properties file. If you do not, it will launch it's internal DVD player and you'll see the familier SageTV DVD playback screen.

If you do have the setting, Sage goes to sleep! It minimizes out of the way and launches the program you call for in your .cmd file (*included with the edited stv). I personally use PowerDVD. PowerDVD can use keyboard commands to be controlled, so I set my Hauppaugue remote control to send the needed keyboard commands.

When PowerDVD closes and exits, Sage is waiting. Through what looks like some Java code, it detects when the program is done, then WAKES Sage back up. You then get your main menu, and it's like nothing had happened!

The same thing happens with the external video player. I use ZoomPlayer for my MP4 NeroDigital encodes, so I browse over to the Media Library, open the videos up, and select an MP4 movie. This minimizes Sage, launches my player, and when I'm done, Sage wakes up.

Pretty cool stuff. I take no credit for it - I just ported it from Cayars to v4!
-Greg
Reply With Quote
  #17  
Old 11-06-2005, 06:43 PM
jzaman jzaman is offline
Sage User
 
Join Date: Jan 2005
Posts: 10
Nice final touches. Excellent and cleanly done. This is the icing on my cake. (My birthday was Friday). I can now fully use Sage as my HTPC. Thanks.
Reply With Quote
  #18  
Old 11-07-2005, 07:31 PM
greggerm greggerm is offline
Sage Advanced User
 
Join Date: Feb 2004
Posts: 175
Thanks for the kind words - I read that post to the girlfriend and she said...

"That's really nice! You're still a big nerd, though."

...of course, she says that while browsing recorded shows on Sage.

Time to take the evening off.
Minor STV updates posted to the top-of-thread file. Yay! .my files!
-Greg
Reply With Quote
  #19  
Old 11-07-2005, 07:51 PM
ToxMox's Avatar
ToxMox ToxMox is offline
Sage Icon
 
Join Date: Oct 2003
Location: NJ
Posts: 1,980
I like the use of the smileys in the first post
Reply With Quote
  #20  
Old 11-08-2005, 07:24 AM
dragon's Avatar
dragon dragon is offline
Sage User
 
Join Date: Mar 2004
Location: Baton Rouge, LA
Posts: 61
Thank you for the STV! It solved my number 1 problem with v3.

Before v3, I was running Cayars17 and PowerDVD as my external DVD player. When I switched to v3 and v4, I lost that ability.

This would not have been too bad, except that the internal DVD player didn't pick up one of the audio streams correctly. I had to turn the volume all the way up on my TV to be able to hear normal level sounds.

A better understanding of the problem, and the reason I referred to it as "one of the audio streams," showed up with the deleted scenes on the Star Wars Episode III DVD's. If I turned up the sound to be able to hear the movie clips, when they ended and the next George Lucas interview section started, George would blast us out of the room!
__________________
Terry -- My Computer Tips site, coffee site, home theater site

Case Lian Li PC-A71F, Motherboard Gigabyte GA-P55-UD4P, CPU Intel Core i7-860, RAM 8 GB, Encoders 2 Hauppauge HVR-2250's, VideoCard PowerCooler AX4350, OS Windows 7 Pro, SageTV 6.6.2, SageTV Media Extender, SageTV Client, SageTV PlaceShifter, Sage Webserver.
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


All times are GMT -6. The time now is 01:04 PM.


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