LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-16-2009, 12:52 PM   #1231
TheDevilWearsPravda
LQ Newbie
 
Registered: Apr 2009
Posts: 17

Rep: Reputation: 0

non-premium here.

My concern is that my system might not be able to handle the premium feed. Non-premium looks great in mplayer, but unwatchably jerky in flash, even without fullscreening.
 
Old 04-16-2009, 01:30 PM   #1232
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
Quote:
Originally Posted by TheDevilWearsPravda View Post
non-premium here.

My concern is that my system might not be able to handle the premium feed. Non-premium looks great in mplayer, but unwatchably jerky in flash, even without fullscreening.
Try the autobahn.jar and update your mplayer to the latest version (the fix came in yesterday) and see if autobahn is an option for non-premium users. In the latest mlbviewer svn there is a nexdef.py script which acts like soapevent.py except returns the nexdef url. There is a parameter in the url (max_bps=2500000.) Search nexdef.py for max_bps and replace with 800000. Let me know if that works with your system.

Don't worry. I definitely want to keep this usable for folks with slower machines because my "headless" laptop, the one connected into my entertainment center, is 750 Mhz x 256 MB RAM.

By the way, have you run into any stream selection errors using the latest mlbdvr.py? I want to know if and what the errors are for non-premium users trying to access the Premium home and away streams.

Also, since you are a non-premium user, can you send me your $HOME/.mlb/log to straycat000(at)yahoo(dot)com? I want to see if there are differences in the SOAP responses that might give me clues on how to find streams that are accessible for non-premium users.
 
Old 04-16-2009, 03:35 PM   #1233
rjwood
Member
 
Registered: Jan 2006
Distribution: UBUNTU
Posts: 130

Rep: Reputation: 16
premium. But I'm totally lost here. Sorry for being the hidden noob. would someone please tell me step by step what I have to do to get mplayer working with this?
 
Old 04-16-2009, 03:46 PM   #1234
bodly
LQ Newbie
 
Registered: Mar 2009
Distribution: Kubuntu
Posts: 24

Rep: Reputation: 16
Premium here also. Along with a friend who is too paranoid to post anything on the interwebs.
 
Old 04-16-2009, 03:55 PM   #1235
rawmill
LQ Newbie
 
Registered: May 2008
Distribution: Gentoo / Ubuntu
Posts: 3

Rep: Reputation: 0
Premium here as well.
 
Old 04-16-2009, 04:45 PM   #1236
Theophile
Member
 
Registered: Jan 2003
Posts: 283

Rep: Reputation: 35
Quote:
Originally Posted by rjwood View Post
premium. But I'm totally lost here. Sorry for being the hidden noob. would someone please tell me step by step what I have to do to get mplayer working with this?
No problem. Follow this guide, with one exception: In the section called "Download the 'Development' Files," rather than running that huge command which probably won't work, do this instead:

Code:
sudo apt-get build-dep mplayer
This will install the development dependencies for compiling mplayer from source.

In addition, the section called "Live555" is optional, as is the last section on SMplayer.

Finally, if you're like me, you don't want two different version of mplayer on your system. If you follow the above-linked guide, it will keep the default Ubuntu build of mplayer in /usr and install the bleeding-edge version in /usr/local

If you want to replace the Ubuntu version (you do), then look at the commands in the section titled "Download and Compile the svn mplayer." Change the ./configure line to this:

Code:
./configure --codecsdir=/usr/lib/codecs --confdir=/etc/mplayer --prefix=/usr
THen run the 'make' command as stated. After 'make' finished but before you run 'checkinstall,' execute this command:

Code:
sudo apt-get remove mplayer mencoder
Then run 'checkinstall' as the guide says. Compiling mplayer from source will provide mplayer and mencoder in one large package, rather than splitting it between two packages like Ubuntu does by default.

For the sake of clarity, following the above instructions will make the "Download and Compile the svn mplayer" section look like this:

Code:
$ cd $HOME
$ svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer
$ cd $HOME/mplayer
$ ./configure --codecsdir=/usr/lib/codecs --confdir=/etc/mplayer --prefix=/usr
$ make
$ sudo apt-get remove mplayer mencoder
$ sudo checkinstall -D --install=yes --fstrans=no --pakdir "$HOME/Desktop" \
--pkgname mplayer --backup=no --deldoc=yes --deldesc=yes --delspec=yes --default \
--pkgversion "3:1.0~svn-`grep "#define VERSION" version.h | cut -d"-" -f2`"
$ make distclean
Good luck!
 
Old 04-16-2009, 05:41 PM   #1237
Theophile
Member
 
Registered: Jan 2003
Posts: 283

Rep: Reputation: 35
Now that we have video playback working, I have a couple feature requests because we all know that daftcat hos nothing better to do than met our every desire. :-)
  • Integrate nexdef.py with mlbdrv.pr so playback can be started by just selecting the game (I know you're already working on this)
  • Video follow
  • Format filename of dumpstream files as follows: VISITORCODE at HOMECODE - date - broadcaster.mp4 (e.g. CLE at NYY - 4-16-09 - YES.mp4)
  • Schedule recordings (If DVR functionality is still planned)

I am currently working on a system service script for Ubuntu that will allow the NexDef "plugin" to be autostarted at boot and treated as a system service.
 
Old 04-16-2009, 06:44 PM   #1238
Theophile
Member
 
Registered: Jan 2003
Posts: 283

Rep: Reputation: 35
Got it. Here's how to run the NexDef plugin as a system service. This work on Ubuntu, probably other systems that use the same sysinit scripts.

First, make sure you have a Java runtime environment (JRE) installed on your system:

Code:
sudo apt-get install sun-java6-jre
Next, download the latest autobahn.jar from mlb.com here, and place it at /usr/share/autobahn/ :

Code:
mkdir /usr/share/autobahn
wget http://www.mlb.com/nexdef-jars/unsupported/autobahn.jar -O /usr/share/autobahn/autobahn.jar
Now, open a text editor to create the system script:

Code:
sudo gedit /etc/init.d/autobahn
In the editor, paste the following:

Code:
#! /bin/sh
### BEGIN INIT INFO
# Provides:          autobahn
# Required-Start:    $local_fs $remote_fs $networking
# Required-Stop:     $local_fs
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: MLB.TV NexDef plugin
# Description:       Autobahn swarmcast plugin (also branded "NexDef")
#                    needed to watch high resolution feeds on MLB.TV
#		     using either the web-based Flash player or the 
#		     mlbviewer project.
### END INIT INFO

PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC="MLB.TV NexDef plugin"
NAME="autobahn"
DAEMON=/usr/bin/java
DAEMON_ARGS="-jar /usr/share/autobahn/autobahn.jar"
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
USER=YOUR_USER_NAME!

# NO NEED TO MODIFY THE LINES BELOW

# Load the VERBOSE setting and other rcS variables
. /lib/init/vars.sh

# Define LSB log_* functions.
# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
. /lib/lsb/init-functions

#
# Function that starts the daemon/service
#
do_start()
{
	log_daemon_msg "Starting $DESC: $NAME "
	start-stop-daemon -b --start --quiet --chuid $USER -m -p $PIDFILE --exec $DAEMON -- $DAEMON_ARGS \
		|| return 2
	log_end_msg $?
}

#
# Function that stops the daemon/service
#
do_stop()
{
	log_daemon_msg "Stopping $DESC: $NAME "
	start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE
	RETVAL="$?"
	rm -f $PIDFILE
	return "$RETVAL"
	log_end_msg $?
}

case "$1" in
  start)
	[ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME"
	do_start
	case "$?" in
		0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
		2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
	esac
	;;
  stop)
	[ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME"
	do_stop
	case "$?" in
		0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
		2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
	esac
	;;
  restart)
	#
	# If the "reload" option is implemented then remove the
	# 'force-reload' alias
	#
	log_daemon_msg "Restarting $DESC" "$NAME"
	do_stop
	case "$?" in
	  0|1)
		do_start
		case "$?" in
			0) log_end_msg 0 ;;
			1) log_end_msg 1 ;; # Old process is still running
			*) log_end_msg 1 ;; # Failed to start
		esac
		;;
	  *)
	  	# Failed to stop
		log_end_msg 1
		;;
	esac
	;;
  *)
	echo "Usage: $SCRIPTNAME {start|stop|restart}" >&2
	exit 3
	;;
esac

:
IMPORTANT! Near the beginning of the script where it says USER=YOUR_USER_NAME!, change "YOUR_USER_NAME!" to the name of the regular user that will be running your web browser or mlbviewer. This is important because only the user that runs the NexDef plugin can access it.

After making the USER= change, save the file and close the text editor.

Next, make the new file executable:

Code:
sudo chmod 777 /etc/init.d/autobahn
Now add it to the startup schedule so it will start on boot:

Code:
sudo update-rc.d autobahn defaults
Now it will start automatically the next time you boot. To start it now, do this:

Code:
sudo /etc/init.d/autobahn start
Once you have it running, make sure your web browser can see it. Go here:

http://www.getautobahn.com/install

If you see a green square, you're good to go! Enjoy!

Last edited by Theophile; 04-17-2009 at 07:30 AM.
 
Old 04-16-2009, 07:42 PM   #1239
poorboywilly
Member
 
Registered: Apr 2009
Posts: 120

Rep: Reputation: 18
premium
 
Old 04-16-2009, 08:27 PM   #1240
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
Quote:
Originally Posted by Theophile View Post
Now that we have video playback working, I have a couple feature requests because we all know that daftcat hos nothing better to do than met our every desire. :-)
  • Integrate nexdef.py with mlbdrv.pr so playback can be started by just selecting the game (I know you're already working on this)
  • Video follow
  • Format filename of dumpstream files as follows: VISITORCODE at HOMECODE - date - broadcaster.mp4 (e.g. CLE at NYY - 4-16-09 - YES.mp4)
  • Schedule recordings (If DVR functionality is still planned)

I am currently working on a system service script for Ubuntu that will allow the NexDef "plugin" to be autostarted at boot and treated as a system service.
1. There will be a [NEXDEF] indicator like [DEBUG] which you can turn on or off using yet another hotkey, the 'n' key. I promise this summer I will work on a help page that supports scrolling. There will also be a config file option to auto-select nexdef.

2. Video follow. No problem. If use_nexdef==True, subject changes from MLB_FLASH_*00K_STREAM to MLB_FLASH_SWARMCLOUD. Video follow code should work without any additional modifications.

3. I want to keep the filename the same using the gameid (2009-04-16-clemlb-nyymlb-1) but I can append the call letters so the final filename would be 2009-04-16-clemlb-nyymlb-1-YES.mp4. The GameStream code doesn't have the datetime()'s that the listings code has. So I'd either have to overpopulate an already crowded constructor, or parse the gameid into a datetime and then back into a string. That seems silly when I have everything you need already in the gameid which the datetime does have. The other reason I want to keep the gameid is because it is a) consistent with last year's gameid's (you may want to watch games from last year and you can if you bookmarked 'em ), and b) the gameid auto-increments on twin bill days. Perhaps later in the summer I can implement a dictionary of format codes like a lot of id3ed tools do for mp3 filenames, but that would be much later in the season.

4. Assuming the retry algorithm is stable, this probably isn't as hard to do as it was before I put all that effort into the retry mechanism. Of course, this relies on you guys testing the hell out of that code and finding a recorder that supports resuming interrupted downloads. Since mplayer has trouble even seeking the files, I doubt it could do a resume by requesting the next keyframe in the sequence (assuming mplayer -dumpstream even supports resume.) Rtmpdump supports resume but I'm not convinced rtmpdump handles a live stream correctly. If you want a "do or die" record with no retries and hope it works, that might be something for a summer release too.

One thing I would like to do is something similar to bookmarks where you could bring up a screen of games you have recorded and delete old games from disk using this screen.

5. You'll notice I have deferred many of your requests until later in the summer. There's two reasons for this. First, there's still some development work to do with highlights, condensed games, and making sure 2008 compatibility remains (I still have 2008 bookmarks.) Second, with summer approaching (and with my newly paid off credit card), the swing dance events I attend and compete in are going to come fast and furious. There will be one or two weekends a month where I won't be online. I have to prioritize what I want to work on before those. Also, I expect work demands to pick up as our schedule has been slipping a bit. This should place even more demands on my free time.

I do plan on putting in some decent code time this weekend though because all my friends are away at one of those swing event weekends so I'll have nothing better to do.
 
Old 04-16-2009, 08:55 PM   #1241
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
Roadmap

MAY 1 RELEASE

* Nexdef integration with an option to default to nexdef or regular streams and set maximum bps (still needs to be tested to see if autobahn actually honors this) via the configuration file.

* Highlights

* Condensed Games (if MLB.com has these available)

* Stable record/play functionality for live game and archived, video and audio using nexdef and/or rtmpdump. I prefer to use nexdef only for video but I need my non-premium subscribers to verify if this will work for them.

The May 1 Release will be the first sourceforge release of the 2009 season. This should be a stable release that has a minimum amount of hacking (preferably none) to get going and a well-documented set of procedures to meet dependencies. In other words, this will be the general newbie version so it needs to be as easy and functional as possible.

Anything beyond the May 1 release is subject to my desire to write new code and my free time to do it.

Of course, with these swing competitions costing as much as they do, donations might sway my desire. Can't say they'll do much on the time equation though.
 
Old 04-16-2009, 08:57 PM   #1242
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
That said, you svn users will likely continue to get at least a weekly revision over the next couple of weeks leading up to the May 1 target date for Sourceforge release.
 
Old 04-16-2009, 09:37 PM   #1243
spektrx
LQ Newbie
 
Registered: Apr 2009
Posts: 8

Rep: Reputation: 0
Sounds good daft, thanks!

Another suggestion I have is that we try and get bitrate selection working with NexDef (especially if you're going to drop non-premium support). The reason being that the 800x450 2200kbps 'best' stream should be readily playable on older systems (which someone already mentioned), if it weren't for the high bitrate. Honestly, a bitrate of around 1200-1500kbps would be *more* than enough for this (without really losing much quality), and it would reduce the size of games you download significantly as well.

I'm playing around with stream URLs, but it seems that 800x450 res is used for the top '4 bars' of nexdef, and the bottom 4 are 400x450. It seems that by playing with the URL, you can tweak the res and the bitrate, but it'll take some more testing to confirm.

Quote:
Originally Posted by daftcat View Post
MAY 1 RELEASE

* Nexdef integration with an option to default to nexdef or regular streams and set maximum bps (still needs to be tested to see if autobahn actually honors this) via the configuration file.

* Highlights

* Condensed Games (if MLB.com has these available)

* Stable record/play functionality for live game and archived, video and audio using nexdef and/or rtmpdump. I prefer to use nexdef only for video but I need my non-premium subscribers to verify if this will work for them.

The May 1 Release will be the first sourceforge release of the 2009 season. This should be a stable release that has a minimum amount of hacking (preferably none) to get going and a well-documented set of procedures to meet dependencies. In other words, this will be the general newbie version so it needs to be as easy and functional as possible.

Anything beyond the May 1 release is subject to my desire to write new code and my free time to do it.

Of course, with these swing competitions costing as much as they do, donations might sway my desire. Can't say they'll do much on the time equation though.
 
Old 04-16-2009, 10:11 PM   #1244
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
Seeing as my target baseball machine is a 750 Mhz x 256 MB laptop, I have a vested interest in getting low-res Nexdef working. I was thinking it might be as simple as adjusting the max_bps in the query string, but I haven't really given it too much attention yet.

I don't know the pixel details but I'm happy if we can get an 800K stream working that looks at least as good last year's offering.

But....

I will still need you non-premium users to experiment with Nexdef when I release the next revision with it (probably this weekend) to tell me if nexdef will even work for you at all at the lower (non-nexdef resolutions.)
 
Old 04-17-2009, 01:27 AM   #1245
Wolfvorkian
Member
 
Registered: Sep 2007
Distribution: Arch
Posts: 108

Rep: Reputation: 15
Quote:
Originally Posted by daftcat View Post
MAY 1 RELEASE

[snip]

The May 1 Release will be the first sourceforge release of the 2009 season. This should be a stable release that has a minimum amount of hacking (preferably none) to get going and a well-documented set of procedures to meet dependencies. In other words, this will be the general newbie version so it needs to be as easy and functional as possible.

[snip]

Of course, with these swing competitions costing as much as they do, donations might sway my desire. Can't say they'll do much on the time equation though.
Good to see you are coming out with a newbie version. Not being a geek means that I'm a tad challenged with this year's SVN downloads. Thank the god lord for the magic f-key hack, enhancement or whatever it.

As far as sending you a donation; you'll hate us the morning after when the dry heaves and splitting headache occur due to the generosity of your fan club. ;-)
 
  


Reply

Tags
help, install, installation, instructions, seek, vlc, windows



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mlb.com gameday audio stream statmobile Linux - Newbie 6 05-06-2008 10:16 PM
link dies intermittently-seemingly at random- between win<->linux not linux<->linux?? takahaya Linux - Networking 10 03-09-2007 10:37 PM
triple boot linux/linux/linux No Windows involved toastermaker Linux - Newbie 12 03-02-2006 10:40 PM
Redhat (rhel v2.1) bootup problem with linux (linux vs linux-up) namgor Linux - Software 2 06-24-2004 02:49 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration