Tuesday, November 30, 2004

Integrating Flash Video into Web Pages

I see that Macromedia are now giving away their "Flash Video Kit" when you purchase Dreamweaver before December 31. The "Video Kit" is regularly $99 and includes Sorenson Squeeze (special "lite" version) and the "extensions" required to integrate flash video with Dreamweaver.

Dreamweaver is $399 for the full package and $199 for the upgrade. I am not a Dreamweaver user, so I am not sure why you need the special extensions. For my own web pages I can just take the code generated from Flix Pro and paste it right into a page. Front Page recognizes it as an ActiveX control and lets you make adjustments by right clicking and going to "ActiveX Control Properties". Or even easier, you can just edit the html.

Here is what the html code for a typical video insertion looks like. This was set up for a movie that was 320 x 240 with a player added by Flix Pro. That accounts for the actual "object" dimensions of 325 x 274. Replace "movie.swf" with your own file name. And replace "server.com/swf" with your own server address.

------------------------------

<OBJECT width="325" height="274"
classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
name="./movie.swf" id="./movie.swf" codebase="http://download.macromedia.com/pub/shockwave/cabs
/flash/swflash.cab#version=5,0,0,0">
<PARAM name="bgcolor" value="000000"><PARAM name="movie" value="http://www.server.com/swf/movie.swf" ref>
<PARAM name="loop" value="0">
<PARAM name="quality" value="High">
<PARAM name="play" value="0">
<PARAM name="menu" value="-1">
<param name="_cx" value="8599">
<param name="_cy" value="7250">
<param name="FlashVars" value>
<param name="Src" ref value="http://www.server.com/swf/movie.swf">
<param name="WMode" value="Window">
<param name="SAlign" value>
<param name="Base" value>
<param name="AllowScriptAccess" value="always">
<param name="Scale" value="ShowAll">
<param name="DeviceFont" value="0">
<param name="EmbedMovie" value="0">
<param name="SWRemote" value>
<param name="MovieData" value>
<param name="SeamlessTabbing" value="1">
<EMBED width="325" height="274" src="http://www.server.com/swf/movie.swf"
name="./movie.swf" bgcolor="#000000" play="TRUE" menu="TRUE" quality="high"
loop="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"></EMBED></OBJECT>

---------------------

You should be able to copy and paste into your own web page, make edits to point to your own video at the correct size. Some of the parameters may look a bit mysterious. The most important are "loop" (keep restartign the movie) and "play" (start playing when the page is loaded". These are both set a "0" which means "no".

Once I get something like this to work the way I want I just copy and paste from a working page to a new one and make appropriate adjustments.

Of course you need to encode your video as a .swf file. For that you will need either Soreson Squeeze, or, my preference, Flix Pro.

-- Rick

This page is sponsored by Power Linking Strategies and Beautiful Vinyl Banners.

0 comments: