private static Link.Visual.Material.Texture ExportTextureData(Texture texture) { string oldTexturePath = UrdfAssetPathHandler.GetFullAssetPath(RuntimeUrdf.AssetDatabase_GetAssetPath(texture)); string newTexturePath = UrdfExportPathHandler.GetNewResourcePath(Path.GetFileName(oldTexturePath)); if (oldTexturePath != newTexturePath) { File.Copy(oldTexturePath, newTexturePath, true); } string packagePath = UrdfExportPathHandler.GetPackagePathForResource(newTexturePath); return(new Link.Visual.Material.Texture(packagePath)); }