TextureResource constructor
TextureResource(})
Creates a texture from an embedded payload or an external asset.
Implementation
TextureResource(
super.id, {
this.payload,
this.asset,
this.content = 'color',
super.unknown,
}) : assert(
(payload == null) != (asset == null),
'A texture has exactly one source: a payload or an asset',
);