Class: NTCTextureSource
Owns a source texture plus the (optional) render target that produced it,
so a caller doesn't have to track "is this a baked texture I own a
render target for, or a plain loaded texture I own directly?" via a
separate nullable variable. dispose() releases whichever one applies -
disposing the render target's own copy of the texture, never both.
Constructors
Constructor
new NTCTextureSource(
texture,renderTarget?):NTCTextureSource
Parameters
texture
any
renderTarget?
any = null
Returns
NTCTextureSource
Properties
renderTarget
renderTarget:
any
texture
texture:
any
Methods
dispose()
dispose():
void
Returns
void
fromBakedColorNode()
staticfromBakedColorNode(renderer,colorNode,resolution?,uvTransform?):Promise<NTCTextureSource>
Parameters
renderer
any
colorNode
any
resolution?
number = 512
uvTransform?
any = null
Returns
Promise<NTCTextureSource>
fromImage()
staticfromImage(url):Promise<NTCTextureSource>
Parameters
url
string
Returns
Promise<NTCTextureSource>