mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-03-21 18:05:03 -05:00
Applied same *AssetEditing improvements to the Texture extracting section of TextureExtractor.ExtractTextures() to batch the importing of created Textures.
This commit is contained in:
parent
dfe2c83a26
commit
2b4ecb5e73
|
|
@ -84,9 +84,22 @@ namespace UniGLTF
|
|||
s_MarkerStartExtractTextures.Begin();
|
||||
|
||||
var extractor = new TextureExtractor(data, textureDirectory, subAssets);
|
||||
foreach (var param in textureDescriptorGenerator.Get().GetEnumerable())
|
||||
try
|
||||
{
|
||||
extractor.Extract(param.SubAssetKey, param);
|
||||
AssetDatabase.StartAssetEditing();
|
||||
|
||||
foreach (var param in textureDescriptorGenerator.Get().GetEnumerable())
|
||||
{
|
||||
extractor.Extract(param.SubAssetKey, param);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Debug.LogException(e);
|
||||
}
|
||||
finally
|
||||
{
|
||||
AssetDatabase.StopAssetEditing();
|
||||
}
|
||||
|
||||
s_MarkerStartExtractTextures.End();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user