Introduction
This article explains how to convert motion data (fbx files) that can be downloaded from Mixamo, a service that provides 3D characters animations provided by Adobe for free, into motions for MMD (vmd files). However, the main focus is on the method Yuuki Sato, the author of this article, uses for conversion and how to use the converter used in that process. So please understand in advance that it is not a commentary on programming or software development.
The original code of the converter mentioned in this article and commentary was used from the commentary article below. I would like to take this opportunity to thank you again.
[URL] : https://kaerudokoro.netlify.app/blender/vmd_exporter/
Things to prepare in advance
In order to perform the data format conversion method explained in this article, the following preparations must be completed in advance.
- Mixamo account registration
- Blender installation
- Blender add-on mmd_tools installation
If we also explain the above three steps, the volume of this commentary article will be excessively large, so we will leave these to another article that has been uploaded on the Internet.
For the time being, the method of implementing the third mmd_tools is written in the technical manual uploaded to BOOTH, so I will introduce it as an advertisement.
[URL] : https://tar.booth.pm/items/1948585
Motion download from Mixamo
- First, download the motion data you want to use from Mixamo.
- Here, download with the settings as shown in the figure below.
Convert fbx file downloaded with Blender to bvh file
Start up a new Blender and import fbx file downloaded from Mixamo into Blender.
Select the imported data (armature), this time in
bvh format. This allows the bones that were perpendicular to the arm and leg elements in the fbx file to be parallel.
Delete redundant strings in the bvh file
Open the exported bvh file as a txt file (Notepad) and use the replace function to delete the string "mixamorig:" all at once.
This is because the character string "mixamorig:" is attached to the beginning of all bone names, but if the character string is too long when converting to vmd using mmd_tools in the later process, it will be stored as vmd. because you won't be able to. Therefore, it is necessary to remove redundant strings.
After deleting the "mixamorig:" string, save the data and close Notepad.
Convert the bvh file into vmd data (data before processing)
Next, import the bvh data with redundant strings removed into Blender. If you import at 1x, a huge size bone will appear, but there is no problem.
Select the bone of the imported bvh data and export it as a vmd file using "Export" from "File" (You need to install the mmd_tools add-on in advance)
It is still in vmd file format at this stage. However, the names of the bones are still in English, and the IK bones around the legs and center bones, which are semi-standard bones used in most MMD character models, are not supported.
- That's a problem, so in the next step, we'll use a converter for MMD motion so that it can be applied to the Japanese name bones of the MMD model.
How to use the converter
The bone name converter is a Blender file, so if you have Blender installed you should be able to open it without problems.
Open the file "mmd_Converter.blend" in the file distributed by Booth. This will be the converter to the Japanese name bone.
Select the "000_Origin" armature from the outliner of the bone name converter, and import the vmd file with the English bone name for that armature.
As a result, the armature "a_01_00_RigBase", which has the Japanese name bone for MMD, moves in conjunction with the English name "000_Origin" (it is made to be so)
In this state, the Japanese name bone Select the "a_01_00_RigBase" armature and click the play button in the "Text Editor" to export as a motion corresponding to the Japanese name MMD bone.
The destination where the vmd file after conversion is exported is set to the place written in the lower right area. If you want to set the export destination to an arbitrary location, rewrite the absolute path before conversion.
Finally
This is the end of the explanation of the conversion method I use. The explanation has become a lot of steps to be done, but the current situation is that I cannot expect any further simplification with my technical skills.
It is not prohibited to establish a new method based on this commentary, or to explain, distribute, or sell it. Rather, I'm going to put the pen down today, hoping that someone reading this article will come up with a more sophisticated method.