diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-04-25 11:43:36 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-04-25 11:45:26 +0300 |
commit | e353cf8705b0c8da529e0bd229dd13fe2b3c2abc (patch) | |
tree | c683b6de169487ca217cfdef4b8aed9a0da279f4 /source/blender/alembic/intern/abc_curves.cc | |
parent | 0a07cdbe80b2999478fa0d062a846e9bcfafc872 (diff) |
Revert "Alembic: Construct ISampleSelector once and pass along"
This reverts commit 099816587a0e064fb6a52c82a737ae8814cf21df. It had some
unforseen side-effects that should be investigated first.
Diffstat (limited to 'source/blender/alembic/intern/abc_curves.cc')
-rw-r--r-- | source/blender/alembic/intern/abc_curves.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/alembic/intern/abc_curves.cc b/source/blender/alembic/intern/abc_curves.cc index d85d8df4d77..bf485c7ef61 100644 --- a/source/blender/alembic/intern/abc_curves.cc +++ b/source/blender/alembic/intern/abc_curves.cc @@ -211,7 +211,7 @@ bool AbcCurveReader::valid() const return m_curves_schema.valid(); } -void AbcCurveReader::readObjectData(Main *bmain, const Alembic::Abc::ISampleSelector &sample_sel) +void AbcCurveReader::readObjectData(Main *bmain, float time) { Curve *cu = BKE_curve_add(bmain, m_data_name.c_str(), OB_CURVE); @@ -219,6 +219,8 @@ void AbcCurveReader::readObjectData(Main *bmain, const Alembic::Abc::ISampleSele cu->actvert = CU_ACT_NONE; cu->resolu = 1; + const ISampleSelector sample_sel(time); + ICompoundProperty user_props = m_curves_schema.getUserProperties(); if (user_props) { const PropertyHeader *header = user_props.getPropertyHeader(ABC_CURVE_RESOLUTION_U_PROPNAME); @@ -387,11 +389,9 @@ void read_curve_sample(Curve *cu, const ICurvesSchema &schema, const ISampleSele * object directly and create a new DerivedMesh from that. Also we might need to * create new or delete existing NURBS in the curve. */ -DerivedMesh *AbcCurveReader::read_derivedmesh(DerivedMesh * /*dm*/, - const ISampleSelector &sample_sel, - int /*read_flag*/, - const char ** /*err_str*/) +DerivedMesh *AbcCurveReader::read_derivedmesh(DerivedMesh * /*dm*/, const float time, int /*read_flag*/, const char ** /*err_str*/) { + ISampleSelector sample_sel(time); const ICurvesSchema::Sample sample = m_curves_schema.getValue(sample_sel); const P3fArraySamplePtr &positions = sample.getPositions(); |