In my opinion, .obj is the best approach for exporting Vectorworks models for VR experiences in Unity. This .obj process has more steps than importing into Unity as .fbx, but it makes up for it in optimization. These .obj files are easier for Unity to work with and, if done right, make it easier for you to edit materials within Unity.
Read on to learn how to set yourself up for organizational and performance success in Unity, starting with prepping your Vectorworks file correctly. It’s all about organizing your objects into material-based classes and converting them into optimized mesh objects. The final product is a collection of .obj objects for easy import and management in Unity.
Save as File
Start by saving out a separate copy of the Vectorworks file you intend to export for Unity. We will be making some substantial changes that would make a mess out of any sheet layer viewports and class assignments.
I recently discovered that the scale of your model when it exports as .obj doesn’t matter. It all imports into Unity at the same size, no matter what scale it was in Vectorworks.
Orient on Internal Origin
It is ideal to have your .obj objects import in the center of your Unity scene. To achieve this, adjust your Vectorworks model to be on the Internal Origin before exporting. Be sure all classes and layers are set to visible. It is easiest to turn on Show/Snap/Modify others in Layer Options and then Select All to move.
Or Main Nav> Tools> Origin> Center Drawing on Internal Origin, but you will likely still need to manually adjust for a perfect center placement. Yet another option is to skip moving your model onto the internal origin at all and instead manually designate a new origin using Tools> Origin> User Origin.
I like to organize my Vectorworks model into material-based classes in order to import efficiently into Unity & optimize for better performance. The intention is to export each of these material-based classes as individual .obj files.
Figure out all the different materials in your model, and create class names for each of these material-defined objects. Reassign all the objects in our scene to our new material-based classes and purge the rest. And if you experience any frustration with some of the pre-made Vectorworks Spotlight symbols, (like monitors, pipe & drape, risers, and doors) check out this post on Re-assigning Classes of Tricky Spotlight Objects.
Get rid of any 3D lights and camera objects. We will handle those in Unity.
Convert to Mesh & Generic Solids
Once every object in your scene has been assigned a material-based class, convert the entire class into a single optimized mesh object. With all objects in the active class selected, navigate to Modify> Convert to Mesh.
Then, with the objects still selected, go back to Modify and Convert to Generic Solids. Go down the list and do the same thing for every object, Convert to Mesh> Convert to Generic Solids.
There is one exception to the Convert to Mesh rule: skip over any objects that have a renderworks texture image applied, as in our LED screen seen in the video. So for example, if I were to convert the led screen to a mesh, our texture mapped image data is completely gone. So in this case, bypass the convert to mesh and instead go straight to convert to generic solids. Note you may have to remap the image after converting.
Another SNAFU with textures is that Vectorworks .obj exports any image files at super low resolution. To solve this, you can export as CINEMA 4D with ‘Materials and Texture Tags” checked to obtain a tex folder containing your full-resolution texture image files. After importing your .obj models, you’ll have to manually replace the low res .obj textures in your Unity Assets folder.
Export as .obj
Finally, export each class as a combined .obj file. With only the active class visible, go to File> Export> Export OBJ. Repeat for all the remaining material-based classes. Make sure ‘Apply Double Side Faces” is unchecked or else you may get some flickering on image textures.
Now your ready to start building your VR scene in Unity! Learn how to use the Oculus Integration Package to quickly create your first project in Unity for Oculus Quest. Or, you can go the even easier route using the new XR Toolkit!