Normalize whitespaces in the codebase

This commit is contained in:
Andrej730
2026-08-19 18:16:59 +05:00
parent 030e6e5bb4
commit 104591a80b
117 changed files with 636 additions and 638 deletions
+7 -7
View File
@@ -114,7 +114,7 @@ std::vector<pxr::UsdShadeMaterial> usd_serializer::createMaterials(const std::ve
}
void usd_serializer::writeHeader() {
stage_->GetRootLayer()->SetComment("File generated by IfcOpenShell " + std::string(IFCOPENSHELL_VERSION));
stage_->GetRootLayer()->SetComment("File generated by IfcOpenShell " + std::string(IFCOPENSHELL_VERSION));
}
std::string usd_serializer::object_id_unique(const ifcopenshell::geom::element* o) {
@@ -147,10 +147,10 @@ T usd_serializer::writeNode(const ifcopenshell::geom::element* o, const ifcopens
written_.insert(o->id());
auto m = o->transformation().data()->ccomponents();
// store absolute matrix for calculating relative child matrices later on.
placements_[o->id()] = o->transformation().data();
bool is_root = false;
std::string prefix = "/";
if (settings_.get<ifcopenshell::geom::settings::UseElementHierarchy>().get() && p == nullptr && o->parents().empty()) {
@@ -168,7 +168,7 @@ T usd_serializer::writeNode(const ifcopenshell::geom::element* o, const ifcopens
std::ostringstream oss;
std::copy(names.begin(), names.end(), std::ostream_iterator<std::string>(oss, "/"));
prefix += oss.str();
// std::ostringstream pss;
// pss << "MATT" << std::endl << std::endl;
// pss << m << std::endl << std::endl << o->parents().back()->transformation().data()->ccomponents() << std::endl << std::endl;
@@ -180,12 +180,12 @@ T usd_serializer::writeNode(const ifcopenshell::geom::element* o, const ifcopens
}
auto el_path = prefix + object_id_unique(o);
paths_[o->id()] = el_path;
T t = T::Define(stage_, pxr::SdfPath(el_path));
if (is_root) {
stage_->SetDefaultPrim(t.GetPrim());
}
t.AddTransformOp().Set(pxr::GfMatrix4d(
m.data()[0], m.data()[1], m.data()[2], m.data()[3],
m.data()[4], m.data()[5], m.data()[6], m.data()[7],
@@ -207,7 +207,7 @@ void usd_serializer::write(const ifcopenshell::geom::triangulation_element* o) {
const auto verts = mesh.verts();
const auto faces = mesh.faces();
const auto material_ids = mesh.material_ids();
pxr::VtVec3fArray points;
for(std::size_t i = 0; i < verts.size(); i+=3) {