Code style format.

This commit is contained in:
K. S. Ernest (iFire) Lee 2021-11-28 12:06:46 -08:00
commit 669985c64c
5 changed files with 17 additions and 16 deletions

View File

@ -469,7 +469,7 @@ static void ReadMesh(
const RawMaterialType materialType =
GetMaterialType(raw, textures, vertexTransparency, skinning.IsSkinned());
const int rawMaterialIndex = raw.AddMaterial(
materialId, materialName, materialType, textures, rawMatProps, userProperties, false );
materialId, materialName, materialType, textures, rawMatProps, userProperties, false);
raw.AddTriangle(
rawVertexIndices[0],

View File

@ -94,13 +94,14 @@ MaterialData::MaterialData(
pbrMetallicRoughness(pbrMetallicRoughness) {}
json MaterialData::serialize() const {
json result = {{"name", name},
{"alphaMode", isTransparent ? "BLEND" : "OPAQUE"},
{"doubleSided", isDoubleSided},
{"extras",
{{"fromFBX",
{{"shadingModel", Describe(shadingModel)},
{"isTruePBR", shadingModel == RAW_SHADING_MODEL_PBR_MET_ROUGH}}}}}};
json result = {
{"name", name},
{"alphaMode", isTransparent ? "BLEND" : "OPAQUE"},
{"doubleSided", isDoubleSided},
{"extras",
{{"fromFBX",
{{"shadingModel", Describe(shadingModel)},
{"isTruePBR", shadingModel == RAW_SHADING_MODEL_PBR_MET_ROUGH}}}}}};
if (normalTexture != nullptr) {
result["normalTexture"] = *normalTexture;

View File

@ -150,7 +150,7 @@ int RawModel::AddMaterial(
const int textures[RAW_TEXTURE_USAGE_MAX],
std::shared_ptr<RawMatProps> materialInfo,
const std::vector<std::string>& userProperties,
const bool isDoubleSided ) {
const bool isDoubleSided) {
for (size_t i = 0; i < materials.size(); i++) {
if (materials[i].name != name) {
continue;

View File

@ -383,7 +383,7 @@ class RawModel {
const int textures[RAW_TEXTURE_USAGE_MAX],
std::shared_ptr<RawMatProps> materialInfo,
const std::vector<std::string>& userProperties,
const bool isDoubleSided );
const bool isDoubleSided);
int AddLight(
const char* name,
RawLightType lightType,