KutttPech MPEG-player Manual

Ok, on this page I will attempt to write some kind of manual to show what KutttPech can do and (more important) HOW YOU can do that... Here is something that looks like a table of content:

How to use KutttPech
List of all parameters
Runtime usage
How to compile source
Trouble shooting

How to use

How do you use KutttPech? --- KutttPech is a JAVA-applet. That means that it will only run within browsers that support JAVA, but don't worry: a big chance that your browser does. (Even if you don't know about it...) JAVA-applets behave a bit like images do within a web-page, only they are working programs. To put an applet in your web-page you need to insert an applet-tag in the body of the HTML that would look something like this:

<applet code="test" codebase="http://base" archive="archive.jar" width="300" height="200">
<param name="foo1" value="bar">
<param name="foo2" value="bar">
<param name="foo3" value="beer">
. . .

In this applet-tag the code field specifies the name of the class to be launched in the browser, the codebase specifies location where the applet files are located and archive is an optional field to specify that the files are stored in a compressed jar-file with that name. The width and the height should speak for themselves.

Between the <applet> and </applet> tag parameters can be defined. In the applet the values of these parameters can be read and used to react in a certain way. In the case KutttPech it is rather important for the applet to know what file/stream it should open and where it should look for it. A list of all parameters and how to use them is listed in the next paragraph.

For now a working applet-tag for KutttPech would look something like this:

<applet code="KutttPech.kutttpech" codebase="http://kutttpech.sourceforge.net/" archive="kutttpech-0.4.jar" width="170" height="120">
<param name="FILENAME" value="sample.mpg">

List of parameters

Ok, here is a (I bet it's incomplete) list of parameters that KutttPech-0.4 will accept. Some features of KutttPech are stream-server dependant and might have no effect if that server does not react as KutttPech expects it to. (lookout, parameters are case-sensitive)

Specifies the location of the file/stream to be loaded. This can be absolute (with path) as well as relative (from codebase). Note that applets usualy are not allowed to open files/urls that are not located on the server from which the applet was loaded. This is done for security reasons. Use this function only when you want to surf only one stream/file, for multiple streams/files use CHOICExxx.

If this parameter has the value 'yes' or is left out and the file/stream contains audio, the applet will try to open the audio device in whatever way he knows how. (sun.audio.* or javax.sound.sampled.*) In all other cases audio is ignored.

If this parameter has the value 'yes' cutting is switched on. Which means that if for some reason the CPU is unable the handle the stream, KutttPech will skip some P- and B-frames and a relative small lag will be maintained.

When this parameter has the value 'yes' buffering will be enabled. This means that the data that has been played, will not be forgotten but stored instead. The only real use for this option is in combination with parameter CONTROLS set to 'full'. This option will eat memory and should never (unless for the fun of it) be used in combination with LOOPING. :)

I have implemented two type of controls with KutttPech, but they are both equaly buggy... If this parameter is set to 'full' then a scrollbar will be displayed. This scrollbar has the basic functionalities you would expect from a scrollbar (Play/Pause/Stop and Slide) and is very handy when viewing files. Note: BUFFERING should be 'yes' and this has no real use for live streams...
When this parameter if set to 'info' an info panel will be shown on the right. This panel displays usefull information like framerate, bitrate, gopsize, buffersizes and timestamps... Good tool to debug or test connections manualy...

If value is 'yes' looping will be enabled. This means that after a file/stream has ended it will reopen this stream and start playing from the beginning...

The value is the location of the site KutttPech should jump to when clicked on.

Specifies the target frame for the location in CLICKLINK to be displayed in.

If this parameter is supplied as the absolute url of the current page, KutttPech can reload the page after receiving a special HTTP-call from the server. (if "Location: reload" is recieved after requesting a stream) "Why?", you ask... "Don't ask", I say, "you don't HAVE to use it you know..."

If implemented a set of parameters to make it easier to surf different streams with different speeds. KutttPech is able to choose the right speed and switch between speeds if the server notices he can not handle a certain stream. Note that this will not run for a stream server out of the box and the server will need to be tweeked. I'll try to explain how... (some day)

Specifies the name of stream with number x. Note that every numbers from 1 until x should be defined else this parameter is ignored.

Specifies the location of stream with number x. (see FILENAME)

Specifies the name of the stream that has the highest lower bitrate.

Specifies the name of the stream that has the lowest higher bitrate.

Specifies the speed of the stream with number x.

Specifies the name of the fixed choice of stream to begin streaming...

Specifies part of the url of the fixed choice of stream to begin streaming...

If set to 'no' it will cause KutttPech not to attempt a connection speed test. In all other cases it will try to open a file in de codebase root named 'connection_speed.php'. This then should generate random output (less likely to be compressed) and KutttPech will attempt to measure the speed of the connection and will choose the right stream (according to speed) and will open it... Note that the connection speed wil be skipped if one of the streams do not have a CHOICExSPEED parameter.

Runtime usage

When KutttPech is playing, the user can interact with it using the mouse. Below you read how:

MOUSE CLICK (without keys)
This will trigger the CLICKLICK load within the browser.

Enable/Disable the info panel for debug info. Very usefull... Note that when doing this with a scrollbar enabled, the scrollbar will disappear and not come back... *snif*

Goto previous stream.

Goto next stream.

How to compile KutttPech

hmmm... Three steps: (1) download KutttPech-0.4.tar.gz, (2) unzip, (3) make... (That is, if you are using UNIX and have a jdk installed...) For Windows users: read Makefile and act like you are 'make' :)... (Copy-paste the line after 'all:' to a console in root of KutttPech.) Note 1.2.2 users, please be so kind as to ignore the error about the 1.3.1 specific audio... No, you can not compile this... No, you will not need it, unless you use Mozilla/Netscape 6 or some kind of 1.4 JAVA version browser...

Trouble shooting

Ok, I expect a lot of troubles... Yes, I do want to hear about them... No, it's not my FAULT... Yes, you may try to do it better...

You want to help me? USE THIS SOFTWARE! and tell people to do the same... You want to do more? Tell me what you think about it and encourage me to go on ;)... You still want to do more? Go to Africa and dig wells! (You have to much time on your hands... ;))

--- Ron ---