Closed toto5100 closed 8 years ago
Can you please attach the obj file? This looks like it got the wrong format. Which tool did you use to export it?
I tried Cinema 4D to export and also Blender, but even with your hair obj example included, i have the same message. Cube_Hair 1.zip
The file looks okay, did you move the TressFX folder? It looks like tressfx cannot find the assetconverter.exe (Which is located in Assets/TressFX/assetconverter.exe, https://github.com/kennux/TressFXUnity/blob/master/Assets/TressFX/assetconverter.exe).
You can edit the path where tressfx should look for it: Edit -> Preferences -> TressFX -> Asset converter path
Check if this path is correct.
Now it works with the example file, but not with files created with C4D. What type of object should be the hair in the obj (mesh, spline...) ?
It must be spline data, the importer looks for a sequence of line segments.
Is the issue solved?
Sorry for the late response. Yes, it's pretty much solved, as i found that C4D hair, even when converted does not work with TressFX, the only way is using Blender.
Alright, more data importers will follow in the future.
Hello, When i try to import an obj file to TressFX (as described here) i have this error, and the hair file created is empty :
ArgumentException: D:/Projets/TressFXUnity-master/Assets/ is a directory System.IO.File.Copy (System.String sourceFileName, System.String destFileName, Boolean overwrite) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.IO/File.cs:109) System.IO.File.Copy (System.String sourceFileName, System.String destFileName) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.IO/File.cs:86) TressFXLib.Hair.PrepareSimulationParamatersAssetConverter (Int32 followHairs, Single maxRadiusAround, System.String assetConverterExePath) (at Assets/TressFX/TressFXLib/Hair.cs:463) TressFX.TressFXHairEditorExt.CreateAssetOBJ () (at Assets/TressFX/EditorExtension/Editor/TressFXHairEditorExt.cs:212)
NullReferenceException: Object reference not set to an instance of an object TressFX.TressFXHairEditor.OnInspectorGUI () (at Assets/TressFX/EditorExtension/Editor/TressFXHairEditor.cs:27) UnityEditor.InspectorWindow.DrawEditor (UnityEditor.Editor editor, Int32 editorIndex, Boolean rebuildOptimizedGUIBlock, System.Boolean& showImportedObjectBarNext, UnityEngine.Rect& importedObjectBarRect) (at C:/buildslave/unity/build/Editor/Mono/Inspector/InspectorWindow.cs:1231) UnityEditor.DockArea:OnGUI()
I tried to run Unity in Administrator mode, but with the same result.