diff options
author | Sergey Sharybin <sergey@blender.org> | 2020-11-12 11:26:20 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey@blender.org> | 2020-11-12 11:26:20 +0300 |
commit | de6cee4fc1913982b0b2bd786bfd813c935bbe73 (patch) | |
tree | a726c0c63bbd1d6c47c90c32119ce14c8048cddc /source/blender/io/alembic/exporter/abc_writer_transform.cc | |
parent | e4d432500a0e2f978fe019da43deb843da405032 (diff) | |
parent | 88bb29dea668df8cc46aa7f55895f229748bdbb4 (diff) |
Merge branch 'master' into codesign_error_tracker
Diffstat (limited to 'source/blender/io/alembic/exporter/abc_writer_transform.cc')
-rw-r--r-- | source/blender/io/alembic/exporter/abc_writer_transform.cc | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/source/blender/io/alembic/exporter/abc_writer_transform.cc b/source/blender/io/alembic/exporter/abc_writer_transform.cc index a72a6b47aa9..7fe9fd933c5 100644 --- a/source/blender/io/alembic/exporter/abc_writer_transform.cc +++ b/source/blender/io/alembic/exporter/abc_writer_transform.cc @@ -53,12 +53,23 @@ void ABCTransformWriter::create_alembic_objects(const HierarchyContext * /*conte abc_xform_schema_ = abc_xform_.getSchema(); } +Alembic::Abc::OCompoundProperty ABCTransformWriter::abc_prop_for_custom_props() +{ + return abc_schema_prop_for_custom_props<OXformSchema>(abc_xform_schema_); +} + +const IDProperty *ABCTransformWriter::get_id_properties(const HierarchyContext &context) const +{ + const Object *object = context.object; + return object->id.properties; +} + void ABCTransformWriter::do_write(HierarchyContext &context) { - float parent_relative_matrix[4][4]; // The object matrix relative to the parent. + float parent_relative_matrix[4][4]; /* The object matrix relative to the parent. */ mul_m4_m4m4(parent_relative_matrix, context.parent_matrix_inv_world, context.matrix_world); - // After this, parent_relative_matrix uses Y=up. + /* After this, parent_relative_matrix uses Y=up. */ copy_m44_axis_swap(parent_relative_matrix, parent_relative_matrix, ABC_YUP_FROM_ZUP); /* If the parent is a camera, undo its to-Maya rotation (see below). */ @@ -101,7 +112,7 @@ OObject ABCTransformWriter::get_alembic_object() const bool ABCTransformWriter::check_is_animated(const HierarchyContext &context) const { - if (context.duplicator != NULL) { + if (context.duplicator != nullptr) { /* This object is being duplicated, so could be emitted by a particle system and thus * influenced by forces. TODO(Sybren): Make this more strict. Probably better to get from the * depsgraph whether this object instance has a time source. */ |