Reign.Video.Abstraction.Model.Model C# (CSharp) Method

Model() public method

public Model ( IDisposableResource parent, SoftwareModel softwareModel, bool loadColors, bool loadUVs, bool loadNormals, string contentDirectory, Type>.Dictionary materialTypes, List value1BinderTypes, List value2BinderTypes, List value3BinderTypes, List value4BinderTypes, List textureBinderTypes, string>.Dictionary fileExtOverrides, int classicInstanceCount, Loader loadedCallback ) : Reign.Core
parent IDisposableResource
softwareModel SoftwareModel
loadColors bool
loadUVs bool
loadNormals bool
contentDirectory string
materialTypes Type>.Dictionary
value1BinderTypes List
value2BinderTypes List
value3BinderTypes List
value4BinderTypes List
textureBinderTypes List
fileExtOverrides string>.Dictionary
classicInstanceCount int
loadedCallback Reign.Core.Loader
return Reign.Core
		public Model(IDisposableResource parent, SoftwareModel softwareModel, bool loadColors, bool loadUVs, bool loadNormals, string contentDirectory, Dictionary<string,Type> materialTypes, List<MaterialFieldBinder> value1BinderTypes, List<MaterialFieldBinder> value2BinderTypes, List<MaterialFieldBinder> value3BinderTypes, List<MaterialFieldBinder> value4BinderTypes, List<MaterialFieldBinder> textureBinderTypes, Dictionary<string,string> fileExtOverrides, int classicInstanceCount, Loader.LoadedCallbackMethod loadedCallback)
		: base(parent)
		{
			Loader.AddLoadable(this);
			new LoadWaiter(new ILoadable[]{softwareModel},
			delegate(object sender, bool succeeeded)
			{
				if (succeeeded)
				{
					using (var stream = new MemoryStream())
					{
						try
						{
							Model.Save(stream, false, softwareModel, loadColors, loadUVs, loadNormals);
							stream.Position = 0;
						}
						catch (Exception e)
						{
							FailedToLoad = true;
							Dispose();
							if (loadedCallback != null) loadedCallback(this, false);
						}

						if (!FailedToLoad) init(null, stream, contentDirectory, materialTypes, value1BinderTypes, value2BinderTypes, value3BinderTypes, value4BinderTypes, textureBinderTypes, fileExtOverrides, classicInstanceCount, loadedCallback);
					}
				}
				else
				{
					FailedToLoad = true;
					Dispose();
					if (loadedCallback != null) loadedCallback(this, false);
				}
			});
		}

Same methods

Model::Model ( IDisposableResource parent, string filename, string contentDirectory, Type>.Dictionary materialTypes, List value1BinderTypes, List value2BinderTypes, List value3BinderTypes, List value4BinderTypes, List textureBinderTypes, string>.Dictionary fileExtOverrides, int classicInstanceCount, Loader loadedCallback ) : Reign.Core