Astra Unity 2.6.6
Astra Unity Plugin
Astra.Asset.MaterialLoadJob Class Reference

Allows creation of materials from our PrimitiveMaterials More...

Inheritance diagram for Astra.Asset.MaterialLoadJob:

Classes

class  MaterialLoadOptions
 Options when loading a material More...
 
class  MaterialLoadResult
 Results from loading a material More...
 

Public Member Functions

override Loader.LoadError GetError ()
 When the job is complete this function can be called by the developer to access the error data set which can be of any type (defined as T2). This needs to be defined if your derived class as an override. More...
 
override MaterialLoadResult GetResult ()
 When the job is complete this function can be called by the developer to access the result data set which can be of any type (defined as T1). This needs to be defined if your derived class as an override. More...
 
- Public Member Functions inherited from Astra.ApiJobWithResult< MaterialLoadJob.MaterialLoadResult, Loader.LoadError >
IEnumerator AsCoroutine (Action< float > progress=null, Action< T1 > onComplete=null, Action< T2 > onFailed=null)
 Wraps a job to be used within a coroutine More...
 

Protected Member Functions

void AsyncFetchMaterialTextures (int parentJobId=Job.kNoParentJobId)
 Fetches a list of textures from memory, disk, or net for the current MaterialLoadJob Triggers Thaw on the main job upon completion More...
 
void OnTextureFetchDone (Job job)
 Fired after all textures have been loaded into Unity Texture objects for the material More...
 
bool? Execute (Job job)
 

Detailed Description

Allows creation of materials from our PrimitiveMaterials

Member Function Documentation

◆ AsyncFetchMaterialTextures()

void Astra.Asset.MaterialLoadJob.AsyncFetchMaterialTextures ( int  parentJobId = Job.kNoParentJobId)
inlineprotected

Fetches a list of textures from memory, disk, or net for the current MaterialLoadJob Triggers Thaw on the main job upon completion

Parameters
parentJobId

◆ GetError()

override Loader.LoadError Astra.Asset.MaterialLoadJob.GetError ( )
inlinevirtual

When the job is complete this function can be called by the developer to access the error data set which can be of any type (defined as T2). This needs to be defined if your derived class as an override.

Returns
Yields the error result data

Implements Astra.ApiJobWithResult< MaterialLoadJob.MaterialLoadResult, Loader.LoadError >.

◆ GetResult()

override MaterialLoadResult Astra.Asset.MaterialLoadJob.GetResult ( )
inlinevirtual

When the job is complete this function can be called by the developer to access the result data set which can be of any type (defined as T1). This needs to be defined if your derived class as an override.

Returns
Yields the success result data

Implements Astra.ApiJobWithResult< MaterialLoadJob.MaterialLoadResult, Loader.LoadError >.

◆ OnTextureFetchDone()

void Astra.Asset.MaterialLoadJob.OnTextureFetchDone ( Job  job)
inlineprotected

Fired after all textures have been loaded into Unity Texture objects for the material

Parameters
job

The documentation for this class was generated from the following file: