A user on the official Unity Discord recently mentioned he was having some difficulty importing Blender models into Unity using the built-in importer. Specifically, he was having issues with rotation and scaling. Some of the advice he was getting was to use the Blender FBX exporter; I had to wholeheartedly disagree (I’ll get into this later) and instead put together this quick step by step guide.
Here I’ve made a simple arrow model (pointing up), and a copy of it that’s scaled x0.5:
If you’re an existing Unity user who’s new to Blender you may notice something really odd about this: the entire thing is rotated! This is because:
If you don’t know this when you first start, you might try to match Unity’s coordinate system, treating the Y axis is as up, but if you do you’re going to have a bad time:
- Blender’s UI really wants to treat Z as up, and you’ll find subtle hints (the default starting orientation being the most obvious)
- Unity’s Blender importer handles this, so your model will end up being rotated upon import
The other thing I’ve done is delete the default camera and light that Blender creates. Unity recognizes these and will end up adding camera and light components accordingly. Most of the time, you won’t want this, as you’ll take care of cameras and lights directly in Unity.
Once your model is complete, simply import it into Unity as you would any other asset (copy to the Assets folder on the file system, or drag & drop directly into the project) and add it to your scene. Now here’s the key: you want to drag the root (parent) asset that Unity has created (
arrow, in my case), and not individual meshes (i.e.
I’ve included a 1 unit cube for reference (side note: ProBuilder is excellent for quickly creating simple meshes… highly recommended!)
So what happens if you try to use individual meshes directly? Let’s find out:
Yeah, that’s not right! Notice how the orientation, rotation and materials are all wrong. This is because the transform information–including the change of orientation–and materials are stored as part of the asset and are therefore lost if you try to use the mesh directly.
If you do need to use an individual mesh from your Blender model, I would recommend starting with the above, and then unpacking the prefab, with the caveat that some changes to your model will no longer be reflected.
- Respect Blender’s native right hand orientation
- Don’t try to use imported meshes directly (unless you’re okay with having to correct their orientation, scale and materials)
As simple as the Blender importer is to use, there are a couple things to watch out for:
- Unity Cloud Build does not support Blender models
- If your Blender model contains only a single mesh, your up/forward pivot orientation will be flipped
- Simple workaround: enable “Preserve hierarchy” in the importer settings
In closing, I’m huge fan of Unity’s Blender importer. I love being able to make quick edits to models without having to re-export/re-import. If one were to export to FBX every time, they would lose this flexibility, and it would add extra (and unnecessary) steps to their workflow.
If you’ve had problems with the Blender importer–or found a reason to favour exporting to FBX–I’d love to hear from you.