new VideoBaseTexture(source [, scaleMode])
Parameters:
Name | Type | Argument | Description |
---|---|---|---|
source |
HTMLVideoElement | ||
scaleMode |
number |
<optional> |
See PIXI.SCALE_MODES for possible values |
Extends
- PIXI.BaseTexture
Methods
-
<static> fromUrl(videoSrc, scaleMode)
-
Helper function that creates a new BaseTexture based on the given video element.
This BaseTexture can then be used to create a textureParameters:
Name Type Description videoSrc
string | object | Array.<string> | Array.<object> The URL(s) for the video.
Properties
Name Type Argument Description src
string <optional>
One of the source urls for the video
mime
string <optional>
The mimetype of the video (e.g. 'video/mp4'). If not specified
the url's extension will be used as the second part of the mime type.scaleMode
number See PIXI.SCALE_MODES for possible values
Returns:
-
<static> fromVideo(video, scaleMode)
-
Mimic Pixi BaseTexture.from.... method.
Parameters:
Name Type Description video
HTMLVideoElement scaleMode
number See PIXI.SCALE_MODES for possible values
Returns:
-
destroy()
-
Destroys this texture