|
The Media Command |
|
Usage
Description
Note: the media command is new in Active Worlds 3.6 and requires Windows Media Player 6.4 or later in order to function. Windows Media
Player 9 is recommended for best performance. Some media content cannot be displayed correctly on older
players, due to missing format decompression support (To upgrade codecs for
older players click here,
to upgrade to the latest Windows Media Player click here). The media command enables media player functionality within a scene for playback of local- and web-based media files, as well as broadcasted streams. Supported are all file formats, supported by your installed version of Windows Media Player, except play-lists. A list of supported media file formats, for a users running WMP9, is here, not supported are Windows Media metafiles (.asx, .wax, .wvx, .wmx, .wpl). Sign objects must be used to take the video frames of the media. The media command has many optional arguments: The url specifies the url, web-address or path to the media file. If the url is empty and a name is specified, it will stop running media on all objects of the triggered object's owner within the current view range. Since build 555 the url-prefix defaults to "http://", if not other protocol is specified. "Info text" is an optional info text for the sign object. It will be displayed while the media is loading and after the media has finished. If omitted, the info text defaults to the contents of the object's description field (this is also the most common form of the sign command.) If specified, the into text must be enclosed in double quotes. Optionally, if the url or path includes spaces, the into text must be used to take the url or path, and the url option must be omitted. The optional name argument specifies the name of the same owner's object to place the media on. Object names are assigned via the name command. The optional set argument changes the attributes of an already playing media on the fly, without pausing or stopping the stream. Note, the resolution cannot be changed on the fly. The optional pause argument is in particular
useful, if named object's are used to pause a running media. Triggering a
subsequent pause causes the media to continue playing where it was paused
before. Note, that live-feeds cannot be paused, the stream will continue, but
the video rendering and the sound will be switched off / muted during the
pause. The optional stop argument is in particular useful, if named object's are used to stop a running media. The color argument specifies the color to use for the sign text, and bcolor specifies the sign's background color. Both arguments are optional. The default color scheme is white text on a blue background. The colors can either be specified as one of many preset word values or as a "raw" hexadecimal value giving the red/green/blue component values (the same format as used for the BGCOLOR= HTML tag). The res argument specifies resolution used to the displayed video frames in pixel, if the media contains a video. Valid values are 64, 128, 256 and 512 pixel. Default is 256 pixel. Note that the proportions of the video (height and width) only depends on the sign's proportions and not on the used resolution. The fx argument specifies a sound effect applied to the media. They include: 3D - causes the sound to pan according to your avatar's position. The optional radius specifies the maximum distance in meters the sound can be heard. The default radius is 30 meters. The optional radoff specifies the maximum distance in meters the media stream will play. The default radoff is 30 meters. radoff cannot be smaller than radius. Outside the given radoff an ongoing media is stopped. The optional vol argument specifies the relative volume of the played sound, in percent. Valid values are in the range from 0 to 100, where 0% is silence (mute) and 100% is full volume. Default is 100%. The optional loop argument specifies the count of loops to play the specified media file. Valid values are in the range from 1 to 2,147,483,647. Default is 1. The optional osd argument specifies if TV-like on-screen-display should be displayed on top of the video frames. Valid values are on/off, yes/ no, or true/false. Default is on, to display additional on-screen information. The optional ext argument specifies and external window should be optioned to display the video. If the media does only contain audio, no external window is displayed. Valid values are on/off, yes/ no, or true/false. Default is off, not to display video in an external window. The optional nostop argument disables the mouse click or bump trigger to stop a running media. Objects using the bump trigger always have this option set, to avoid subsequent on/off triggering of the media command. In conjunction with the activate trigger, this disables the toggle-switch-function, which is applied on media signs by default. When used with the create trigger the nostop argument has no effect. The optional nostart argument disables the mouse click or bump trigger to start the media. This is in particular useful for forwarding a running media stream from one sign to another within the range of view. The first media command would start the stream. While walking though the world subsequent media commands (of the same url) would take the stream over from the first one. If the stream stopped, another create/activate media command using nostart would not re-start the stream again.
Comments The create trigger only works with the media command, if "Disable create url" is not checked in the world features settings. Other options that affect the media command are in the General tab and in the Downloads tab of the browser option settings.
Examples
This creates and plays the given media stream as soon the used sign object comes within your avatar's view range.
On another object: activate media name=foo url=http://www.umpd.umd.edu/sirens/video/Windows/EWdownload.wmv This creates an empty sign object at first. As soon the activate command on the other object is triggered, the given media stream is displayed on the sign object named foo.
This creates an object that when clicked on, starts the media, and when clicked on the second time it switches it off again.
On another object: If your avatar collides with the first object, it will start the media. When colliding with the other object it stops the running media. create sign, name foo;
activate media url=... This creates and plays the given media stream which can be paused by clicking the other object.
On other objects: activate media set vol=50 osd=off name=foo activate media set vol=100 osd=on name=foo This will change the parameters of an already playing media.
Important Note About Media Files! The purpose of this command is to allow you to customize your building with your own personal media and artwork. It should be treated exactly the same as the HTML <img> tag; in other words, it is not appropriate to link to media streams and files on other people's web sites without their permission. This can cause their web servers to experience extra load and possibly cost them money unfairly. A good rule to follow is: when in doubt, you should only link to media files on your own website. Also, remember that many media files on the web are protected by copyrights. Linking to these media files without the owner's permission, whether on your web site or theirs, is illegal and could subject you to criminal prosecution! Also, always keep in mind that content guidelines may be in effect in the world you are building in! If they are, linking to obscene, offensive or otherwise inappropriate media files or live streams may cause your property to be removed or your account to be deleted without warning! |