Search Unity

  1. Curious about what's going to be in 2020.1? Have a look at the 2020.1 beta blog post.
    Dismiss Notice
  2. Want to see 2020.1b in action? Sign up for our Beta 2020.1 Overview Webinar on April 20th for a live presentation from our evangelists and a Q&A session with guests from R&D.
    Dismiss Notice
  3. Interested in giving us feedback? Join our online research interviews on a broad range of topics and share your insights with us.
    Dismiss Notice
  4. New Unity Live Help updates. Check them out here!

    Dismiss Notice

New FBX Exporter in 2017.2

Discussion in 'External Tools Previews' started by ans_unity, Oct 12, 2017.

  1. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Ben,

    Yes it's planned :)
     
  2. Voodoo_ZA

    Voodoo_ZA

    Joined:
    Mar 18, 2013
    Posts:
    132
    Yes!!!! Thank You guys!!
     
    ans_unity and vkovec like this.
  3. olix4242

    olix4242

    Joined:
    Jul 21, 2013
    Posts:
    1,546
    I don't think that this could work. As it would require another texture sampling in a shader (and many more instructions). also, a problem is that I have to export few milions of vertices that make thousands of meshes - so, some pre processing would be required on exporting and importing. Not having free UV sets makes this mostly impossible to do that way.
     
  4. pojoih

    pojoih

    Joined:
    Mar 30, 2013
    Posts:
    181
    Are there any plans to export materials as stingray shader? Exporting already finished assets from Unity to Maya and switching the shaders from lambert/phong to stingray breaks all the texture connections which is a hassle.
     
  5. bblumberg

    bblumberg

    Joined:
    Apr 2, 2014
    Posts:
    2
    I am having a problem using the fbx exporter with 3js. The problem can be demonstrated by exporting a simple cube and then importing it into the threejs editor. The problem seems to be in the exported LayerElementColor. Threejs is expecting a Color property as well as the ColorIndex. Since the cube is all one color I can imagine that there is a flag that is set somewhere to handle this in the fbx file or in the exporter.

    If you can provide any assistance that would be great. Thanks!!!!

    LayerElementColor: 0 {
    Version: 101
    Name: "VertexColors"
    MappingInformationType: "ByPolygonVertex"
    ReferenceInformationType: "IndexToDirect"
    ColorIndex: *36 {
    a: 0,3,2,0,1,3,8,5,4,8,9,5,10,7,6,10,11,7,12,14,13,12,15,14,16,18,17,16,19,18,20,22,21,20,23,22
    }
    }
     
  6. RobertoM

    RobertoM

    Joined:
    Jan 28, 2015
    Posts:
    2
    Hi guys,

    Thanks for new great Unity functionality!
    Would be possible export any dynamically runtime generated mesh in coming future?
    It will be really useful.

    It currently throws error:
    dexOutOfRangeException: Array index is out of range.
    FbxExporters.Editor.ModelExporter+MeshInfo.get_Binormals ()
    FbxExporters.Editor.ModelExporter.ExportComponentAttributes (FbxExporters.Editor.MeshInfo mesh, Unity.FbxSdk.FbxMesh fbxMesh, System.Int32[] unmergedTriangles)
    ...

    Thanks!!
     
  7. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi pojoih,

    No plans at the moment.

    Best,
    Viktoria
     
  8. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi bblumberg,

    I tried to reproduce the issue and got the following error:
    Code (csharp):
    1.  
    2. TypeError: ColorNode.subNodes.Colors is undefined
    3.  
    Is this the error message you get?
    If not, or if you get any other errors, could you please send them?

    It does indeed seem to be a problem with the exported vertex colors.

    Best,
    Viktoria
     
  9. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi RobertoM,

    Glad you are enjoying the exporter :)

    Does your mesh have normals and tangents assigned to it?

    This error is usually caused by missing normals and/or tangents.
    In the next release export of meshes without normals or tangents will be supported.

    Best,
    Viktoria
     
  10. pojoih

    pojoih

    Joined:
    Mar 30, 2013
    Posts:
    181
    Feature request:
    Would be cool to export instances of meshes as well. Currently when importing a lot of the same meshes, Unity exports them as duplicates and breaks GPU instancing on reimport.
     
  11. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    Hi everyone,

    We're planning to release a new package to the forum this week. The new package will include added features like Maya LT one button import/export and camera export support, plus several improvements and bug fixes.

    However, the package may break links to the FbxPrefab component in assets created using the forum release (1.1.0b1). Here are more details about the problem and the fix we are shipping:

    • On updating to 1.2.0b1, links to the FbxPrefab component may be lost in previously created assets. In order to repair the missing links to FbxPrefab, the following steps can be taken depending on whether project assets are serialized as Text or Binary.
    • Before proceeding, it is recommended to make a backup of the project.
    • For Binary Assets: Switch the Asset Serialization mode in the Editor Settings (Edit->Project Settings->Editor) to “Force Text” to convert all project assets to text. Follow text asset steps below.
    • For Text Assets: The FBX export settings (Edit->Project Settings->Fbx Export), should contain a “Run Component Updater” button at the bottom of the settings. Clicking this button will repair all Text serialized prefab and scene assets in the project containing the FbxPrefab component.

    So again, only FbxPrefab component in assets created using the forum release (1.1.0b1) will be affected.

    Stay tuned!
     
    Last edited: Dec 14, 2017
    JakubSmaga and JJC1138 like this.
  12. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi pojoih,

    Instance export should already be supported. If I understood correctly, the issue is that if you import an fbx with instances into Unity, then export it, the instances are lost?

    If possible, could you please send me an example fbx with instances that is causing this problem?

    Best,
    Viktoria
     
  13. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    Hi everyone,

    The one button import/export is now available in Beta for MayaLT 2017 and up. You will now find the exact same simplified workflow that was available in the Maya version of the FBX Exporter. Also we have added camera export support. Have a try and let us know what you think!

    Several other improvements and bug fixes have been made to the package:

    NEW FEATURES
    • Added Maya LT one button import/export
    • Added camera export support
      • Export game camera as film camera, with filmback settings set to 35 mm TV Projection (0.816 x 0.612).
      • The camera aperture with always have a height of 0.612 inches, while the width will depend on the aspect of the Unity camera, as camera width = aspectRatio * height.
      • The projection type (perspective/orthogonal), aspect ratio, focal length, field of view, near plane, and far plane are also exported.
      • The last camera exported is set to the default camera in the FBX file.
      • NOTE: the field of view will show up as a different value in Maya. This is because Unity display's the vertical FOV, Maya displays the horizontal FOV.
      • NOTE: for GameObjects that have both a mesh and a camera component, only the mesh will be exported.
    • Export Settings: Added option to launch 3D application after installing integration
    • Export Settings: Added option to export FBX as ASCII or Binary

    FIXES
    • Fbx Exporter: Fix error when exporting meshes with missing normals, tangents, binormals, or vertex colors
    • Fbx Prefab Auto Update: Fix updating GameObjects with missing components
    • Fbx Exporter: Fix incorrect scaling on nested children when importing into Maya
    • Added script to fix FbxPrefab component links when updating from forum release (1.1.0b1)
      • A "Run Component Updater" button will appear in the FBX export settings inspector.
        Clicking the button will repair all prefabs and scene files serialized as text.
        To repair binary files, first convert asset serialization mode to "Force Text" in Editor Settings (Edit->Project Settings->Editor).

    KNOWN ISSUES
    • possible broken links to the FbxPrefab component in assets created using the forum release (1.1.0b1)
    • it is no longer possible to unload the Maya plugin using Maya's plugin manager.

    As mentioned yesterday, there's a known issue with possible broken links to the FbxPrefab component in assets created using the forum release (1.1.0b1). See my previous post for detailed information.

    Also it’s important to close and reopen Unity before installing the package into Unity in order to make sure that the native dll in the package is unloaded before updating.

    Next on our roadmap, are the lights FBX export support and updating the Asset Store FBX exporter with latest changes.

    You can download the package here.


    Note: The FBX Exporter is a “Restricted Asset” under the Asset Store End User License Agreement and is subject to the Unity Companion License 1.0. Further, use of the Autodesk FBX SDK is subject to your acceptance of and agreement to the FBX SDK License and Service Agreement terms.
     
    Last edited: Dec 15, 2017
    Archviz3d, vkovec and JJC1138 like this.
  14. JJC1138

    JJC1138

    Joined:
    Feb 23, 2012
    Posts:
    89
    This is extremely cool! Kudos to everyone who has worked on it!

    I presume more detailed docs are coming later, and I'd like to request that you include some guidance about workflow best practices. In particular, I'm interested in how best to handle materials and textures for the common case of using the Standard shader in Unity and an equivalent Stringray PBS material in Maya.

    I'm very new to Maya and I've just been playing for a little bit and a workflow that seems to work for making an object with a texture is:
    1) In Unity, use GameObject > 3D Object > Cube
    2) Create a dummy material, and assign it to the GameObject
    3) Put your texture in the Unity Assets folder, and set its import settings appropriately
    4) Set the texture as the Albedo map in the dummy material
    5) 'Convert to Linked Prefab Instance'
    6) In Maya, create a blank scene and use the File > Unity > Import menu item to import the newly-created FBX into it
    7) Select the object in Maya and in the Shading shelf select the 'PBS' icon to create a new Stringray material and assign it to the object
    8) In the Attribute Editor find that new material 'StringrayPBS1' and give it a more meaningful name if you like
    9) Enable the 'Use Color Map' option in the material
    10) In the Outliner disable the 'Show DAG Objects Only' option so that you can find the file reference to your texture, which is probably called "DiffuseColor_Texture" (you can rename it if you like)
    11) Middle-click drag that onto the 'Color Map' of the material
    12) File > Unity > Export
    13) Return to Unity and the GameObject should have reloaded and now be using the material that is internal to the FBX file, but still correctly linked to your texture
    14) You can delete the dummy Unity material that you created in step 2 because it's no longer needed

    Is there a simpler way than that?
     
    Archviz3d and vkovec like this.
  15. design89

    design89

    Joined:
    Dec 13, 2017
    Posts:
    3
    Hello guys

    from the comments and responses, I imagine the latest beta version of the fbx exporter is compatible with Windows 10.
    Is it also compatible with Windows 7?
     
  16. mikelo

    mikelo

    Joined:
    Feb 5, 2014
    Posts:
    34
    I've tried the last version 1.2.0b1 posted by @ans_unity in this forum. When I export a GameObject it renames the child objects, replacing non-alphanumeric characters with "_". The problem is it renames the objects in the hierarchy view. I find it ok if it renames objects in the target fbx, but it shouldn't modify the objects' name in the scene.

    EDIT: Ok. I found you can change it in the Fbx Export Settings under "Compatible Naming". But anyway, i think it shouldn't change names in the hierarchy.
     
    Last edited: Dec 20, 2017
  17. imgspc

    imgspc

    Unity Developer - FBX Exporter

    Joined:
    Aug 22, 2017
    Posts:
    13
    Hi Mikelo,

    We working a way to avoid having to change GameObject hierarchy names and still support the roundtrips. Until then we need the names in the GameObject hierarchy to be unique so that they will match to the FBX nodes. We also need the names to be valid for FBX so that the FBX importer in the 3d application doesn't rename the nodes on us.

    Simon
     
  18. imgspc

    imgspc

    Unity Developer - FBX Exporter

    Joined:
    Aug 22, 2017
    Posts:
    13
    Unity supports Windows 7 SP1 +, 8, 10, 64-bit versions only.
    The Fbx Importer Settings control how new materials are imported and how existing materials are remapped. In your example I can control which material the Cube uses as seen in this screenshot. I'm remapped the Maya DummyPBS to replace the Unity Dummy material that you defined in your first steps.

    If you don't use this control to handle the materials then the FBX Prefab Updater will match based on the material name. If, in Maya LT, I had named the Stringray shader "Dummy" and exported that then my original material would be replaced by the material in the FBX file, imported as a Standard (roughness setup).
     

    Attached Files:

    JJC1138 likes this.
  19. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    The latest version of the FBX exporter that we shared here in the forum is now officially available in the Unity Asset Store.
     
    vkovec and Archviz3d like this.
  20. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,067
    Cool! Is the Blender version still in the works?
     
  21. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    Yes it's still in the works but currently delayed in favor of improvements for the animation roundtrip. Keep in mind that the current FBX exporter is already working with Blender; what will be added is the one button import/export to make everything easier.
     
  22. tufeixp

    tufeixp

    Joined:
    Sep 6, 2015
    Posts:
    20
    any updates for the run-time importer / exporter version?
     
  23. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi tufeixp,

    We've received requests for this feature, however we don't have any updates at the moment.

    Best,
    Viktoria
     
  24. rad1c

    rad1c

    Joined:
    Feb 26, 2016
    Posts:
    21
    hi guys,

    I don't know if I'm a special snowflake but export messes up my materials big time.
    All I did was download & install the asset (about an hour ago [see post date]), select a (prefabbed) group of models, right click & "Export Model...", then reimported the fbx (to the very same project & a new one - same results).
    [Nothing else: no link to any 3d editing tool, nothing, just what I described above]

    Could you please advice? Or fix. Or both :)

    Attached a screenshot of the diffs for a better understand
     

    Attached Files:

  25. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi rad1c,

    Its possible that on import Unity is not finding the original materials and instead creating new ones based on the material and texture information available in the fbx file.
    If this is the case, first delete the incorrect materials created on import (if any), then try the following (depending on which version of Unity you are using):

    For Unity 2017.1, try changing the fbx import material settings to the following and reimporting:

    upload_2018-1-4_11-54-4.png

    For Unity 2017.2, try setting the remapped materials in the materials tab to link to
    the materials the model should use:

    upload_2018-1-4_11-54-25.png

    Alternatively you could also set the Material Location to legacy and follow the same procedure as for Unity 2017.1.

    upload_2018-1-4_11-54-34.png

    For Unity 2017.3, there is the additional option to use the "On Demand Remap" in the material import settings.
    Make sure the Naming and Search options are set as shown in the following image:

    upload_2018-1-4_11-55-5.png

    It also may help to have the materials located in a "Materials" folder at the same location as the
    fbx is exported to, if you didn't have this setup already.

    Let me know if this does not fix the problem or if you see any additional issues.

    Best,
    Viktoria
     
  26. rad1c

    rad1c

    Joined:
    Feb 26, 2016
    Posts:
    21
    hi Viktoria,

    Thank you for the help! The issue was sorted out by following the method you describe (for 2017.2, I use that version).

    What confused me was it seemed my materials were doubled and I had a 'wronged copy' in the fbx file (yet they weren't, fbx had the material names only - I checked this with a hex editor (EDIT: btw there seems to be exact Texture info -full path- in the fbx files but name only for Material files, which is strange, and possibly the source of the problem; both for full path -file system full path, not 'Assets' relative path- and name only)).

    It's a huge overhead I'll have to re-assign materials for everything after an export-import*, as Unity seems to always lose this connection (and I'll also have to sweep 'default materials' - again), however, this most probably is not an issue with your app.


    Thank you for your help again!
    Mark

    p.s.: I always store my Materials in the "Materials" folder, however, I have sub-folders in there which might lead to the issue. Probably the millionth Unity bug. I don't know...

    * == I do this to break connection with the original fbx file. I receive fbx files with all the stuff I need, I break them up the way I'll use them in my game and want to save & prefab & "export as unity package" them independently from each other, without carrying around the huge, original fbx file
     
    Last edited: Jan 4, 2018
  27. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    Hi,
    I'm a 3dsmax user. 2 questions.

    1) For me its' a bit curious to start with.
    + first have to create my model in 3dsmax
    + export by save as fbx-1 to unity
    + create an instance prefab-1
    + convert to linked fbx-2 and model-prefab-2 (created in root)
    + delete fbx-1 because of confusion to reference fbx-2
    + open 3ds, Unity-import fbx-2.
    Is this that way?

    2) What is a the goal of the fbx exporter of unity generally?
    In several cases I extend the instanced-prefab with scripts other meshes and components for sure. But this requires to update the model-prefab in the project. So is your goal to update the models prefab and instanced prefab correctly, if the referenced fbx-asset has changed?

    I think the biggest issue in the general prefab system is, materials/meshes/components can be changed on an instanced prefab on the original contents. It break the consistency of the prefab ideology and cause this quirky overall behavior.

    It's possible to change a instance prefab completely so the name only matches with the corresponding model prefab.

    + Anyway, I would prefer an additional 3dmax menu entry called "Unity > Export & Build Fbx/PrefabModel" to the selected folder of the project in unity for the first time. But not created an instanced prefab in hierarchy.
     
  28. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    For 3dsmax the security fix 2017.0.1 or 2017.1.1 is required. The "security fix" vulnerabilities related to improper memory allocation when opening FBX, DXF, DAE and 3DS malformed files.

    https://knowledge.autodesk.com/supp...1-and-2017-0-1-SECURITY-FIX/td-p/6770840.html

    In this case wrong exported fbx files from the unity side cause some crashes and data loss on 3dsmax.
    I think that worse a note on advertising the fbx system.
     
  29. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    Cannot get rid of the fbx linked to Visual Studio 2015.

    I tried to change the "linked behavior" from fbx -> Visual Studio to 3dsmax but does not work. I tried extMan to change the link but no way, seems like locked.

    Untitled-1.jpg

    Any idea how to solve?

    Edit 08.JAN.2018 : Found a solution to solve it by extMan and edit the file extension directly.
    Then opening works.


    Edit 08.JAN.2018 ; On enabling auto update and Fix 2017.2 was installed 3h later
    Untitled-3.jpg

    View attachment 261509

    Untitled-4.jpg

    :confused:
     

    Attached Files:

    Last edited: Jan 8, 2018
  30. rad1c

    rad1c

    Joined:
    Feb 26, 2016
    Posts:
    21
    I found an issue and this definitely is a defect in the exporter. Simple stuff go out smooth (materials are still an issue all the time but Viktoria's method works after all), however, a bit more complex meshes get ruined - consistently.

    See the attached image for a better understand (the original mesh on the left, the messed up one -exported then re-imported- on the right).

    Thanks for the fix in advance

    [ps if you need the fbx, let me know in an email, this is a live project and I cannot publicly share]


    EDIT: I found one of the reasons for a defective execution. If two or more GameObjects share the same name, even on different hierarchy branch, the exporter explodes and messes up things. (e.g. if I have a "ShelfLeft" and a "ShelfRight" GO, and both have a SUB GO named "Handle" -so even in a file system this would be legal-, the exporter blows up)
     

    Attached Files:

    Last edited: Jan 8, 2018
  31. Kubic75

    Kubic75

    Joined:
    Jan 2, 2017
    Posts:
    83
    Can´t we I have two or more selection sets in 3dsmax for splitting up a scene into multiple parts?

    Let´s say my scene in 3dsmax contains some houses and a groundobject.
    Until today I seperately exported all the houses to a "houses.fbx" and the ground to "ground.fbx".
    The big advantage is, that when I updated the groundobject only I don´t have to export the houses too.
    This way I save a lot of export/import time (especially if the houses are very detailed...).

    With your new exporter I have to put all houses + groundobject into the selection set and export the whole scene in one big part. The idea to save import/export time is gone.

    If 3dsmax would create multiple selectionsets based upon the name of the imported fbx, it could work again:
    Simply select the set you want to export before and voilà!
     
    Last edited: Jan 8, 2018
  32. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Quatum1000,

    1) I agree it's not ideal to have to export the fbx a second time to create a linked prefab. We need to add a workflow where you can easily create a linked prefab from an existing fbx.
    Until then, here are two alternative workflows:

    1.
    - Create model in 3dsMax
    - export fbx-1 to Unity
    - turn fbx-1 into a regular prefab-1 by adding it to the hierarchy then dragging it from the scene into the project view
    - attach FbxPrefab component to prefab-1 that was just created
    - set fbx-1 as the "source fbx asset" on FbxPrefab component

    2.
    - Create empty GameObject in Unity
    - Convert to linked prefab (creates prefab-1 and fbx-1)
    - import fbx-1 into 3dsMax, modify as necessary and export with Unity-Export

    2) Yes that's correct. The goal for the instanced-prefab is to be able to update the prefab in the scene when the referenced fbx changes, while maintaining any scripts/components that you already had on the prefab.

    Best,
    Viktoria
     
    Quatum1000 likes this.
  33. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Quatum1000,

    Are you still seeing fbx files exported from Unity causing crashes in 3dsmax?
    If so could you please send me the fbx files causing issues and/or related crash logs?

    Best,
    Viktoria
     
    Quatum1000 likes this.
  34. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Mark,

    Thank you for the feedback. Does changing the object names to be unique before export fix the exported model?
    Also, are the names unique in the fbx? The exporter should be setting the names to be unique when exporting.


    Could you please email me the original and exported fbx as well as any error messages?

    My email is: viktoria@imgspc.com

    Best,
    Viktoria
     
    Last edited: Jan 8, 2018
  35. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Kubic75,

    Thank you for the suggestion, we will work on improving this workflow.
    In the meantime here are a couple of alternative workflows:

    1.
    - run the following commands from the maxscript editor:
    Code (csharp):
    1.  
    2.     unityFbxFilePathAttr=undefined;
    3.     unityFbxFileNameAttr=undefined;
    4.  
    - Import house fbx using regular 3dsmax import (File->Import->Import...)*
    - Create set for house fbx contents (e.g. "HouseSet")
    - import ground fbx using regular 3dsmax import (File->Import->Import...)*
    - Create set for ground fbx contents (e.g. "GroundSet")
    - before exporting select a set ("HouseSet" or "GroundSet") to export from the set dropdown

    *if house and ground are not already present in scene

    2.
    - Import house fbx using Unity import
    - rename UnityFbxExportSet (e.g. to "HouseSet")
    - Import ground fbx using Unity import
    - rename UnityFbxExportSet (e.g. to "GroundSet")
    - run the following commands from the maxscript editor:
    Code (csharp):
    1.  
    2.     unityFbxFilePathAttr=undefined;
    3.     unityFbxFileNameAttr=undefined;
    4.  
    - before exporting select a set to export from the set dropdown

    One drawback (for both workflows) is that you will always get a popup asking you where to export, however it should always open into your Unity project.

    Best,
    Viktoria
     
  36. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    Nice idea! If that has no issues with the same material is shared over different SelectionSets I prefer as well.

    Perhaps on the first export (unityFbxFilePathAttr==null), you can set the 3dsmax-unity-exporter-script any argument to perform , <name.fbx> from - export fbx-1 to Unity (to) - set fbx-1 as the "source fbx asset" on FbxPrefab component.

    And in this case - for the project path in unity, perhaps define a GUILayout.Field in "FBX exporter/exporter settings", where to save the source fbx and model prefab on an undefined export reference to any fbx file.

    Sounds great, very useful!
    Vote Viktoria for best programming solutionist!
     
  37. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    Another issue: Seems the path to the readme.txt is fixed and not relative to the FbxExporter folder. To keep the hierarchy as small as possible, I move all add-ons into folder called _AddOns/, but this push a permanent warning on the readme file on mouse-move or editor messages.

    Untitled-1.png

    Further on my second pc system the unity integration does no appear on 3dsmax.
    Result -1073741819
    Any idea what this cause?

    Untitled-1.jpg

    Untitled-3.jpg

    Ran max: [C:/Program Files/Autodesk/3ds Max 2017/3dsmax.exe]
    With args [-q -silent -mxs "global UnityPluginScript_Source = @\"C:/Program Files/Autodesk/3ds Max 2017/Integrations/Autodesk/max/scripts/UnityFbxForMaxPlugin.ms\";global UnityPluginScript_Name = @\"UnityFbxForMaxPlugin.ms\";global UnityProject = @\"D:/Dropbox/Dropbox/DreamTech\";global UnityFbxExportSettings = @\"C:/Program Files/Autodesk/3ds Max 2017/Integrations/Autodesk/max/scripts/unityFbxExportSettings.ms\";filein \"C:/Program Files/Autodesk/3ds Max 2017/Integrations/Autodesk/max/scripts/configureUnityFbxForMax.ms\""]
    Result -1073741819
     

    Attached Files:

    Last edited: Jan 9, 2018
  38. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi Quatum1000,

    Yes that warning is definitely an issue, I'll add it as a bug. Currently the only solution would be to either not move the FbxExporter folder or move everything except for the readme. Otherwise it should be safe to ignore.

    I think the issue might be that the UnityFbxForMax.zip file is being unzipped into the 3ds Max installation directory (C:/Program Files/Autodesk/3ds Max 2017).
    Could you please try selecting a different path to unzip the file to when installing the integration?

    The steps to take are:
    1. Make sure 3ds Max is still selected as the desired 3D Application in the export settings
    upload_2018-1-9_14-3-0.png

    2. Click "Install Unity Integration"

    3. In the following folder browser popup select a writeable location outside the 3ds Max installation folder
    upload_2018-1-9_13-55-20.png

    You may also want to try moving the FbxExporters folder out of _AddOns/ and back into the Assets folder, in case it's causing this issue as well as the readme warning.

    Let me know if this doesn't fix the issue or if you get any other errors.

    Best,
    Viktoria
     
    Quatum1000 likes this.
  39. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    I got an exit error messgae, but it works!
    Untitled-1.jpg


    1) Open 3dsxmax and use Import works well so far. It seems a double click in unity on a fbx (to open) has a small issue.

    On a double click in unity on any fbx, the UnityFbxExportSet is not visible or inexistent in 3dsmax. Creating a new UnityFbxExportSetshows all included objects directly inside the new UnityFbxExportSet.

    2) Each double click on a fbx creates an new instance of 3dsmax. But 3dsmax generally is not stable on multiple instances. Is there any chance to have an option to prevent multiple instances in the fbx exporter settings?
     
    Last edited: Jan 18, 2018
  40. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    Hi fellow Unity users,

    We have published a revised series of videos showing the best practices when importing 3D art into Unity. To view the videos in the context of the Unity Tutorials, just follow the link.
     
    Last edited: Jan 11, 2018
    vkovec and JJC1138 like this.
  41. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Thank you for the suggestion, it's a good idea and I've logged it :). It may require starting Unity from 3ds Max in order to setup the prefab.

    Best,
    Viktoria
     
    Quatum1000 likes this.
  42. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Glad it works! Will add a bug and look into that error message though.

    The Unity integration plugins do not support double clicking on an fbx to import it into 3ds Max or other 3D applications. Double clicking will run the application set through the operating system for that file type, but won't run the Unity fbx importer.

    In order to import the fbx using the Unity importer in 3ds Max, first open 3ds Max then run Unity->Import (for Max 2017) or File->Import->Import from Unity (for Max 2018).

    Best,
    Viktoria
     
    Last edited: Jan 11, 2018
    Quatum1000 likes this.
  43. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    We have a new installation video (Maya) to simplify the process for first time users here.
     
    Last edited: Jan 23, 2018
  44. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    Another option would required be to prevent importing .max or other 3ds files, ideally by an toggle list.

    I save all my max files into the unity project folder. These folders are shared by dropbox and other members over the unity developer network also. Now unity tries to import the max files into a prefab. 1)This takes a lot of time, 2) It stops working with the editor. 3) It's not necessary. Because these max files include originals, test models, and stuff is not used in the scene.

    1) Would it generally possible to prevent automatic import of any file formats/extensions?
    2) If files are not used but inside the project, does unity pack them into the build anyway?
     
  45. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    I'm not sure to understand fully, do you mean that you save your Max files without using the FBX Exporter?

    In regards to your two other points:
    1) Not to my knowledge unless you use custom scripts (scriptedImporter).
    2) Not if there are no reference to them. The only exception is the Ressources folder where EVERY recognizable file will be packaged even if not referred.
     
  46. ans_unity

    ans_unity

    Unity Technologies

    Joined:
    Oct 12, 2017
    Posts:
    106
    It's also good practice to create a specific folder for your DCC files and not put them in the Unity project folder as is.
     
  47. indieDoroid

    indieDoroid

    Joined:
    Jan 25, 2016
    Posts:
    250
    Noob question here.. but the materials I'm using in 3dsmax are not being imported.

    I'm not sure if I'm using the correct workflow, but here it is:

    1) [ UNITY ] create a placeholder cube -> add a placeholder material
    2) [ UNITY ] right click "convert to linked prefab instance". FBX expoter does its own calculation stuff
    3) [ 3DSMAX ] "import from UNity", the FBX file that UNity created
    4) [ 3DSMAX ] "add selected objects" the 3dsmax mesh (with it's own material) into the "UnityFbxExportSet" selection set.
    5) [ 3DSMAX ] "export to UNity"
    6) [ UNITY ] Unity automaticlaly updates. The new mesh is there, but NOT the correct scale (it's smaller) and the materials from 3dsmax are not applied.

    Any help?

    Thanks
     
  48. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    The place holder material in unity requires a texture to be recognized in 3dsmax?

    Seems to be the right workflow. Important is System Unit Setup to cm, not Units Setup!

    Untitled-1.jpg

    The scale issue mostly depends on starting max without a default scene. For me it's important to save empty max file with the correct setting as MaxStart.max and save it into the Config User Path / scenes. Max now start with correct setup, windows positions, grid sizes, etc.

    Untitled-2.jpg
    In my case it's C:\Users\a\Documents\3dsMax\scenes\

    https://forums.autodesk.com/t5/3ds-...-to-reset-to-custom-maxstart-max/td-p/6042373

    Untitled-3.gif
     
    Last edited: Jan 18, 2018
    vkovec likes this.
  49. Quatum1000

    Quatum1000

    Joined:
    Oct 5, 2014
    Posts:
    784
    @vkovec

    Is there any reason why a new material is created in max, will be created as new Material with a name as the diffuse texture? This is a bit ugly. Is there a way to export the standard material name.. as new material.name in unity.. and not from any texture.name is added?

    And it would be really use and help to have a new exporter version that makes it possible to "convert a lined prefab asset" in to a specified project folder!
     
    Last edited: Jan 18, 2018
  50. vkovec

    vkovec

    Unity Developer - FBX Exporter

    Joined:
    Aug 9, 2017
    Posts:
    178
    Hi indieDoroid,

    Your workflow is correct. In 3ds Max are you using the default material or did you assign a custom material to the object you are exporting?
    I'm not sure if it's possible to export the default material (the one that is given to an object when created) in 3ds Max, but creating and assigning a custom material should work.

    To create and assign a material, open the Slate Material Editor in 3ds Max, then follow the instructions found here for creating a material.

    If you had already created a material and it didn't export, what type of material were you using, and did it have a texture?
    If possible, could you please send me the 3ds Max file with the object and material that failed to export?

    As for the scaling, as Quatum1000 mentioned, it is recommended to have your system units in cm in Max.
    However, it should still work properly as long as the system units on export are the same as the units on import.

    Is it only the new mesh that is the wrong scale or the original as well?

    Best,
    Viktoria
     
unityunity