Using SuperBMD

This article describes how to use SuperBMD, a program which can convert between common 3d model files (.dae / .fbx / .obj )

Conversion: .bmd -> .dae
The basic usage of SuperBMD is to drag n drop the desired model onto SuperBMD.exe. In the .bmd to .dae conversion, it will dump a .dae file, the textures (including mipmaps), and material and texture data .json files in the same directory as the original .bmd file. Usually, this .dae file is then imported into a CAD software such as 3ds Max. If using the command line, use the instruction

SuperBMD.exe 

The .json files
There are two .json files that are created with .bmd -> .dae conversion. Here they are described in more detail.

material .json
This file defines materials the final .bmd. If a material is not defined within this file, it will take on a default material, as defined by SuperBMD. If a .json file is not specified during conversion, all materials will have the default material. Alternatively, you can define your own default material by having it be named "__MatDefault". To have multiple default materials, you can create several materials named "__MatDefault::Category", and every material with name "Category" in it will have the material. Here is a quick rundown of some of the settings:
 * Name - The name of the material being defined
 * CullMode - determines which faces will render
 * "Back" (default) - triangles facing away from the camera are not rendered
 * "Front" - triangles facing toward the camera are not rendered
 * None - All triangles are always rendered
 * All - No triangles are ever rendered
 * Texture Names - the list of textures that this material uses
 * The ":number" after each texture name points to the index of that texture header in the texture.json file. So, a :0 will look for the first header with that texture name, a :1 will look for the second header with that texture name.
 * SwapModes - determines the channel that each channel will draw from
 * For example, one can have the red channel in the final render be drawn from the green channel in the texture.
 * In order, you define the source of the red, green, blue, then alpha channels.
 * 0 = "sample from red", 1 = "sample from green", 2 = "sample from blue", 3 = "sample from alpha"
 * AlphCompare - Alpha Compare
 * Creates a filter based on the alpha of a pixel that determines whether or not that pixel is rendered.
 * BMode - Blend Mode
 * Determines how a mesh is rendered in relation to meshes that have already been rendered.

texheader .json
This file is basically an array of various texture headers, which gives information about how textures should be rendered. If using a texheader file during not .bmd -> .bmd conversion, at the very least, all textures in your model and in the defined materials should be listed. Here is a quick rundown of some of the settings:
 * Name - the name of the texture
 * headers with the same texture name are allowed - this allows one to use the same texture in different materials with different settings
 * Format - how pixel information is stored within an image
 * By default, SuperBMD will assign "IA8" if the image is grayscale, "RGB5A3" if the texture is translucent, and "CMPR" otherwise.
 * A list of color formats can be found here
 * WrapS / WrapT - basically WrapU / WrapV
 * Define how UVs should act when a meshes UV's put them outside of the texture.
 * S is for U, and T is for V
 * "Clamp" will put the UVS at the closest edge of the texture, "Repeat" will cause the texture to be repeated over all UV space, and "Mirror" will cause the texture to be mirrored over all UV space.
 * PaletteFormat - see here for more information
 * MipMap - Set to 1 if a texture has mipmaps, otherwise, put it to 0

For a texture that has mipmaps, only one texheader is needed. The following settings should be used:
 * MipMap set to 1
 * MinFilter set to "LinearMipmapLinear"
 * MaxLOD set to the number of mipmaps.

Conversion: not .bmd -> .bmd
The basic usage of SuperBMD in this direction is to drag n drop the model onto SuperBMD.exe, and a .bmd of the same name will appear in the directory of the original file.

Custom Materials / Texture Data
To have custom materials, you must specify a material .json file and texheader .json data files. These files take the format of the material and texture data .json files from .bmd -> .dae conversion. The command line instruction

SuperBMD.exe   --mat material_data.json --texheader texture_data.json

will specify these files.

Additional Features

 * --rotate, which rotates the model poster-like for conversion from not .bmd -> .bmd conversion.
 * Mipmaps
 * Each image with mipmaps must have dimensions that are a power of 2. Each successive mipmap must be a quarter the size of the next larger one.
 * The base image should be named normally, and each successive mipmap should be named _mip#, with the # starting a 1 for the first mipmap.

Common Errors
STILL IN PROGRESS - PLEASE ADD IF YOU HAVE ANY COMMON ISSUES

{| class="wikitable"