Difference between revisions of "DOMCurve"

From Virtual World Web Wiki
Jump to: navigation, search
(Documentation for the DOMCurve class)
(Documentation for the DOMCurve class)
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
Represents an animation of DOM properties over time. A Curve is made up of [[DOMCurveKeyframe]] child nodes with time indexes. Each keyframe can have multiple [[DOMCurveValue]] nodes which set the value of a property at that point in time. Then a [[DOMCurvePlayer]] node "plays" the curve, projecting its animated properties onto other DOM nodes in the scene that match the [[Selectors|selector]] specified. The results of a curve's playing are not guarenteed to be perfectly synchronized, but many efforts are made to ensure all clients and the server are as close as possible. This is a powerful mechanism for low-cost, high-frequency animations of the DOM with almost no network traffic.
+
Represents an animation of DOM properties over time. A Curve is made up of [[DOMCurveKeyframe]] child nodes with time indexes. Each keyframe can have multiple [[DOMCurveValue]] nodes which set the value of a property at that point in time. Then a [[DOMCurvePlayer]] node "plays" the curve, projecting its animated properties onto other DOM nodes in the scene that match the [[CSS Selector]] specified. The results of a curve's playing are not guarenteed to be perfectly synchronized, but many efforts are made to ensure all clients and the server are as close as possible. This is a powerful mechanism for low-cost, high-frequency animations of the DOM with almost no network traffic.
  
'''See also:''' [[DOM Curves]]
+
'''See also:''' [[Curves]]
  
 
*'''Inherits class: [[DOMObject]]'''
 
*'''Inherits class: [[DOMObject]]'''

Latest revision as of 14:13, 19 February 2019

Represents an animation of DOM properties over time. A Curve is made up of DOMCurveKeyframe child nodes with time indexes. Each keyframe can have multiple DOMCurveValue nodes which set the value of a property at that point in time. Then a DOMCurvePlayer node "plays" the curve, projecting its animated properties onto other DOM nodes in the scene that match the CSS Selector specified. The results of a curve's playing are not guarenteed to be perfectly synchronized, but many efforts are made to ensure all clients and the server are as close as possible. This is a powerful mechanism for low-cost, high-frequency animations of the DOM with almost no network traffic.

See also: Curves

Remarks [edit]

Constructors

DOMCurve()
Constructs a new DOMCurve with default settings
DOMCurve(DOMObject[] children)
Constructs a new DOMCurve, adding children at the same time
DOMCurve(string title, DOMObject[] children)
Constructs a new DOMCurve, setting a title and adding children at the same time

Methods

DOMCurve FromJson(string json)
loads a curve's keyframes and keyframe values from JSON
string ToJson()
Converts the current curve and its keyframes and keyframe values to JSON