| HTML Tutorials |
|
|
| XML Tutorials |
|
|
| Browser Scripting |
|
|
| Server Scripting |
|
|
| .NET (dotnet) |
|
|
| Multimedia |
|
|
| Web Building |
|
|
| Java Tutorials |
|
|
| Programming Langauges |
|
|
| Soft Skills |
|
|
|
 |
 |
|
My first SMIL File
|
|
SMIL code can be written by using a text-editor. An XML editor or better
SMIL editor will save you some time and effort. The files must be run in an SMIL
player. We are testing in
Ambulant
player.It is also execute in realone player
|
|
This first example "Looping Zebra" will end up looking like a simple gif
animation except we use the SMIL language and jpg-files. It is a looping
sequence of zebra images where we learn a little bit about timing.
Just as we are used to in HTML, SMIL have <head> and <body> tags . It should be
no surprise that the head contains mostly meta-information and that the body
contains media content and timing. Lay-out is placed in the head.
Let's start with <layout></layout>. It must be placed between the <head> and
</head> tags, and it is recommended that you always use it unless you want to be
surprised by how the different implementations deal with it. You will also
usually use the <topLayout> tag which describe properties of the window for
your presentation. topLayout goes inside layout. topLayout has some familiar
attribute like height,width and backgroundColor. You also have the open and
close attributes for describing when the window shall open or close.
|
|
<head>
<layout>
<topLayout width="640px" height="480px" backgroundColor="#FFFFFF"
open="whenActive" close="whenNotActive"/>
</layout>
</head>
|
|
In synchronized multimedia timing is an important element . SMIL 2.0 defines
three types of time containers: par, seq and excl. par is for parallel timing and seq is
for sequential timing. excl is a mix of the two former a mix of the two former
tags, and was introduced with SMIL 2.0 because it was needed. Attributes for the
time tags are begin, end, dur(ation) etc.
Media object most important attribute is src. Just as in html this is an [URI]
so you can either use filename or an URL. Time to look at the body in our
example. seq has the attribute repeatCount set to indefinite, so it will loop.
The image files have the well-known alt attribute and I've used the dur
attribute to time each images duration. Since we use seq they will be played
sequentially. The first image will start, and play for 2 seconds as its dur is
set to "2s". Then the next image will start.
|
|
<body>
<!-- Zebra transformation looped-->
<seq repeatCount="indefinite">
<img src="images/zebra.jpg" alt="a zebra" dur="2s"/>
…
<img src="images/zebra_oil.jpg" alt="a zebra as an oil
painting" dur="1.0s"/>
</seq>
</body>
|
|
As a finishing touch we add language information and a title to the
beginning <smil> tag. Below is the complete file will look like:
|
|
<?xml version="1.0"?>
<!DOCTYPE smil PUBLIC "-//W3C//DTD SMIL 2.0//EN"
"http://www.w3.org/2001/SMIL20/SMIL20.dtd">
<smil xmlns="http://www.w3.org/2001/SMIL20/Language"
xml:lang="en" title="SMIL template">
<head>
<layout>
<topLayout width="640px" height="480px" backgroundColor="#FFFFFF"
open="whenActive" close="whenNotActive"/>
</layout>
</head>
<body>
<!-- Zebra transformation looped-->
<seq repeatCount="3">
<!-- Duration in seconds, using different time formats -->
<img src="images/zebra.jpg" alt="a zebra" dur="2s"/>
<img src="images/zebra_swirl80.jpg" alt="a zebra with a
swirl effect" dur="1"/>
<img src="images/zebra_swirl120neg.jpg" alt="a zebra with a
large swirl effect" dur="1000ms"/>
<img src="images/zebra_fuschia.jpg" alt="a zebra colorized
fuschia" dur="00:00:01"/>
<img src="images/zebra_lime.jpg" alt="a zebra colorized
lime green" dur="00:01"/>
<img src="images/zebra_oil.jpg" alt="a zebra as an oil
painting" dur="1.0s"/>
</seq>
</body>
</smil>
|
Share And Enjoy:These icons link to social bookmarking sites where readers can share and discover new web pages.
Keywords: smil-files,
how to play smil,
smil file format,
windows media player files,
smil file extension,
smil file type,
smil windows media,
smil file,
streaming video files,
smil files,
windows media files,
media player files,
streaming audio files,
playing smil files,
play smil files,
how to open files,
play smil file,
smil format,
smil player,
smil extension,
smil audio,
smil media,
ogm files,
play smil,
smil video,
smil mac,
codec files,
smil mp3,
freeware files,
mkv files,
asf files,
rmvb files,
asx files,
ogg files,
avi files,
rm files,
mov files,
mpc files,
wmv files,
wav files,
cda files,
vcd files,
srt files,
smil playlist,
m4a files,
m2v files,
dat files,
vob files,
3gp files,
mp4 files,
sound files
|
|
| HTML Quizes |
|
|
| XML Quizes |
|
|
| Browser Scripting Quizes |
|
|
| Server Scripting Quizes |
|
|
| .NET (dotnet) Quizes |
|
|
| Multimedia Quizes |
|
|
| Web Building Quizes |
|
|
| Java Quizes |
|
|
| Programming Langauges Quizes |
|
|
| Soft Skills Quizes |
|
|
|