Search Unity

Question Best practice for imported models in Unity for Mac OS

Discussion in 'Asset Importing & Exporting' started by dot_entity, Oct 14, 2022.

  1. dot_entity

    dot_entity

    Joined:
    Nov 2, 2012
    Posts:
    86
    Hello all, I have been intending to restart learning unity after many years of being inactive and I have some initial question. Although it might be basic, I have not managed to find specific information (by googling) and I am not even sure of how to even look for it.
    So the question: What might be the best practice in order to import 3d models created in other 3d software into unity for mac, in order to be able to update them in case of future editing, either in unity or in the other software.
    I found out that the FBX Exporter can do this job in Windows environment between 3ds Max or Maya and Unity. Although I use 3ds max in Windows (with bootcamp), I have installed Unity in the Mac os. I tried the FBX exporter and, as obviously expected, does not seem to serve the interoperability purpose, if both pieces of software are not installed in the same OS.
    Although I'd rather keep using Max for model building, I don't mind to try adopting another work- method/software within the Mac os only, if necessary. I know that there is Maya for Mac, but I had never tried it and, as far as I'm concerned, it is less suitable for my needs (architectural designs).
    I am not looking for a detailed answer or a full tutorial here, just someone to point me to the right direction or give me some workflow hints that offer similar advantages with FBX exporter in Windows. What would be the best practice if, let's say, my goal is to build the 3d models in Max, then import them into Unity, add there the materials, then in case I want for some reason to edit the geometry to do it back in Max and reimport(update) it in Unity?
    Maybe, after all, there is no real challenge and I only need to go back and forth from one software to the other like following: Exporting model in FBX format in 3ds Max, importing it in Unity and if I want to edit it export it with FBX Exporter (maybe this step is unnecessary) and import it in 3ds Max again (with any additions from unity this time) for further editing. When I finally reopen Unity will the model be updated with the last edits without breaking something? Despite I am not sure for any potential problems with the above process, I would moreover like to know a more efficient approach.
     
  2. bastien_humeau

    bastien_humeau

    Unity Technologies

    Joined:
    Jun 14, 2017
    Posts:
    191
    I'll start by saying that the workflow you'll use on your project is probably very different from what anyone else would do, because everyone has their own way to do things, and I'm sure there is an answer that would be better than anything else.

    Here's how I handle my projects regarding model imports:
    - My first rule is always to use FBX files. Using max, blend, ma or any other native DCC format is just asking for trouble. It's nice and useful when you prototype and want quick iterations locally, but once you start sharing your project you always end up in DCCs' version nightmare and random failed import because of that.
    - Never use the FBX file directly in a scene. Create a Prefab Variant first and use that in your project. This allows you to add new scripts or GameObject to the PrefabVariant, which will be merged properly with any subsequent changes made to the FBX file.
    - I personally never use the FBXExporter, but if you're doing a bunch of prototyping in Unity, and for example added a bunch of primitives to existing variants in your scenes that you'd like to edit in max later, then yes, use the Exporter to update your existing FBX file with the added objects, edit them in max, and replacing them in Unity once you're done should be seamless.
    - Regarding Material imports, I'm always trying to leave the default settings as much as possible. When I want to use custom shaders for optimization or specific rendering issues, then I'm writing AssetPostprocessors to change my settings based on the fbx data using the OnPostprocessMaterialDescription method, so that I can just forget that and have all my models working properly when I drop them in my project. The only moment I'm using the remap-material setting is when I want some very specific materials to be shared between multiple assets. Keep in mind that once you start using an external material, changes to the material properties in the fbx file don't update in Unity anymore...
     
    dot_entity likes this.
  3. dot_entity

    dot_entity

    Joined:
    Nov 2, 2012
    Posts:
    86
    Thank you bastien for taking the time reading my concerns and your wonderful comments!
    It's not really necessary that I will need this dynamic updating feature into my current project needs. Way back, I had been using Unity to build scenes "on the fly", trying to visualise text information on real-time demand from a database, which also had all sort of difficulties (for a beginner as myself) in comparison to a standard game project that most of the tutorials out there would talk about. But this fact does not help me anymore that I try another perspective, Now, I only want to build a static architectural scene with photorealistic lighting, so no extensive prototyping involvement or many-steps modification would be necessary (let alone complicated scripting), I guess. Nevertheless, I was curious for the available options and common directions of doing things, as I have lost track of the developments in the field, before I dive into this new approach.
    And your info points are extremely appreciated, and -I am sure- a good compass to keep in mind too, while I restart exploring and trying to get a grip of what I am missing. I will have a look on the OnPostprocessMaterialDescription method. Not sure if i got it even remotely right, but since I am now intending to build the materials only inside Unity with non-custom shaders, probably I will not need it for the time being. Thanks again!
     
    Last edited: Oct 18, 2022
    bastien_humeau likes this.