Posts filed under 'Windows Media'

Stopping a Windows Media Stream with an ASX file

You can stop a Windows Media stream part way through the file using an ASX file. In order to do this, you need to set the duration parameter. Unlike starttime, there is no endtime, so you will need to calculate the duration from your start point that you require in order to end at the correct point.

e.g. If you want to start at 30 seconds and finish at 1 minute into the stream, you sill start at 30 seconds and have a duration of 30 seconds, so your ASX file will look like the following.

<ASX version=”3.0″>
<entry>
<starttime value=”0:30″/>
<duration value=”0:30″/>
<ref href=”mms://merlin.streamingwizard.com/demo/animationbraodband.wmv” />
</entry>
</asx>

Add comment July 20th, 2005

Opening Windows Media Player In Full Screen

The following script is only applicable to Windows Media versions 9 and above. In effect it does the same as right clicking on the media player when it is playing and selecting the zoom >> full screen option. As this option is only available when the file is playing, so the script will only work once the stream has started. If you try clicking the link before that, it will not work, and you will get a javascript error. I have not yet found a way around that.

<script language="JavaScript" type="text/javascript">
function fullscreen()
{
MediaPlayer.fullscreen="true"
}
</script>

<OBJECT ID="MediaPlayer" CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6" width=320 height=240>
<PARAM NAME="URL" value="mms://merlin.streamingwizard.com/demo/animationbroadband.wmv">
</OBJECT>

<br>

<a href="#" onClick="javascript:fullscreen()">Full screen</a>

Add comment July 20th, 2005

Connecting to the middle of a Windows Media Stream

Connecting directly to the middle of a Windows Media stream can be done in several ways using proprietery software which create new streams with embedded triggers in them.

You can also set up server side playlists which will connect at the required point.

The easiest and most basic way however is to add an extra line to your ASX file using the starttime parameter.

e.g.

<ASX version=”3.0″>
<entry>
<starttime value=”0:30″/>
<ref href=”mms://merlin.streamingwizard.com/demo/animationbraodband.wmv” />
</entry>
</asx>

This would connect to the given stream 30 seconds from the beginning.

Add comment July 19th, 2005

Transcoding

Traditionally whenever you wanted to encode a file, you had to start with an uncompressed source media file such as an avi or mov. These raw files can be many hundreds of megabytes in size, and encoding them requires lots of processor power. If you wanted to create several differnt files for different speed connections and media formats, for each one you would have to start with the original source file which would take comparable times for each version of the encoded file that you created.

More recently transcoding has begun to take off. It is now possible with most formats to be able to change from one to another (at the time of writing I think Real Media is still unique in that you can not re-encode from a file).

Transcoding from an encoded file is generally much faster as a lot of “unimportant” data has been discarded, and so a lot less processing has to be done.

There may be a slight loss of quality when transcoding, although to an untrained eye this is unlikely to be apparent, and any blips in quality are more likely to be due to bandwidth restrictions than transocding problems.

I have found that encoding a raw video into Windows Media 9 at around 2Mbps and then transcoding to other formats has produced the same results as using the native files, and saved substantial time.

Add comment July 18th, 2005

ASX Files

ASX files are meta files used to link to Windows Media streaming files. They contain the URI of the actual stream along with proprietery information such as titles.

A basic ASX file looks like:

<asx version=”3.0″>
<title>www.streamingwizard.com</title>
<entry>
<ref href=”mms://gandalf.streamingwizard.com/chester” />
<ref href=”http://gandalf.streamingwizard.com/chester” />
</entry>
<asx>

Notice there are two references in the ASX file. One that starts with mms (Microsoft Media Streaming Protocol), and the second one http. This is not entirely necessary, but Windows Media streams better over mms than http and should be used in prerence to http. MMS streams over port 1755 though which may be blocked my some firewalls, so it is useful to set up http streaming as a failover if the MMS link does not work.

Here is a link to the above ASX file.

Add comment July 18th, 2005

Next Posts


Calendar

January 2009
M T W T F S S
« Jan    
 1234
567891011
12131415161718
19202122232425
262728293031  

Posts by Month

Posts by Category