#author("2023-12-21T01:30:49+00:00","default:admin","admin") #author("2023-12-21T01:32:27+00:00","default:admin","admin") *Convert VRM to FBX and Import to Bakin [#d7de0b61] Bakin's supported format for 3D assets is FBX. Therefore, .vrm format files, which are often used for 3D character models, need to be converted to .fbx before importing them into Bakin. There are several methods of conversion, but here we will explain how to create a simple VRM model with "2" materials using "Vroid Studio" and convert it to .fbx using "Blender". Vroid Studio Steam: https://store.steampowered.com/app/1486350/VRoid_Studio_v1260/ Blender Steam: https://store.steampowered.com/app/365670/Blender/ At the same time, we will explain how to apply Mixamo's character motions. Mixamo URL: https://www.mixamo.com/ "Vroid Studio" and "Blender", which appear in the following explanation, can be obtained from Steam and other sources. "Mixamo" is a web service. For details of each application, please refer to the respective references. #Contents **Steps to Import VRoid -> Blender -> Mixamo -> Bakin (Case with "2" Number of Materials) [#o857098b] ***Creating a Folder to Store Data [#q4044217] First, create a folder somewhere to store the data you are about to create. It will be easier to identify the model if it is the name you are thinking of giving to the model, for example. We refer to this folder as the "Model Folder". ***Creating a VRM File [#lc4db3a6] +First, create a model using "Vroid Studio". Please refer to the "Vroid Studio" reference for details on how to do this. #br +Select "VRM Export". #br +Set the number of materials to "2" in Material Reduction. Assign a texture atlas resolution. ''(!) Placing multiple models with large texture sizes on a Bakin map will affect the processing speed of the editor.'' Please determine the size you need for your project. #br +Export by pressing the Export button. Either version of VRM is acceptable. The other settings are not necessary when converted to FBX. #br +Save it in the "Model Folder". ***Conversion to .fbx [#t0323865] The following images are for "Blender" 4.0, but the process is the same for other versions. +Please install an add-on that imports .vrm into "Blender". There are various add-ons, such as "VRM IMPORTER," so please choose the one that best suits your needs. Please refer to the "Blender" reference for information on how to install add-ons. #br +Select File > Import > VRM. Select the .vrm you wish to import in the file view. When doing so, check the "Extract texture images into the folder" checkbox. #br #ref(./BlenderVRMimport_1.png,60%) #br +After importing, delete unnecessary objects. Please note that there may be hidden objects. The red box in the image is an example of objects to be deleted. #br #ref(./BlenderVRMimport_2.png,60%) #br +Select File > Export > FBX. Export to the "Model Folder" with the following settings: -- ''Include > Object Types'': Select Empty, Armature, or Mesh (Shift+click for multiple selections) -- ''Transform'': Scale 0.01, Check "Apply Unit" and "Use Space Transform" -- ''Geometry'': Check "Tangent Space" only; uncheck "Apply Modifiers". -- Otherwise, the default settings are acceptable. #br #ref(./BlenderVRMimport_3.png,60%) #br ***Add Motions [#xd371151] +Motions are added using "Mixamo". Please register and log in to "Mixamo". #br +Press the Upload Character button and drag and drop the FBX you just exported. #br +Once uploaded, an untextured model of the character will be displayed, so press Next to continue. #br +Select the motion you like, apply detailed settings in the parameters on the right, and then press the Download button. The settings for this are as follows: Format (FBX Binary), Skin (Without Skin), Frames per Second (60), Keyfram Reduction (None) #br +In the "Model Folder," create a folder called "motions" and move the FBXs you just downloaded. ***Import to Bakin [#f7f5dc8c] ''*Important*'' Here we describe how to do the import using the attached def file. This is because the def file allows for the linking of textures to materials and basic settings. The attached def file is only supported when exported with "Vroid Studio" with the number of materials "2". However, it is possible to link textures to materials in Bakin's Resources menu without using a def file. - ''Preparation before Importing'' +Specify the attached material settings file (VRM_MaterialSettings.def) for VRM with the same name as the FBX (###.def) and put it in the "Model Folder". The link to download the def file is at the bottom of this page. #br -''Importing Models into Bakin'' +Go to Resources > 3D Stamps > Add > Local File tab, select the FBX of the model file and add it. The "Material Sharing" dialog will appear when the second or later model is imported into the project and added. Select "Add All as New Materials". #br +If you continue to import other VRM models, you may want to put the textures together in a folder under Resources > Textures. This is to make it easier to distinguish between the textures, since the names of the textures are the same for each VRM. #br A textured 3D stamp with the toon shader specified for materials will now be generated. If you want to adjust the toon shader, see [[Shaders]]. The following is the process of linking motions created by "Mixamo" to the 3D stamp. -''Importing Motions into Bakin'' +Return to Resources > 3D Stamps and click on Motion Setting > Motion in Properties. #br +Click on the Resources tab, select and add the model for that stamp. #br +Go to Resources > Motions and select the model you just chose. #br +Delete T-pose motion that is in Motion Sets Settings > Motions. #br +Press the Add Motion button to open the Local File tab and add the FBX downloaded from Mixamo. FBXs for imported motion will be added to Resources > Models, so it will be easier to organize them later by separating them into folders. #br +Change the "Motion Name" of the added motion according to the [[Motion Name Rules:https://rpgbakin.com/pukiwiki_en/?Motion+Name+Rules]] This allows for the automatic assignment of assigned motions to movements such as walking, running, attacking, etc. #br At this point, motion is assigned to the 3D stamp. See Resources > [[Blend Shapes]] for more information on the process of adding expressions. Finally, set up collisions as needed. -''Collision Settings'' +At this point, the collision is assigned a simple collision box. Go to Resources > 3D Stamps and specify the appropriate collision in the "Rendering Stamp Settings" section. The following methods are available: -- Specify a vertical capsule with Simple Collision Settings. -- Turn on Accurate Collision. Then go to Resources > Physics Settings and specify collisions for each part.