How to convert an OAR to DAE files

In this article I will show you how to convert an OAR to a collection of DAE files. We will be using a tool by Fumi.Iseki, Austin Tate, D.Mizumaki and K.Suzuki, you can read up on the tool on the Tokyo University of Information Science’s website. All credit goes to them for creating this convenient and powerful program. Accompanying the written descriptions there will also be screenshots detailing the steps.

How to setup/install the converter

The converter is available for Windows and Linux, I prefer using Linux and will explain how to install and use the tool on a Linux system. Don’t worry, the installation is not difficult at all, I will also explain how to get a Linux system in this guide.

How to install a Linux system on your PC

First of all we have to install a program, that can simulate a Linux system. I recommend using VMware, it is free and easy to use.

When you have VMware or a similar program installed you have to create a Linux system, I used Ubuntu 18.04.3 and used this .iso file to set the Ubuntu system up. The first start of the Ubuntu system may take a while.

Downloading the converter

When the Linux system is ready, go to your home folder and open the terminal. On Ubuntu you can open the terminal by right-clicking in the explorer and selecting “Open in Terminal”. You can then install the converter by typing the next two commands in the console and then hitting the enter key.

wget http://www.nsl.tuis.ac.jp/DownLoad/SoftWare/Linux/oarconv_bin-1.4.0.zip

unzip oarconv_bin-1.4.0.zip

The first command downloads a .zip folder that contains the converter and the second command extracts that very .zip file. Alternatively you can also manually download the .zip folder and then unzip the file using the command in terminal or manually.

The converter also needs another library, it can be installed with a simple command in the console, the command then requires you to input your password.

sudo apt-get install libjpeg62

Furthermore before we can execute the converter we have to create a symbolic link, the symbolic link ensures that the converter can find a library it needs for execution. The library is referenced under /usr/lib/libcrypto.so.10 by the converter but in the Ubuntu system as /lib/x86_64-linux-gnu/libcrypt.so.1. The link might be different or not needed if you use a different .iso file to install Linux.

To set this symbolic link up you just also have to enter the next command in the terminal you opened before.

sudo ln -s /lib/x86_64-linux-gnu/libcrypt.so.1 /usr/lib/libcrypto.so.10

Extracting an OAR file

Before we can run the converter we have to extract our OAR file and put all the content of the OAR file in one folder. Imagine we have an OAR called my_art.oar then we can create a folder called art_oar and extract the content to the folder with the following commands in a terminal.

mkdir art_oar

cd art_oar

tar zxfv ../my_art.oar

These commands move our terminal into the OAR folder, in our case art_oar, to step back out of the folder we can enter the next command or reopen a terminal in the parent folder.

cd ../

Converting an extracted OAR to DAE files

Finally we can use the program to convert the folder, in our example art_oar. To do so we enter the next command in the terminal. The first argument is the location of the oarconv.sh file, the last argument is the name/location of the folder that we want to convert.

./oarconv/oarconv.sh -i art_oar

Conclusion

The converter creates a folder called DAE where you executed the command, that folder contains everything in the original OAR converted to DAE files, textures and more. You should note, that there are a few particularities. The converter is not able to convert scripts from the OAR. Every object in the DAE folder has a suffix of 50 characters, this suffix is the ID of the original object in the OAR.

The next guide will explain how to import the DAE files to Unity and some experiences and issues I encountered.

Leave a Reply

Your email address will not be published. Required fields are marked *