![]() ![]() ![]() (wrapper remoting-invoke-with-check) System.IO.DirectoryInfo.Create() ![]() System.IO.Directory.CreateDirectory (System.String path) (at :0) System.IO.Directory.CreateDirectoriesInternal (System.String path) (at :0) Path: C:\Users\cdani\Unity-Projects\WWWF8-AfterHours\Assets\CluesC: IOException: Win32 IO returned ERROR_INVALID_NAME. Installed and attempted to drop-drag a zip with GLTF. But I think it's important to get KTX2 working properly again in Unity 2021.1.1f1 as soon as I can. I'm a bit swamped at the moment, so I'll have to experiment with more optimal solutions later. ![]() If it looks okay, I will go ahead and publish another Piglet release (1.2.2) in the next day or so. I'm currently doing some performance comparisons on PC and WebGL to make sure that your original two-request fix doesn't hurt the performance too badly. Unity provides the DownloadHandlerScript class to help people write custom download handlers, but I haven't tried it yet. (2) In cases where the image *is* coming from an HTTP(S) URL, I might be able to write a custom DownloadHandler for UnityWebRequest that only downloads the first few bytes to determine the image format. So I could have two versions of the ReadTextureEnum method - one for KTX2 and one for PNG/JPG. PNG/JPG) in upstream code, before the call to ReadTextureEnum even gets made. (1) In many (but not all) cases, it's possible to detect the image format (KTX2 vs. In future work, I have a couple of ideas for improving the performance of your two-request solution: Most of the time the "URI" that gets passed to ReadTextureEnum is a local temp file rather than an HTTP(S) URL, so the cost of "downloading" the file a second time isn't actually as bad as it looks. For example, I've seen LoadImage take as long as 200ms to load a large PNG image on my PC.Äownloading/reading the whole image file twice definitely isn't ideal, but I think it's probably the lesser of two evils in this case. So LoadImage works fine for edit-time glTF imports, but can cause unacceptable stalling of the main Unity thread during runtime glTF imports. Unfortunately, LoadImage completely blocks the main Unity thread while it's performing PNG/JPG compression, whereas UnityWebRequestTexture does PNG/JPG decompression on a background thread. UnityWebRequest followed by UnityWebRequestTexture). Thanks for your help, I think I prefer your original solution (i.e. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |