C# Class KEngine.MaterialLoader

加载材质,通过CSerializeMaterial
Inheritance: AbstractResourceLoader
Datei anzeigen Open project: mr-kelly/KEngine

Public Methods

Method Description
Load ( string path, CCMaterialLoaderDelegate callback = null ) : MaterialLoader

Protected Methods

Method Description
DoDispose ( ) : void
Init ( string url ) : void
OnFinish ( object resultObj ) : void

Private Methods

Method Description
CoGenerateMaterial ( string matPath, KSerializeMaterial sMat ) : IEnumerator
CoLoadSerializeMaterial ( ) : IEnumerator
ParseMaterialStr ( string materialTextureStr, Vector2 &tiling, Vector2 &offset ) : string
_SetMatColor ( Material mat, string colorPropName, string _colorStr ) : void
_SetMatRange ( Material mat, string propName, string propValue ) : void
_SetMatTex ( Material mat, string matPropName, Texture tex, Vector2 tiling, Vector2 offset ) : void
_SetMatVector ( Material mat, string propName, string propValue ) : void

Method Details

DoDispose() protected method

protected DoDispose ( ) : void
return void

Init() protected method

protected Init ( string url ) : void
url string
return void

Load() public static method

public static Load ( string path, CCMaterialLoaderDelegate callback = null ) : MaterialLoader
path string
callback CCMaterialLoaderDelegate
return MaterialLoader

OnFinish() protected method

protected OnFinish ( object resultObj ) : void
resultObj object
return void