forked from Jibo-Revival-Group/JiboOs
155 lines
3.9 KiB
JavaScript
155 lines
3.9 KiB
JavaScript
/**
|
|
* The representation of the eye.
|
|
* @class EyeContainer
|
|
* @memberof jibo.face
|
|
* @extends PIXI.Container
|
|
*/
|
|
|
|
/**
|
|
* Eye display.
|
|
* @name jibo.face.EyeContainer#eye
|
|
* @type {jibo.face.Eye}
|
|
*/
|
|
|
|
/**
|
|
* Eye overlay display.
|
|
* @name jibo.face.EyeContainer#eyeOverlay
|
|
* @type {jibo.face.EyeOverlay}
|
|
*/
|
|
|
|
/**
|
|
* The background border for debugging.
|
|
* @name jibo.face.EyeContainer#backgroundBorder
|
|
* @type {PIXI.Graphics}
|
|
*/
|
|
|
|
/**
|
|
* The background of eye.
|
|
* @name jibo.face.EyeContainer#background
|
|
* @type {jibo.face.Background}
|
|
*/
|
|
|
|
/**
|
|
* `true` if the eye is connected to the DOF values.
|
|
* @name jibo.face.EyeContainer#connected
|
|
* @type {Boolean}
|
|
*/
|
|
|
|
/**
|
|
* Glow Filter for eye display.
|
|
* Must enable with `jibo.face.eye.glow.enabled = true`
|
|
* @name jibo.face.EyeContainer#glow
|
|
* @type {jibo.face.GlowFilter}
|
|
*/
|
|
|
|
/**
|
|
* Lighting Filter for eye display.
|
|
* Must enable with `jibo.face.eye.lighting.enabled = true`
|
|
* @name jibo.face.EyeContainer#lighting
|
|
* @type {jibo.face.LightFilter}
|
|
*/
|
|
|
|
/**
|
|
* Adds a face animation to play.
|
|
* @method jibo.face#addAnimation
|
|
* @param {jibo.rendering.animation.KeysAnimation} anim The animation to play.
|
|
*/
|
|
|
|
/**
|
|
* Removes a face animation. It will be destroyed in the future (but soon) to avoid flickering
|
|
* between animations.
|
|
* @method jibo.face#removeAnimation
|
|
* @param {jibo.rendering.animation.KeysAnimation} anim The animation to remove - this should a playing animation.
|
|
*/
|
|
|
|
/**
|
|
* Holds the current face animation if it is scheduled for removal. It will be removed the next
|
|
* time that an animation is set.
|
|
* @method jibo.face#holdCurrentAnim
|
|
*/
|
|
|
|
/**
|
|
* Get a texture from the current loaded animation.
|
|
* @method jibo.face#getTexture
|
|
* @param {String} value Full path to the file to use.
|
|
* @return {PIXI.Texture} Texture from the animation.
|
|
*/
|
|
|
|
/**
|
|
* If the eye is active.
|
|
* @method jibo.face#active
|
|
* @type {boolean}
|
|
*/
|
|
|
|
/**
|
|
* Update the DOFValues for display.
|
|
* @private
|
|
* @method jibo.face.EyeContainer#display
|
|
* @param {Array<number>} timestamp Global timestamps in seconds and milliseconds.
|
|
* @param {jibo.face.DOFValues} dofValues Collection of animation values.
|
|
* @param {Object} [meta] Optional object for timeline timestamps.
|
|
*/
|
|
|
|
/**
|
|
* Changes the zoom level. Default is 1 = 100%.
|
|
* @method jibo.face.eyeContainer#zoom
|
|
* @type {number}
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Make a border around the screen.
|
|
* @method jibo.face.EyeContainer#makeBorder
|
|
* @param {Array<Number>} timestamp Timestamp when update is called.
|
|
* @param {String} dofValues Update display according to these values.
|
|
* @param {Object} meta
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Cleans up the renderer.
|
|
* @method jibo.face.EyeContainer#destroy
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Get the default texture names.
|
|
* @method jibo.face.EyeContainer#_getDefaultTextures
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Handle when the timeline needs to be reordered.
|
|
* @method jibo.face.EyeContainer#onAnimationReorder
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Handle when the animation stops.
|
|
* @method jibo.face.EyeContainer#onAnimationStopped
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Queues a face animation for removal.
|
|
* @method jibo.face#queueAnimRemoval
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Removes the current face animation, and sets up the pending one.
|
|
* @method jibo.face#swapLastAnimForPending
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Removes the current face animation, destroying it.
|
|
* @method jibo.face#removeLastAnim
|
|
* @private
|
|
*/
|
|
|
|
/**
|
|
* Removes the current face animation, destroying it and resetting the eye.
|
|
* @method jibo.face#removeLastAnimAndReset
|
|
* @private
|
|
*/ |