diff options
Diffstat (limited to 'source/blender/io/alembic/exporter')
27 files changed, 54 insertions, 162 deletions
diff --git a/source/blender/io/alembic/exporter/abc_archive.cc b/source/blender/io/alembic/exporter/abc_archive.cc index 5fbf74f0705..a181a721de9 100644 --- a/source/blender/io/alembic/exporter/abc_archive.cc +++ b/source/blender/io/alembic/exporter/abc_archive.cc @@ -37,9 +37,7 @@ # include "utfconv.h" #endif -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::Abc::ErrorHandler; using Alembic::Abc::kWrapExisting; @@ -260,6 +258,4 @@ void ABCArchive::update_bounding_box(const Imath::Box3d &bounds) abc_archive_bbox_.set(bounds); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_archive.h b/source/blender/io/alembic/exporter/abc_archive.h index 43d0acf2520..8e6e5e40663 100644 --- a/source/blender/io/alembic/exporter/abc_archive.h +++ b/source/blender/io/alembic/exporter/abc_archive.h @@ -36,9 +36,7 @@ struct Main; struct Scene; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { /* Container for an Alembic archive and time sampling info. * @@ -82,6 +80,4 @@ class ABCArchive { Alembic::Abc::OBox3dProperty abc_archive_bbox_; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_export_capi.cc b/source/blender/io/alembic/exporter/abc_export_capi.cc index 6412379c126..c22864a5433 100644 --- a/source/blender/io/alembic/exporter/abc_export_capi.cc +++ b/source/blender/io/alembic/exporter/abc_export_capi.cc @@ -62,9 +62,7 @@ struct ExportJobData { bool export_ok; }; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { // Construct the depsgraph for exporting. static void build_depsgraph(Depsgraph *depsgraph, const bool visible_objects_only) @@ -197,9 +195,7 @@ static void export_endjob(void *customdata) WM_set_locked_interface(data->wm, false); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic bool ABC_export(Scene *scene, bContext *C, diff --git a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc index 4cb6ca0c601..e2be241c144 100644 --- a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc +++ b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc @@ -40,9 +40,7 @@ #include "DNA_layer_types.h" #include "DNA_object_types.h" -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { ABCHierarchyIterator::ABCHierarchyIterator(Depsgraph *depsgraph, ABCArchive *abc_archive, @@ -275,6 +273,4 @@ AbstractHierarchyWriter *ABCHierarchyIterator::create_particle_writer( return particle_writer.release(); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.h b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.h index 5bc82564cdb..a0d9257b822 100644 --- a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.h +++ b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.h @@ -32,9 +32,7 @@ struct Depsgraph; struct ID; struct Object; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCAbstractWriter; class ABCHierarchyIterator; @@ -93,6 +91,4 @@ class ABCHierarchyIterator : public AbstractHierarchyIterator { const HierarchyContext *context, const ABCWriterConstructorArgs &writer_args); }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_subdiv_disabler.cc b/source/blender/io/alembic/exporter/abc_subdiv_disabler.cc index 7c147076975..255803a6bfb 100644 --- a/source/blender/io/alembic/exporter/abc_subdiv_disabler.cc +++ b/source/blender/io/alembic/exporter/abc_subdiv_disabler.cc @@ -32,9 +32,7 @@ #include "BKE_modifier.h" -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { SubdivModifierDisabler::SubdivModifierDisabler(Depsgraph *depsgraph) : depsgraph_(depsgraph) { @@ -102,6 +100,4 @@ ModifierData *SubdivModifierDisabler::get_subdiv_modifier(Scene *scene, Object * return nullptr; } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_subdiv_disabler.h b/source/blender/io/alembic/exporter/abc_subdiv_disabler.h index 677847f3f63..3556df7ff31 100644 --- a/source/blender/io/alembic/exporter/abc_subdiv_disabler.h +++ b/source/blender/io/alembic/exporter/abc_subdiv_disabler.h @@ -25,9 +25,7 @@ struct ModifierData; struct Object; struct Scene; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { /** * Temporarily all subdivision modifiers on mesh objects. @@ -50,6 +48,4 @@ class SubdivModifierDisabler final { static ModifierData *get_subdiv_modifier(Scene *scene, Object *ob); }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_abstract.cc b/source/blender/io/alembic/exporter/abc_writer_abstract.cc index 84527a12e85..0b08d8c4e58 100644 --- a/source/blender/io/alembic/exporter/abc_writer_abstract.cc +++ b/source/blender/io/alembic/exporter/abc_writer_abstract.cc @@ -32,9 +32,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::Abc::OObject; using Alembic::Abc::TimeSamplingPtr; @@ -112,6 +110,4 @@ void ABCAbstractWriter::write_visibility(const HierarchyContext &context) Alembic::AbcGeom::kVisibilityHidden); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_abstract.h b/source/blender/io/alembic/exporter/abc_writer_abstract.h index fefa9c356f2..59c55330443 100644 --- a/source/blender/io/alembic/exporter/abc_writer_abstract.h +++ b/source/blender/io/alembic/exporter/abc_writer_abstract.h @@ -30,9 +30,7 @@ struct Material; struct Object; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCAbstractWriter : public AbstractHierarchyWriter { protected: @@ -77,6 +75,4 @@ class ABCAbstractWriter : public AbstractHierarchyWriter { void write_visibility(const HierarchyContext &context); }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_camera.cc b/source/blender/io/alembic/exporter/abc_writer_camera.cc index 6f13f791c4e..0ce6c3dc07f 100644 --- a/source/blender/io/alembic/exporter/abc_writer_camera.cc +++ b/source/blender/io/alembic/exporter/abc_writer_camera.cc @@ -31,9 +31,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::AbcGeom::CameraSample; using Alembic::AbcGeom::OCamera; @@ -105,6 +103,4 @@ void ABCCameraWriter::do_write(HierarchyContext &context) abc_camera_schema_.set(camera_sample); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_camera.h b/source/blender/io/alembic/exporter/abc_writer_camera.h index ceaa352d162..1b3e5898517 100644 --- a/source/blender/io/alembic/exporter/abc_writer_camera.h +++ b/source/blender/io/alembic/exporter/abc_writer_camera.h @@ -23,9 +23,7 @@ #include <Alembic/AbcGeom/OCamera.h> -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCCameraWriter : public ABCAbstractWriter { private: @@ -47,6 +45,4 @@ class ABCCameraWriter : public ABCAbstractWriter { virtual void do_write(HierarchyContext &context) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_curves.cc b/source/blender/io/alembic/exporter/abc_writer_curves.cc index 9d65830c699..6a12e4c59f3 100644 --- a/source/blender/io/alembic/exporter/abc_writer_curves.cc +++ b/source/blender/io/alembic/exporter/abc_writer_curves.cc @@ -41,9 +41,7 @@ using Alembic::AbcGeom::OInt16Property; using Alembic::AbcGeom::ON3fGeomParam; using Alembic::AbcGeom::OV2fGeomParam; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { const std::string ABC_CURVE_RESOLUTION_U_PROPNAME("blender:resolution"); @@ -196,6 +194,4 @@ Mesh *ABCCurveMeshWriter::get_export_mesh(Object *object_eval, bool &r_needsfree return BKE_mesh_new_nomain_from_curve(object_eval); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_curves.h b/source/blender/io/alembic/exporter/abc_writer_curves.h index cd6621c398d..d15f008f947 100644 --- a/source/blender/io/alembic/exporter/abc_writer_curves.h +++ b/source/blender/io/alembic/exporter/abc_writer_curves.h @@ -27,9 +27,7 @@ #include <Alembic/AbcGeom/OCurves.h> -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { extern const std::string ABC_CURVE_RESOLUTION_U_PROPNAME; @@ -56,6 +54,4 @@ class ABCCurveMeshWriter : public ABCGenericMeshWriter { virtual Mesh *get_export_mesh(Object *object_eval, bool &r_needsfree) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_hair.cc b/source/blender/io/alembic/exporter/abc_writer_hair.cc index 1e1d2cf32ca..80034245b84 100644 --- a/source/blender/io/alembic/exporter/abc_writer_hair.cc +++ b/source/blender/io/alembic/exporter/abc_writer_hair.cc @@ -43,9 +43,7 @@ using Alembic::AbcGeom::OCurvesSchema; using Alembic::AbcGeom::ON3fGeomParam; using Alembic::AbcGeom::OV2fGeomParam; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { ABCHairWriter::ABCHairWriter(const ABCWriterConstructorArgs &args) : ABCAbstractWriter(args), uv_warning_shown_(false) @@ -306,6 +304,4 @@ void ABCHairWriter::write_hair_child_sample(const HierarchyContext &context, } } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_hair.h b/source/blender/io/alembic/exporter/abc_writer_hair.h index 0e149b0d045..f7d988ecbc4 100644 --- a/source/blender/io/alembic/exporter/abc_writer_hair.h +++ b/source/blender/io/alembic/exporter/abc_writer_hair.h @@ -26,9 +26,7 @@ struct ParticleSettings; struct ParticleSystem; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCHairWriter : public ABCAbstractWriter { private: @@ -63,6 +61,4 @@ class ABCHairWriter : public ABCAbstractWriter { std::vector<int32_t> &hvertices); }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_instance.cc b/source/blender/io/alembic/exporter/abc_writer_instance.cc index 581d94ee961..14c65e2a2e2 100644 --- a/source/blender/io/alembic/exporter/abc_writer_instance.cc +++ b/source/blender/io/alembic/exporter/abc_writer_instance.cc @@ -26,9 +26,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::Abc::OObject; @@ -69,6 +67,4 @@ void ABCInstanceWriter::do_write(HierarchyContext & /*context*/) /* Instances don't have data to be written. Just creating them is enough. */ } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_instance.h b/source/blender/io/alembic/exporter/abc_writer_instance.h index 74379b9d6bd..067c4af7aed 100644 --- a/source/blender/io/alembic/exporter/abc_writer_instance.h +++ b/source/blender/io/alembic/exporter/abc_writer_instance.h @@ -21,9 +21,7 @@ #include "abc_writer_abstract.h" -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { /* Writer for Alembic instances, i.e. data that references another Alembic object. * @@ -43,6 +41,4 @@ class ABCInstanceWriter : public ABCAbstractWriter { virtual void do_write(HierarchyContext &context) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_mball.cc b/source/blender/io/alembic/exporter/abc_writer_mball.cc index 167e392eb96..a797310f864 100644 --- a/source/blender/io/alembic/exporter/abc_writer_mball.cc +++ b/source/blender/io/alembic/exporter/abc_writer_mball.cc @@ -32,9 +32,7 @@ #include "DNA_mesh_types.h" #include "DNA_meta_types.h" -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { ABCMetaballWriter::ABCMetaballWriter(const ABCWriterConstructorArgs &args) : ABCGenericMeshWriter(args) @@ -85,6 +83,4 @@ bool ABCMetaballWriter::is_basis_ball(Scene *scene, Object *ob) const return ob == basis_ob; } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_mball.h b/source/blender/io/alembic/exporter/abc_writer_mball.h index 90d8c4d4b15..f96daa6d84b 100644 --- a/source/blender/io/alembic/exporter/abc_writer_mball.h +++ b/source/blender/io/alembic/exporter/abc_writer_mball.h @@ -21,9 +21,7 @@ #include "abc_writer_mesh.h" -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCMetaballWriter : public ABCGenericMeshWriter { public: @@ -40,6 +38,4 @@ class ABCMetaballWriter : public ABCGenericMeshWriter { bool is_basis_ball(Scene *scene, Object *ob) const; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_mesh.cc b/source/blender/io/alembic/exporter/abc_writer_mesh.cc index a9c722cae91..b762ad47932 100644 --- a/source/blender/io/alembic/exporter/abc_writer_mesh.cc +++ b/source/blender/io/alembic/exporter/abc_writer_mesh.cc @@ -66,9 +66,7 @@ using Alembic::AbcGeom::OSubDSchema; using Alembic::AbcGeom::OV2fGeomParam; using Alembic::AbcGeom::UInt32ArraySample; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { /* NOTE: Alembic's polygon winding order is clockwise, to match with Renderman. */ @@ -551,6 +549,4 @@ Mesh *ABCMeshWriter::get_export_mesh(Object *object_eval, bool & /*r_needsfree*/ return BKE_object_get_evaluated_mesh(object_eval); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_mesh.h b/source/blender/io/alembic/exporter/abc_writer_mesh.h index 2bb5b687c47..956587df7c0 100644 --- a/source/blender/io/alembic/exporter/abc_writer_mesh.h +++ b/source/blender/io/alembic/exporter/abc_writer_mesh.h @@ -27,9 +27,7 @@ struct ModifierData; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { /* Writer for Alembic geometry. Does not assume the object is a mesh object. */ class ABCGenericMeshWriter : public ABCAbstractWriter { @@ -90,6 +88,4 @@ class ABCMeshWriter : public ABCGenericMeshWriter { virtual Mesh *get_export_mesh(Object *object_eval, bool &r_needsfree) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_nurbs.cc b/source/blender/io/alembic/exporter/abc_writer_nurbs.cc index a2dc4441b75..de1870fefd9 100644 --- a/source/blender/io/alembic/exporter/abc_writer_nurbs.cc +++ b/source/blender/io/alembic/exporter/abc_writer_nurbs.cc @@ -31,9 +31,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::Abc::OObject; using Alembic::AbcGeom::FloatArraySample; @@ -181,6 +179,4 @@ void ABCNurbsWriter::do_write(HierarchyContext &context) } } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_nurbs.h b/source/blender/io/alembic/exporter/abc_writer_nurbs.h index f7fd8ffe91a..691390ffc9f 100644 --- a/source/blender/io/alembic/exporter/abc_writer_nurbs.h +++ b/source/blender/io/alembic/exporter/abc_writer_nurbs.h @@ -23,9 +23,7 @@ #include "abc_writer_mesh.h" #include <vector> -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCNurbsWriter : public ABCAbstractWriter { private: @@ -52,6 +50,4 @@ class ABCNurbsMeshWriter : public ABCGenericMeshWriter { virtual Mesh *get_export_mesh(Object *object_eval, bool &r_needsfree) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_points.cc b/source/blender/io/alembic/exporter/abc_writer_points.cc index 350b70b9552..83d33577b3b 100644 --- a/source/blender/io/alembic/exporter/abc_writer_points.cc +++ b/source/blender/io/alembic/exporter/abc_writer_points.cc @@ -36,9 +36,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::AbcGeom::kVertexScope; using Alembic::AbcGeom::OPoints; @@ -143,6 +141,4 @@ void ABCPointsWriter::do_write(HierarchyContext &context) abc_points_schema_.set(sample); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_points.h b/source/blender/io/alembic/exporter/abc_writer_points.h index 88dd424ca2a..fec5e84f3f2 100644 --- a/source/blender/io/alembic/exporter/abc_writer_points.h +++ b/source/blender/io/alembic/exporter/abc_writer_points.h @@ -26,9 +26,7 @@ #include <Alembic/AbcGeom/OPoints.h> -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCPointsWriter : public ABCAbstractWriter { Alembic::AbcGeom::OPoints abc_points_; @@ -47,6 +45,4 @@ class ABCPointsWriter : public ABCAbstractWriter { virtual void do_write(HierarchyContext &context) override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_transform.cc b/source/blender/io/alembic/exporter/abc_writer_transform.cc index 93ffd847bf2..a72a6b47aa9 100644 --- a/source/blender/io/alembic/exporter/abc_writer_transform.cc +++ b/source/blender/io/alembic/exporter/abc_writer_transform.cc @@ -33,9 +33,7 @@ #include "CLG_log.h" static CLG_LogRef LOG = {"io.alembic"}; -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { using Alembic::Abc::OObject; using Alembic::AbcGeom::OXform; @@ -115,6 +113,4 @@ bool ABCTransformWriter::check_is_animated(const HierarchyContext &context) cons return BKE_object_moves_in_time(context.object, context.animation_check_include_parent); } -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic diff --git a/source/blender/io/alembic/exporter/abc_writer_transform.h b/source/blender/io/alembic/exporter/abc_writer_transform.h index 9d172531d1f..a334fe610ee 100644 --- a/source/blender/io/alembic/exporter/abc_writer_transform.h +++ b/source/blender/io/alembic/exporter/abc_writer_transform.h @@ -23,9 +23,7 @@ #include <Alembic/AbcGeom/OXform.h> -namespace blender { -namespace io { -namespace alembic { +namespace blender::io::alembic { class ABCTransformWriter : public ABCAbstractWriter { private: @@ -42,6 +40,4 @@ class ABCTransformWriter : public ABCAbstractWriter { virtual Alembic::Abc::OObject get_alembic_object() const override; }; -} // namespace alembic -} // namespace io -} // namespace blender +} // namespace blender::io::alembic |