Appearance
@tmrw-realityos/world • Docs
@tmrw-realityos/world / Components / Surface
Class: Surface
Surface component
Extends
Constructors
new Surface()
new Surface():
Surface
Returns
Overrides
Defined in
world/components/surface.ts:52
Properties
canvas?
optional
canvas:HTMLCanvasElement
Defined in
world/components/surface.ts:34
cursor
cursor:
vec2
Defined in
world/components/surface.ts:35
enabled
enabled:
boolean
=true
Inherited from
Defined in
index
index:
number
Defined in
world/components/surface.ts:32
isVisible
isVisible:
boolean
=true
Defined in
world/components/surface.ts:37
mustSave
mustSave:
boolean
=true
Inherited from
Defined in
parent?
optional
parent:ComponentsContainer
Inherited from
Defined in
proxyNodeName
proxyNodeName:
string
=""
Defined in
world/components/surface.ts:31
tv
tv:
boolean
=true
Defined in
world/components/surface.ts:38
uid
uid:
string
=""
Inherited from
Defined in
allowSurface
static
allowSurface:boolean
=true
Defined in
world/components/surface.ts:50
compName
static
compName:string
="Surface"
Overrides
Defined in
world/components/surface.ts:28
emissiveFactor
static
emissiveFactor:vec3
Defined in
world/components/surface.ts:49
lastIndex
static
lastIndex:number
=0
Defined in
world/components/surface.ts:29
Accessors
entity
get
entity():undefined
|Entity
set
entity(_v
):void
Parameters
• _v: Entity
Returns
undefined
| Entity
Inherited from
Defined in
Methods
configure()
configure(
o
):void
Parameters
• o
• o.proxy_node: string
Returns
void
Overrides
Defined in
world/components/surface.ts:274
drawApp()
drawApp(
canvas
,ctx
):void
Parameters
• canvas: HTMLCanvasElement
• ctx: CanvasRenderingContext2D
Returns
void
Defined in
world/components/surface.ts:240
getCompName()
getCompName():
string
Returns
string
Inherited from
Defined in
getTargetNode()
getTargetNode():
undefined
|Node
Returns
undefined
| Node
Defined in
world/components/surface.ts:103
onAdded()
onAdded():
void
Returns
void
Overrides
Defined in
world/components/surface.ts:58
onClick()?
optional
onClick():void
Returns
void
Inherited from
Defined in
onDrawGizmos()
onDrawGizmos(
renderer
):void
Parameters
• renderer: RendererInterface
Returns
void
Defined in
world/components/surface.ts:278
onMouse()
onMouse(
e
):void
Parameters
• e: PointerEvent
Returns
void
Defined in
world/components/surface.ts:84
onRay()
onRay(
ray
):void
Parameters
• ray: Ray
Returns
void
Defined in
world/components/surface.ts:89
onRemoved()
onRemoved():
void
Returns
void
Overrides
Defined in
world/components/surface.ts:77
onUpdate()?
optional
onUpdate(dt
):void
Parameters
• dt: number
Returns
void
Inherited from
Defined in
preRender()
preRender(
camera
):void
Parameters
• camera: Camera
Returns
void
Defined in
world/components/surface.ts:120
serialize()
serialize():
void
Returns
void
Inherited from
Defined in
updateCanvas()
updateCanvas(
camera
):void
Parameters
• camera: Camera
Returns
void
Defined in
world/components/surface.ts:186
setEmissiveFactor()
static
setEmissiveFactor(v
):void
Parameters
• v: number
| vec3
Returns
void