previous   next   contents   index

25 February, 2000

4. SMIL Document Object Model

A DOM application can use the hasFeature method of the DOMImplementation interface to determine whether the SMIL Object Model interfaces are supported or not. The feature string for the fundamental interfaces listed in this section is "org.w3c.dom.smil". The version of this DOM version is "2.0".

The purpose of the SMIL Boston DOM is to provide an easy access to the attributes and functionalities of the SMIL Boston specification ([SMIL Boston]). Not all SMIL Boston attributes are accessible with the following API but the user can still use the DOM Core ([DOM Level 2]) to access them (see setAttributeNS and getAttributeNS).

Table of contents

4.1. SMIL Core extensions

(ED: A separate document should describe the integrated DOM associated with SMIL documents, and documents for other document profiles (like HTML and SMIL integrations). )
Interface SMILDocument

A SMIL document is the root of the SMIL Hierarchy and holds the entire content. Beside providing access to the hierarchy, it also provides some convenience methods for accessing certain sets of information from the document.

(ED: Cover document timing, document locking?, linking modality and any other document level issues. Are there issues with nested SMIL files?
Is it worth talking about different document scenarios, corresponding to differing profiles? E.g. Standalone SMIL, HTML integration, etc. )

IDL Definition
interface SMILDocument : Document, ElementSequentialTimeContainer {
};

Interface SMILElement

The SMILElement interface is the base for all SMIL element types. It follows the model of the HTMLElement in the HTML DOM, extending the base Element class to denote SMIL-specific elements.

Note that the SMILElement interface overlaps with the HTMLElement interface. In practice, an integrated document profile that include HTML and SMIL modules will effectively implement both interfaces (see also the DOM documentation discussion of Inheritance vs Flattened Views of the API).

(ED: // etc. This needs attention)

IDL Definition
interface SMILElement : Element {
           attribute DOMString        id;
                                        // raises(DOMException) on setting

};

Attributes
id of type DOMString
The unique id.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

4.2. Structure extensions

(ED: This module will include the smil, head and body elements. )

4.3. Meta informations extensions

This SMIL Boston module doesn't have a corresponding SMIL Boston DOM module.

(ED: Relation with a RDF DOM ? )

4.4. Layout extensions

This module includes the layout, root_layout and region elements, and associated attributes.

Interface SMILLayoutElement

Declares layout type for the document. See the LAYOUT element definition.


IDL Definition
interface SMILLayoutElement : SMILElement {
  readonly attribute DOMString        type;
  readonly attribute boolean          resolved;
};

Attributes
type of type DOMString, readonly
The mime type of the layout langage used in this layout element.The default value of the type attribute is "text/smil-basic-layout".

resolved of type boolean, readonly
true if the player can understand the mime type, false otherwise.

Interface ElementLayout

This interface is used by SMIL elements root-layout, top-layout and region.


IDL Definition
interface ElementLayout {
           attribute DOMString        title;
                                        // raises(DOMException) on setting

           attribute DOMString        backgroundColor;
                                        // raises(DOMException) on setting

           attribute long             height;
                                        // raises(DOMException) on setting

           attribute long             width;
                                        // raises(DOMException) on setting

};

Attributes
title of type DOMString
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

backgroundColor of type DOMString
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

height of type long
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

width of type long
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Interface SMILTopLayoutElement

Declares layout properties for the top-layout element. See the top-layout element definition.


IDL Definition
interface SMILTopLayoutElement : SMILElement, ElementLayout {
};

Interface SMILRootLayoutElement

Declares layout properties for the root-layout element. See the root-layout element definition.


IDL Definition
interface SMILRootLayoutElement : SMILElement, ElementLayout {
};

Interface SMILRegionElement

Controls the position, size and scaling of media object elements. See the region element definition.


IDL Definition
interface SMILRegionElement : SMILElement, ElementLayout {
           attribute DOMString        fit;
                                        // raises(DOMException) on setting

           attribute DOMString        top;
                                        // raises(DOMException) on setting

           attribute long             zIndex;
                                        // raises(DOMException) on setting

};

Attributes
fit of type DOMString
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

top of type DOMString
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

zIndex of type long
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

The layout module also includes the region attribute, used in SMIL layout to associate layout with content elements. This is represented as an individual interface, that is supported by content elements in SMIL documents (i.e. in profiles that use SMIL layout).

Interface SMILRegionInterface

Declares rendering surface for an element. See the region attribute definition.


IDL Definition
interface SMILRegionInterface {
           attribute SMILRegionElement  region;
};

Attributes
region of type SMILRegionElement

4.5. Timing and synchronization extensions

This module includes extensions for timing and synchronization.

(ED: This will be fleshed out as we work on the timing module. For now, we will define a time leaf interface as a placeholder for simple media elements (i.e. those that are not also time containers). This is just an indication of one possibility - this is subject to discussion and review. )
Interface Time

The Time interface is a datatype that represents times within the timegraph. A Time has a type, key values to describe the time, and a boolean to indicate whether the values are currently unresolved.

(ED: Still need to address the wallclock values. )

IDL Definition
interface Time {
  readonly attribute boolean          resolved;
  readonly attribute double           resolvedOffset;
  // TimeTypes
  const unsigned short      SMIL_TIME_INDEFINITE           = 0;
  const unsigned short      SMIL_TIME_OFFSET               = 1;
  const unsigned short      SMIL_TIME_SYNC_BASED           = 2;
  const unsigned short      SMIL_TIME_EVENT_BASED          = 3;
  const unsigned short      SMIL_TIME_WALLCLOCK            = 4;
  const unsigned short      SMIL_TIME_MEDIA_MARKER         = 5;

  readonly attribute unsigned short   timeType;
           attribute double           offset;
                                        // raises(DOMException) on setting

           attribute Element          baseElement;
                                        // raises(DOMException) on setting

           attribute boolean          baseBegin;
                                        // raises(DOMException) on setting

           attribute DOMString        event;
                                        // raises(DOMException) on setting

           attribute DOMString        marker;
                                        // raises(DOMException) on setting

};

Attributes
resolved of type boolean, readonly
A boolean indicating whether the current Time has been fully resolved to the document schedule. Note that for this to be true, the current Time must be defined (not indefinite), the syncbase and all Time's that the syncbase depends on must be defined (not indefinite), and the begin Time of all ascendent time containers of this element and all Time elements that this depends upon must be defined (not indefinite).
If this Time is based upon an event, this Time will only be resolved once the specified event has happened, subject to the constraints of the time container.
Note that this may change from true to false when the parent time container ends its simple duration (including when it repeats or restarts).

resolvedOffset of type double, readonly
The clock value in seconds relative to the parent time container begin. This indicates the resolved time relationship to the parent time container. This is only valid if resolved is true.

Definition group TimeTypes

An integer indicating the type of this time value.

Defined Constants
SMIL_TIME_INDEFINITE The Time is specified to be "indefinite". The Time may have a resolved value, if a method call is made to activate this time (beginElement for a begin time, or endElement for an active end time). If the Time is resolved, the resolvedOffset will reflect the time at which the method call was made.
The Time attributes offset, baseBegin, event and marker are undefined for this type.
SMIL_TIME_OFFSET The value is a simple offset from the default syncbase. The baseElement will be the default syncbase element defined by the time model, the baseBegin indicates whether the default syncbase is relative to the begin or active end of the baseElement, and the offset will be the specified offset.
The Time attributes baseElement, baseBegin, event and marker are undefined for this type.
SMIL_TIME_SYNC_BASED The value is relative to the begin of the specified baseElement. The baseElement will be the specified syncbase, the baseBegin indicates whether the default syncbase is relative to the begin or active end of the baseElement, and the offset will be the specified offset. Note that this includes times specified with the logical syncbases "prev.begin" or "prev.end".
The Time attributes event and marker are undefined for this type.
SMIL_TIME_EVENT_BASED The value is relative to the specified event raised on the baseElement. The baseElement will be the specified syncbase, and the offset will be the specified offset. If the Time is resolved, the resolvedOffset will reflect the time at which the event was raised.
The Time attributes baseBegin and marker are undefined for this type.
SMIL_TIME_WALLCLOCK The value is specified as a wallclock value. If the Time is resolved, the resolvedOffset will reflect the wallclock time, converted to document time.
The Time attributes baseElement, baseBegin, event and marker are undefined for this type.
SMIL_TIME_MEDIA_MARKER The value is specified as a marker value associated with a given media element. The baseElement will be the specified media element, and the marker will be the name of the media marker value. If the Time is resolved, the resolvedOffset will reflect the time associated with the specified marker value.
The Time attributes offset, baseElement and event are undefined for this type.
timeType of type unsigned short, readonly
A code representing the type of the underlying object, as defined above.

offset of type double
The clock value in seconds relative to the syncbase or eventbase. Default value is 0.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised on attempts to modify this readonly attribute.

baseElement of type Element
The base element for a sync-based or event-based time.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised on attempts to modify this readonly attribute.

baseBegin of type boolean
If true, indicates that a sync-based time is relative to the begin of the baseElement. If false, indicates that a sync-based time is relative to the active end of the baseElement.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised on attempts to modify this readonly attribute.

event of type DOMString
The name of the event for an event-based time. Default value is null.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised on attempts to modify this readonly attribute.

marker of type DOMString
The name of the marker from the media element, for media marker times. Default value is null.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised on attempts to modify this readonly attribute.

Interface TimeList

The TimeList interface provides the abstraction of an ordered collection of times, without defining or constraining how this collection is implemented.

The items in the TimeList are accessible via an integral index, starting from 0.


IDL Definition
interface TimeList {
  Time               item(in unsigned long index);
  readonly attribute unsigned long    length;
};

Attributes
length of type unsigned long, readonly
The number of times in the list. The range of valid child time indices is 0 to length-1 inclusive.

Methods
item
Returns the indexth item in the collection. If index is greater than or equal to the number of times in the list, this returns null.
Parameters

unsigned long

index

Index into the collection.

Return Value

Time

The time at the indexth position in the TimeList, or null if that is not a valid index.

No Exceptions

Interface ElementTime

This interface defines the set of timing attributes that are common to all timed elements.


IDL Definition
interface ElementTime {
           attribute TimeList         begin;
                                        // raises(DOMException) on setting

           attribute TimeList         end;
                                        // raises(DOMException) on setting

           attribute float            dur;
                                        // raises(DOMException) on setting

  // restartTypes
  const unsigned short      RESTART_ALWAYS                 = 0;
  const unsigned short      RESTART_NEVER                  = 1;
  const unsigned short      RESTART_WHEN_NOT_ACTIVE        = 2;

           attribute unsigned short   restart;
                                        // raises(DOMException) on setting

  // fillTypes
  const unsigned short      FILL_REMOVE                    = 0;
  const unsigned short      FILL_FREEZE                    = 1;

           attribute unsigned short   fill;
                                        // raises(DOMException) on setting

           attribute float            repeatCount;
                                        // raises(DOMException) on setting

           attribute float            repeatDur;
                                        // raises(DOMException) on setting

  boolean            beginElement();
  boolean            endElement();
  void               pauseElement();
  void               resumeElement();
  void               seekElement(inout float seekTo);
};

Attributes
begin of type TimeList
The desired value (as a list of times) of the begin instant of this node.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

end of type TimeList
The list of active ends for this node.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

dur of type float
The desired simple duration value of this node in seconds. Negative value means "indefinite".
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Definition group restartTypes

An integer indicating the value of the restart attribute.

Defined Constants
RESTART_ALWAYS
RESTART_NEVER
RESTART_WHEN_NOT_ACTIVE
restart of type unsigned short
A code representing the value of the restart attribute, as defined above. Default value is RESTART_ALWAYS.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Definition group fillTypes

An integer indicating the value of the fill attribute.

Defined Constants
FILL_REMOVE
FILL_FREEZE
fill of type unsigned short
A code representing the value of the fill attribute, as defined above. Default value is FILL_REMOVE.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

repeatCount of type float
The repeatCount attribute causes the element to play repeatedly (loop) for the specified number of times. A negative value repeat the element indefinitely. Default value is 0 (unspecified).
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

repeatDur of type float
The repeatDur causes the element to play repeatedly (loop) for the specified duration in milliseconds. Negative means "indefinite".
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Methods
beginElement
Causes this element to begin the local timeline (subject to sync constraints).
Return Value

boolean

true if the method call was successful and the element was begun. false if the method call failed. Possible reasons for failure include:

  • The element doesn't support the beginElement method. (the beginEvent attribute is not set to "undefinite")
  • The element is already active and can't be restart when it is active. (the restart attribute is set to "whenNotActive")
  • The element is active or has been active and can't be restart. (the restart attribute is set to "never").
No Parameters
No Exceptions

endElement
Causes this element to end the local timeline (subject to sync constraints).
Return Value

boolean

true if the method call was successful and the element was endeed. false if method call failed. Possible reasons for failure include:

  • The element doesn't support the endElement method. (the endEvent attribute is not set to "undefinite")
  • The element is not active.
No Parameters
No Exceptions

pauseElement
Causes this element to pause the local timeline (subject to sync constraints).
No Parameters
No Return Value
No Exceptions

resumeElement
Causes this element to resume a paused local timeline.
No Parameters
No Return Value
No Exceptions

seekElement
Seeks this element to the specified point on the local timeline (subject to sync constraints). If this is a timeline, this must seek the entire timeline (i.e. propagate to all timeChildren).
Parameters

float

seekTo

The desired position on the local timeline in milliseconds.

No Return Value
No Exceptions

Interface ElementTimeManipulation

This interface support use-cases commonly associated with animation.

(ED: "accelerate" and "decelerate" are float values in the timing draft and percentage values even in this draft if both of them represent a percentage. )

IDL Definition
interface ElementTimeManipulation {
           attribute float            speed;
                                        // raises(DOMException) on setting

           attribute float            accelerate;
                                        // raises(DOMException) on setting

           attribute float            decelerate;
                                        // raises(DOMException) on setting

           attribute boolean          autoReverse;
                                        // raises(DOMException) on setting

};

Attributes
speed of type float
Defines the playback speed of element time. The value is specified as a multiple of normal (parent time container) play speed. Legal values are signed floating point values. Zero values are not allowed. The default is 1.0 (no modification of speed).
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

accelerate of type float
The percentage value of the simple acceleration of time for the element. Allowed values are from 0 to 100. Default value is 0 (no acceleration).
The sum of the values for accelerate and decelerate must not exceed 100. If it does, the deceleration value will be reduced to make the sum legal.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

decelerate of type float
The percentage value of the simple decelerate of time for the element. Allowed values are from 0 to 100. Default value is 0 (no deceleration).
The sum of the values for accelerate and decelerate must not exceed 100. If it does, the deceleration value will be reduced to make the sum legal.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

autoReverse of type boolean
The autoReverse attribute controls the "play forwards then backwards" functionality. Default value is false.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Interface ElementTimeContainer

This is a placeholder - subject to change. This represents generic timelines.


IDL Definition
interface ElementTimeContainer : ElementTime {
  readonly attribute NodeList         timeChildren;
  NodeList           getActiveChildrenAt(in float instant);
};

Attributes
timeChildren of type NodeList, readonly
A NodeList that contains all timed childrens of this node. If there are no timed children, the Nodelist is empty.
(ED: An iterator is more appropriate here than a node list but it requires Traversal module support. )

Methods
getActiveChildrenAt
Returns a list of child elements active at the specified invocation.
Parameters

float

instant

The desired position on the local timeline in milliseconds.

Return Value

NodeList

List of timed child-elements active at instant.

No Exceptions

Interface ElementSyncBehavior

The synchronization behavior extension.


IDL Definition
interface ElementSyncBehavior {
  readonly attribute DOMString        syncBehavior;
  readonly attribute float            syncTolerance;
  readonly attribute DOMString        defaultSyncBehavior;
  readonly attribute float            defaultSyncTolerance;
  readonly attribute boolean          syncMaster;
};

Attributes
syncBehavior of type DOMString, readonly
The runtime synchronization behavior for an element.

syncTolerance of type float, readonly
The sync tolerance for the associated element. It has an effect only if the element has syncBehavior="locked".

defaultSyncBehavior of type DOMString, readonly
Defines the default value for the runtime synchronization behavior for an element, and all descendents.

defaultSyncTolerance of type float, readonly
Defines the default value for the sync tolerance for an element, and all descendents.

syncMaster of type boolean, readonly
If set to true, forces the time container playback to sync to this element.

Interface ElementParallelTimeContainer

A parallel container defines a simple parallel time grouping in which multiple elements can play back at the same time.

(ED: It may have to specify a repeat iteration. (?) )

IDL Definition
interface ElementParallelTimeContainer : ElementTimeContainer {
           attribute DOMString        endSync;
                                        // raises(DOMException) on setting

  float              getImplicitDuration();
};

Attributes
endSync of type DOMString
Controls the end of the container.
(ED: Need to address thr id-ref value. )
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Methods
getImplicitDuration
This method returns the implicit duration in seconds.
Return Value

float

The implicit duration in seconds or -1 if the implicit is unknown (indefinite?).

No Parameters
No Exceptions

Interface ElementSequentialTimeContainer

A seq container defines a sequence of elements in which elements play one after the other.


IDL Definition
interface ElementSequentialTimeContainer : ElementTimeContainer {
};

Interface ElementExclusiveTimeContainer

This interface defines a time container with semantics based upon par, but with the additional constraint that only one child element may play at a time.


IDL Definition
interface ElementExclusiveTimeContainer : ElementTimeContainer {
           attribute DOMString        endSync;
                                        // raises(DOMException) on setting

  NodeList           getPausedElements();
};

Attributes
endSync of type DOMString
Controls the end of the container.
(ED: Need to address thr id-ref value. )
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Methods
getPausedElements
This should support another method to get the ordered collection of paused elements (the paused stack) at a given point in time.
Return Value

NodeList

All paused elements at the current time.

No Parameters
No Exceptions

4.5.1. Timing Events

Interface TimeEvent

The TimeEvent interface provides specific contextual information associated with Time events.


IDL Definition
interface TimeEvent : events::Event {
  readonly attribute views::AbstractView  view;
  readonly attribute long             detail;
  void               initTimeEvent(in DOMString typeArg, 
                                   in views::AbstractView viewArg, 
                                   in long detailArg);
};

Attributes
view of type views::AbstractView, readonly
The view attribute identifies the AbstractView from which the event was generated.

detail of type long, readonly
Specifies some detail information about the Event, depending on the type of event.

Methods
initTimeEvent
The initTimeEvent method is used to initialize the value of a TimeEvent created through the DocumentEvent interface. This method may only be called before the TimeEvent has been dispatched via the dispatchEvent method, though it may be called multiple times during that phase if necessary. If called multiple times, the final invocation takes precedence.
Parameters

DOMString

typeArg

Specifies the event type.

views::AbstractView

viewArg

Specifies the Event's AbstractView.

long

detailArg

Specifies the Event's detail.

No Return Value
No Exceptions

The different types of events that can occur are:

begin
This event is raised when the element local timeline begins to play. It will be raised each time the element begins the active duration (i.e. when it restarts, but not when it repeats). It may be raised both in the course of normal (i.e. scheduled or interactive) timeline play, as well as in the case that the element was begun with the beginElement() or beginElementAt() methods. Note that if an element is restarted while it is currently playing, the element will raise an end event and another begin event, as the element restarts.
  • Bubbles: No
  • Cancelable: No
  • Context Info: None
end
This event is raised at the active end of the element. Note that this event is not raised at the simple end of each repeat. This event may be raised both in the course of normal (i.e. scheduled or interactive) timeline play, as well as in the case that the element was ended with the endElement() or endElementAt() methods. Note that if an element is restarted while it is currently playing, the element will raise an end event and another begin event, as the element restarts.
  • Bubbles: No
  • Cancelable: No
  • Context Info: None
repeat
This event is raised when the element local timeline repeats. It will be raised each time the element repeats, after the first iteration.
The Time event interface supports a property "detail" that indicates which repeat iteration is beginning. The value is a 0-based integer, but the repeat event is not raised for the first iteration and so the observed values will be >= 1. of the element ?
  • Bubbles: No
  • Cancelable: No
  • Context Info: number of iterations

4.6. Media Object extensions

This module includes the media elements, and associated attributes. They are all currently represented by a single interface, as there are no specific attributes for individual media elements.

Interface SMILMediaElement

Declares media content.


IDL Definition
interface SMILMediaElement : ElementTime, SMILElement {
           attribute DOMString        abstractAttr;
                                        // raises(DOMException) on setting

           attribute DOMString        alt;
                                        // raises(DOMException) on setting

           attribute DOMString        author;
                                        // raises(DOMException) on setting

           attribute DOMString        clipBegin;
                                        // raises(DOMException) on setting

           attribute DOMString        clipEnd;
                                        // raises(DOMException) on setting

           attribute DOMString        copyright;
                                        // raises(DOMException) on setting

           attribute DOMString        longdesc;
                                        // raises(DOMException) on setting

           attribute DOMString        port;
                                        // raises(DOMException) on setting

           attribute DOMString        readIndex;
                                        // raises(DOMException) on setting

           attribute DOMString        rtpformat;
                                        // raises(DOMException) on setting

           attribute DOMString        src;
                                        // raises(DOMException) on setting

           attribute DOMString        stripRepeat;
                                        // raises(DOMException) on setting

           attribute DOMString        title;
                                        // raises(DOMException) on setting

           attribute DOMString        transport;
                                        // raises(DOMException) on setting

           attribute DOMString        type;
                                        // raises(DOMException) on setting

};

Attributes
abstractAttr of type DOMString
See the abstract attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

alt of type DOMString
See the alt attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

author of type DOMString
See the author attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

clipBegin of type DOMString
See the clipBegin attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

clipEnd of type DOMString
See the clipEnd attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

copyright of type DOMString
See the copyright attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

longdesc of type DOMString
See the longdesc attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

port of type DOMString
See the port attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

readIndex of type DOMString
See the readIndex attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

rtpformat of type DOMString
See the rtpformat attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

src of type DOMString
See the src attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

stripRepeat of type DOMString
See the stripRepeat attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

title of type DOMString
See the title attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

transport of type DOMString
See the transport attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

type of type DOMString
See the type attribute from [SMIL Boston].
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Interface SMILRefElement
(ED: // audio, video, ... )

IDL Definition
interface SMILRefElement : SMILMediaElement {
};

4.7. Animations extensions

This module will include interfaces associated with animation extensions.

4.7.1. SMIL Animation

The following interface comes from the SMIL Animation draft.

Interface ElementTimeControl

IDL Definition
interface ElementTimeControl {
  boolean            beginElement()
                                        raises(DOMException);
  boolean            beginElementAt(in float offset)
                                        raises(DOMException);
  boolean            endElement()
                                        raises(DOMException);
  boolean            endElementAt(in float offset)
                                        raises(DOMException);
};

Methods
beginElement
Causes this element to begin the local timeline (subject to sync constraints).
Return Value

boolean

true if the method call was successful and the element was begun. false if the method call failed. Possible reasons for failure include:

  • The element doesn't support the beginElement method. (the begin attribute is not set to "indefinite")
  • The element is already active and can't be restart when it is active. (the restart attribute is set to "whenNotActive")
  • The element is active or has been active and can't be restart. (the restart attribute is set to "never").
Exceptions

DOMException

SYNTAX_ERR: The element was not defined with the appropriate syntax to allow beginElement calls.

No Parameters

beginElementAt
Causes this element to begin the local timeline (subject to sync constraints), at the passed offset from the current time when the method is called. If the offset is >= 0, the semantics are equivalent to an event-base begin with the specified offset. If the offset is < 0, the semantics are equivalent to beginElement(), but the element active duration is evaluated as though the element had begun at the passed (negative) offset from the current time when the method is called.
Parameters

float

offset

The offset in seconds at which to begin the element.

Return Value

boolean

true if the method call was successful and the element was begun. false if the method call failed. Possible reasons for failure include:

  • The element doesn't support the beginElementAt method. (the begin attribute is not set to "indefinite")
  • The element is already active and can't be restart when it is active. (the restart attribute is set to "whenNotActive")
  • The element is active or has been active and can't be restart. (the restart attribute is set to "never").
Exceptions

DOMException

SYNTAX_ERR: The element was not defined with the appropriate syntax to allow beginElementAt calls.

endElement
Causes this element to end the local timeline (subject to sync constraints).
Return Value

boolean

true if the method call was successful and the element was ended. false if method call failed. Possible reasons for failure include:

  • The element doesn't support the endElement method. (the end attribute is not set to "indefinite")
  • The element is not active.
Exceptions

DOMException

SYNTAX_ERR: The element was not defined with the appropriate syntax to allow endElement calls.

No Parameters

endElementAt
Causes this element to end the local timeline (subject to sync constraints) at the specified offset from the current time when the method is called.
Parameters

float

offset

The offset in seconds at which to end the element. Must be >= 0.

Return Value

boolean

true if the method call was successful and the element was ended. false if method call failed. Possible reasons for failure include:

  • The element doesn't support the endElementAt method. (the end attribute is not set to "indefinite")
  • The element is not active.
Exceptions

DOMException

SYNTAX_ERR: The element was not defined with the appropriate syntax to allow endElementAt calls.

4.7.2. SMIL Boston Animation

Interface SMILAnimation

This interface define the set of animation extensions for SMIL.

(ED: The [XLink] attributes will go in a XLink interface. )

IDL Definition
interface SMILAnimation : SMILElement, ElementTargetAttributes, ElementTime, ElementTimeControl {
  // additiveTypes
  const unsigned short      ADDITIVE_REPLACE               = 0;
  const unsigned short      ADDITIVE_SUM                   = 1;

           attribute unsigned short   additive;
                                        // raises(DOMException) on setting

  // accumulateTypes
  const unsigned short      ACCUMULATE_NONE                = 0;
  const unsigned short      ACCUMULATE_SUM                 = 1;

           attribute unsigned short   accumulate;
                                        // raises(DOMException) on setting

  // calcModeTypes
  const unsigned short      CALCMODE_DISCRETE              = 0;
  const unsigned short      CALCMODE_LINEAR                = 1;
  const unsigned short      CALCMODE_PACED                 = 2;
  const unsigned short      CALCMODE_SPLINE                = 3;

           attribute unsigned short   calcMode;
                                        // raises(DOMException) on setting

           attribute DOMString        keySplines;
                                        // raises(DOMException) on setting

           attribute TimeList         keyTimes;
                                        // raises(DOMException) on setting

           attribute DOMString        values;
                                        // raises(DOMException) on setting

           attribute DOMString        from;
                                        // raises(DOMException) on setting

           attribute DOMString        to;
                                        // raises(DOMException) on setting

           attribute DOMString        by;
                                        // raises(DOMException) on setting

};

Definition group additiveTypes
Defined Constants
ADDITIVE_REPLACE
ADDITIVE_SUM
Attributes
additive of type unsigned short
A code representing the value of the additive attribute, as defined above. Default value is ADDITIVE_REPLACE.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Definition group accumulateTypes
Defined Constants
ACCUMULATE_NONE
ACCUMULATE_SUM
accumulate of type unsigned short
A code representing the value of the accumulate attribute, as defined above. Default value is ACCUMULATE_NONE.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Definition group calcModeTypes
Defined Constants
CALCMODE_DISCRETE
CALCMODE_LINEAR
CALCMODE_PACED
CALCMODE_SPLINE
calcMode of type unsigned short
A code representing the value of the calcMode attribute, as defined above.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

keySplines of type DOMString
A DOMString representing the value of the keySplines attribute.
(ED: Need an interface a point (x1,y1,x2,y2) )
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

keyTimes of type TimeList
A list of the time value of the keyTimes attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

values of type DOMString
A DOMString representing the value of the values attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

from of type DOMString
A DOMString representing the value of the from attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

to of type DOMString
A DOMString representing the value of the to attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

by of type DOMString
A DOMString representing the value of the by attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Interface ElementTargetAttributes

This interface define the set of animation target extensions.


IDL Definition
interface ElementTargetAttributes {
           attribute DOMString        attributeName;
  // attributeTypes
  const unsigned short      ATTRIBUTE_TYPE_AUTO            = 0;
  const unsigned short      ATTRIBUTE_TYPE_CSS             = 1;
  const unsigned short      ATTRIBUTE_TYPE_XML             = 2;

           attribute unsigned short   attributeType;
};

Attributes
attributeName of type DOMString
The name of the target attribute.

Definition group attributeTypes
Defined Constants
ATTRIBUTE_TYPE_AUTO
ATTRIBUTE_TYPE_CSS
ATTRIBUTE_TYPE_XML
attributeType of type unsigned short
A code representing the value of the attributeType attribute, as defined above. Default value is ATTRIBUTE_TYPE_CODE.

Interface SMILAnimateElement

This interface represents the SMIL animate element.


IDL Definition
interface SMILAnimateElement : SMILAnimation {
};

Interface SMILSetElement

This interface represents the set element.


IDL Definition
interface SMILSetElement : ElementTimeControl, ElementTime, ElementTargetAttributes, SMILElement {
           attribute DOMString        to;
};

Attributes
to of type DOMString
Specifies the value for the attribute during the duration of this element.

Interface SMILAnimateMotionElement

This interface present the animationMotion element in SMIL.


IDL Definition
interface SMILAnimateMotionElement : SMILAnimateElement {
           attribute DOMString        path;
                                        // raises(DOMException) on setting

           attribute DOMString        origin;
                                        // raises(DOMException) on setting

};

Attributes
path of type DOMString
Specifies the curve that describes the attribute value as a function of time.
(ED: Check with the SVG spec for better support )
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

origin of type DOMString
Specifies the origin of motion for the animation.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

Interface SMILAnimateColorElement

This interface represents the SMIL animateColor element.


IDL Definition
interface SMILAnimateColorElement : SMILAnimation {
};

4.8. Transition extensions

This module will include interfaces associated with transition markup. This is yet to be defined.

4.9. Linking extensions

This module includes interfaces for hyperlinking elements.

4.10. Content Control extensions

This module includes interfaces for content control markup.

Interface SMILSwitchElement

Defines a block of content control. See the switch element definition.


IDL Definition
interface SMILSwitchElement : SMILElement {
  Element            getSelectedElement();
};

Methods
getSelectedElement
Returns the slected element at runtime. null if the selected element is not yet available.
Return Value

Element

The selected Element for thisd switch element.

No Parameters
No Exceptions

Interface ElementTest

Defines the test attributes interface. See the Test attributes definition.


IDL Definition
interface ElementTest {
           attribute long             systemBitrate;
                                        // raises(DOMException) on setting

           attribute boolean          systemCaptions;
                                        // raises(DOMException) on setting

           attribute DOMString        systemLanguage;
                                        // raises(DOMException) on setting

  readonly attribute boolean          systemRequired;
  readonly attribute boolean          systemScreenSize;
  readonly attribute boolean          systemScreenDepth;
           attribute DOMString        systemOverdubOrSubtitle;
                                        // raises(DOMException) on setting

           attribute boolean          systemAudioDesc;
                                        // raises(DOMException) on setting

};

Attributes
systemBitrate of type long
The systemBitrate value.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

systemCaptions of type boolean
The systemCaptions value.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

systemLanguage of type DOMString
The systemLanguage value.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

systemRequired of type boolean, readonly
The result of the evaluation of the systemRequired attribute.

systemScreenSize of type boolean, readonly
The result of the evaluation of the systemScreenSize attribute.

systemScreenDepth of type boolean, readonly
The result of the evaluation of the systemScreenDepth attribute.

systemOverdubOrSubtitle of type DOMString
The value of the systemOverdubOrSubtitle attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

systemAudioDesc of type boolean
The value of the systemAudioDesc attribute.
Exceptions on setting

DOMException

NO_MODIFICATION_ALLOWED_ERR: Raised if this attribute is readonly.

4.11. Media Player extensions

(ED: This is NOT a plug-in interface, but rather a simple interface that describes some guaranteed methods that any application plug-in interface must support. This provides a means of standardizing extensions to the timing model, independent of the specific application. )

4.11.1. Media Player Level 1 Interface

4.11.2. Media Player Level 2 Interface

4.11.3. Media Player Level 3 Interface


previous   next   contents   index