public async System.Threading.Tasks.Task <ResourceInfo> CreateEmptyResource(string Absfolder, EditorCommon.Resources.IResourceCreateData createData) { await EngineNS.Thread.AsyncDummyClass.DummyFunc(); var result = new ShadingEnvResourceInfo(); var mcd = createData as ShadingEnvCreateData; if (EngineNS.CEngine.Instance.FileManager.GetFileExtension(mcd.ResourceName) != EngineNS.CEngineDesc.ShadingEnvExtension) { mcd.ResourceName = mcd.ResourceName + EngineNS.CEngineDesc.ShadingEnvExtension; } var ipWin = createData as InputWindow.InputWindow; var reName = EngineNS.CEngine.Instance.FileManager._GetRelativePathFromAbsPath(Absfolder + "/" + mcd.ResourceName, EngineNS.CEngine.Instance.FileManager.Content); result.ResourceName = RName.GetRName(reName); var senv = EngineNS.CEngine.Instance.ShadingEnvManager.NewGfxShadingEnv( typeof(EngineNS.Graphics.CGfxShadingEnv), RName.GetRName(reName), mcd.Shader); senv.SaveShadingEnv(); return(result); }
protected override async System.Threading.Tasks.Task <ResourceInfo> CreateResourceInfoFromResourceOverride(RName resourceName) { await EngineNS.Thread.AsyncDummyClass.DummyFunc(); var result = new ShadingEnvResourceInfo(); result.ResourceName = resourceName; return(result); }