Class in reactor_media_surfaces.js
MediaSurfaceOwner
47 public functions in 7 groups · show internal (_) functions
Quick Reference
Setup & Creation 12
| constructor() | Sets up a new instance. |
| createVideo() | Creates the video. |
| createImage() | Creates the image. |
| attach() | Attach. |
| attachmentKeyFor() | Attachment key for. |
| attachPixi() | Attach pixi. |
| createPixiScanline() | Creates the pixi scanline. |
| attachThree() | Attach three. |
| ensureUpperPass() | Ensure upper pass. |
| makeThreeGeometry() | Makes the three geometry. |
| createThreeScanline() | Creates the three scanline. |
| ensureAudioRoute() | Ensure audio route. |
Getting Information 1
| current() | Current. |
Checks (True / False) 1
| needsRecreate() | Whether it needs recreate. |
Actions 7
| startPlayback() | Starts the playback. |
| restoreAndPlay() | Restores the and play. |
| play() | Play. |
| destroyPixiScanline() | Destroy pixi scanline. |
| destroyThreeScanline() | Destroy three scanline. |
| setPixiCorners() | Sets the pixi corners. |
| applyDescriptor() | Applies the descriptor. |
Events, Commands & Input 2
| listen() | Listen. |
| listenVideo() | Listen video. |
Updating & Drawing 7
| syncPixiScanlines() | Sync pixi scanlines. |
| syncThreeScanlines() | Sync three scanlines. |
| updateAudio() | Updates the audio each frame. |
| updatePixiPosition() | Updates the pixi position each frame. |
| syncVideoUploads() | A playing video uploads every decoded frame to the GPU whether its quad is drawn or not: a flat map with a ro… |
| updateThreePosition() | Updates the three position each frame. |
| update() | Update. |
Other 17
| imageReady() | Image ready. |
| imageSource() | The picture as loaded, for a texture that takes any image-like: no canvas copy is made of it. |
| imageCanvas() | The decoded pixels as a canvas, for PIXI's CanvasSource. |
| desiredBackend() | Desired backend. |
| mapWants3D() | Map wants3 d. |
| autoplayBlocked() | Autoplay blocked. |
| retryPlayback() | Retry playback. |
| threeGroup() | Three group. |
| worldSize() | World size. |
| worldWidth() | The two halves of worldSize, for the per-tick placement, which made a record of them twice a frame per surfac… |
| worldHeight() | World height. |
| character() | Character. |
| transformedCorners() | Transformed corners. |
| cornerTurn() | The descriptor's turn and perspective, for transformCorner; one record, refilled. |
| transformCorner() | One corner of the flat quad, turned and foreshortened, into out. |
| captureCurrentTime() | Capture current time. |
| cleanup() | Cleanup. |
Setup & Creation
constructor
constructor sourcenew MediaSurfaceOwner(manager, descriptor, spriteset)
Sets up a new instance.
createVideo
method sourceMediaSurfaceOwner.prototype.createVideo()
Creates the video.
createImage
method sourceMediaSurfaceOwner.prototype.createImage()
Creates the image.
attach
method sourceMediaSurfaceOwner.prototype.attach(spriteset)
Attach.
attachmentKeyFor
method sourceMediaSurfaceOwner.prototype.attachmentKeyFor(descriptor)
Attachment key for.
attachPixi
method sourceMediaSurfaceOwner.prototype.attachPixi(spriteset)
Attach pixi.
createPixiScanline
method sourceMediaSurfaceOwner.prototype.createPixiScanline()
Creates the pixi scanline.
attachThree
method sourceMediaSurfaceOwner.prototype.attachThree(state)
Attach three.
ensureUpperPass
method sourceMediaSurfaceOwner.prototype.ensureUpperPass(state, scene)
Ensure upper pass.
makeThreeGeometry
method sourceMediaSurfaceOwner.prototype.makeThreeGeometry()
Makes the three geometry.
createThreeScanline
method sourceMediaSurfaceOwner.prototype.createThreeScanline(group)
Creates the three scanline.
ensureAudioRoute
method sourceMediaSurfaceOwner.prototype.ensureAudioRoute()
Ensure audio route.
Getting Information
current
method sourceMediaSurfaceOwner.prototype.current()
Current.
Checks (True / False)
needsRecreate
method sourceMediaSurfaceOwner.prototype.needsRecreate(descriptor)
Whether it needs recreate.
Actions
startPlayback
method sourceMediaSurfaceOwner.prototype.startPlayback()
Starts the playback.
restoreAndPlay
method sourceMediaSurfaceOwner.prototype.restoreAndPlay()
Restores the and play.
play
method sourceMediaSurfaceOwner.prototype.play()
Play.
destroyPixiScanline
method sourceMediaSurfaceOwner.prototype.destroyPixiScanline()
Destroy pixi scanline.
destroyThreeScanline
method sourceMediaSurfaceOwner.prototype.destroyThreeScanline()
Destroy three scanline.
setPixiCorners
method sourceMediaSurfaceOwner.prototype.setPixiCorners(mesh, corners)
Sets the pixi corners.
applyDescriptor
method sourceMediaSurfaceOwner.prototype.applyDescriptor(descriptor, forceGeometry)
Applies the descriptor.
Events, Commands & Input
listen
method sourceMediaSurfaceOwner.prototype.listen(target, type, callback, options)
Listen.
listenVideo
method sourceMediaSurfaceOwner.prototype.listenVideo(video)
Listen video.
Updating & Drawing
syncPixiScanlines
method sourceMediaSurfaceOwner.prototype.syncPixiScanlines()
Sync pixi scanlines.
syncThreeScanlines
method sourceMediaSurfaceOwner.prototype.syncThreeScanlines(group)
Sync three scanlines.
updateAudio
method sourceMediaSurfaceOwner.prototype.updateAudio()
Updates the audio each frame.
updatePixiPosition
method sourceMediaSurfaceOwner.prototype.updatePixiPosition()
Updates the pixi position each frame.
syncVideoUploads
method sourceMediaSurfaceOwner.prototype.syncVideoUploads(minX, minY, maxX, maxY, graphics)
A playing video uploads every decoded frame to the GPU whether its quad is drawn or not: a flat map with a row of screens off to the side spent more on those uploads than on the whole map.
Details
A playing video uploads every decoded frame to the GPU whether its quad is drawn or not: a flat map with a row of screens off to the side spent more on those uploads than on the whole map. Off screen (judged through the parent's last rendered transform, with a margin for that frame of lag) the uploads wait, and the frame showing now goes up the moment the quad comes back. Playback itself carries on.
updateThreePosition
method sourceMediaSurfaceOwner.prototype.updateThreePosition()
Updates the three position each frame.
update
method sourceMediaSurfaceOwner.prototype.update()
Update.
Other
imageReady
method sourceMediaSurfaceOwner.prototype.imageReady()
Image ready.
imageSource
method sourceMediaSurfaceOwner.prototype.imageSource()
The picture as loaded, for a texture that takes any image-like: no canvas copy is made of it.
imageCanvas
method sourceMediaSurfaceOwner.prototype.imageCanvas()
The decoded pixels as a canvas, for PIXI's CanvasSource.
desiredBackend
method sourceMediaSurfaceOwner.prototype.desiredBackend(descriptor)
Desired backend.
mapWants3D
method sourceMediaSurfaceOwner.prototype.mapWants3D()
Map wants3 d.
autoplayBlocked
method sourceMediaSurfaceOwner.prototype.autoplayBlocked(error)
Autoplay blocked.
retryPlayback
method sourceMediaSurfaceOwner.prototype.retryPlayback()
Retry playback.
threeGroup
method sourceMediaSurfaceOwner.prototype.threeGroup(state, descriptor)
Three group.
worldSize
method sourceMediaSurfaceOwner.prototype.worldSize()
World size.
worldWidth
method sourceMediaSurfaceOwner.prototype.worldWidth()
The two halves of worldSize, for the per-tick placement, which made a record of them twice a frame per surface to read two numbers.
worldHeight
method sourceMediaSurfaceOwner.prototype.worldHeight()
World height.
character
method sourceMediaSurfaceOwner.prototype.character()
Character.
transformedCorners
method sourceMediaSurfaceOwner.prototype.transformedCorners()
Transformed corners.
cornerTurn
method sourceMediaSurfaceOwner.prototype.cornerTurn()
The descriptor's turn and perspective, for transformCorner; one record, refilled.
transformCorner
method sourceMediaSurfaceOwner.prototype.transformCorner(corner, turn, out)
One corner of the flat quad, turned and foreshortened, into out.
captureCurrentTime
method sourceMediaSurfaceOwner.prototype.captureCurrentTime(descriptor)
Capture current time.
cleanup
method sourceMediaSurfaceOwner.prototype.cleanup(reason)
Cleanup.