public void PrepareExport(IAssetExportEnvironment env) { // We can export any Resource that is a shader if (env.Input is AbstractShader) { // Add the file path of the exported output we'll produce. if (env.Input is FragmentShader) env.AddOutputPath(env.Input.Name + SourceFileExtFragment); else env.AddOutputPath(env.Input.Name + SourceFileExtVertex); } }
public void PrepareExport(IAssetExportEnvironment env) { // We can export any Resource that is a shader if (env.Input is AbstractShader) { // Add the file path of the exported output we'll produce. if (env.Input is FragmentShader) { env.AddOutputPath(env.Input.Name + SourceFileExtFragment); } else { env.AddOutputPath(env.Input.Name + SourceFileExtVertex); } } }
public void PrepareExport(IAssetExportEnvironment env) { if (env.Input is PythonScript) { env.AddOutputPath(env.Input.Name + SourceFileExtPrimary); } }
public void Export(IAssetExportEnvironment env) { PythonScript input = env.Input as PythonScript; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); SaveScriptData(input.Content, outputPath); }
void IAssetImporter.Export(IAssetExportEnvironment env) { T resource = env.Input as T; string outputPath = env.AddOutputPath(this.GetOutputNameFromResource(resource)); this.ExportResource(resource, outputPath, env); }
public void Export(IAssetExportEnvironment env) { // Determine input and output path CsvData input = env.Input as CsvData; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); BaseAssetImporter.Export(input, outputPath); }
public void Export(IAssetExportEnvironment env) { // Determine input and output path AudioData input = env.Input as AudioData; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); // Take the input Resource's audio data and save it at the specified location File.WriteAllBytes(outputPath, input.OggVorbisData); }
public void Export(IAssetExportEnvironment env) { // Determine input and output path Font input = env.Input as Font; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); // Take the input Resource's TrueType font data and save it at the specified location File.WriteAllBytes(outputPath, input.EmbeddedTrueTypeFont); }
void IAssetImporter.PrepareExport(IAssetExportEnvironment env) { T resource = env.Input as T; if (resource != null && this.CanExport(resource)) { env.AddOutputPath(this.GetOutputNameFromResource(resource)); } }
public void Export(IAssetExportEnvironment env) { // Determine input and output path Pixmap input = env.Input as Pixmap; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); // Take the input Resource's pixel data and save it at the specified location this.SavePixelData(input.MainLayer, outputPath); }
public void PrepareExport(IAssetExportEnvironment env) { // We can export any Resource that is a Pixmap if (env.Input is Pixmap) { // Add the file path of the exported output we'll produce. env.AddOutputPath(env.Input.Name + SourceFileExtPrimary); } }
public void Export(IAssetExportEnvironment env) { // Determine input and output path JsonData input = env.Input as JsonData; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); // Take the input Resource's pixel data and save it at the specified location BaseAssetImporter.Export(input, outputPath); }
public void Export(IAssetExportEnvironment env) { // Determine input and output path AbstractShader input = env.Input as AbstractShader; string outputPath; if (env.Input is FragmentShader) { outputPath = env.AddOutputPath(input.Name + SourceFileExtFragment); } else { outputPath = env.AddOutputPath(input.Name + SourceFileExtVertex); } // Take the input Resource's TrueType font data and save it at the specified location File.WriteAllText(outputPath, input.Source); }
public void PrepareExport(IAssetExportEnvironment env) { // We can export any Resource that is a Font with an embedded TrueType face Font input = env.Input as Font; if (input != null && input.EmbeddedTrueTypeFont != null) { // Add the file path of the exported output we'll produce. env.AddOutputPath(env.Input.Name + SourceFileExtPrimary); } }
public void Export(IAssetExportEnvironment env) { // Determine input and output path AudioData input = env.Input as AudioData; string outputPath = env.AddOutputPath(input.Name + SourceFileExtPrimary); WAVExporter.SaveVorbisDataToWAV(input.OggVorbisData, outputPath); }
public void Export(IAssetExportEnvironment env) { // Determine input and output path AbstractShader input = env.Input as AbstractShader; string outputPath; if (env.Input is FragmentShader) outputPath = env.AddOutputPath(input.Name + SourceFileExtFragment); else outputPath = env.AddOutputPath(input.Name + SourceFileExtVertex); // Take the input Resource's TrueType font data and save it at the specified location File.WriteAllText(outputPath, input.Source); }