//-***************************************************************************** void IArrayProperty::init( AbcA::CompoundPropertyReaderPtr iParent, const std::string &iName, ErrorHandler::Policy iParentPolicy, const Argument &iArg0, const Argument &iArg1 ) { Arguments args( iParentPolicy ); iArg0.setInto( args ); iArg1.setInto( args ); getErrorHandler().setPolicy( args.getErrorHandlerPolicy() ); ALEMBIC_ABC_SAFE_CALL_BEGIN( "IArrayProperty::init()" ); const AbcA::PropertyHeader *pheader = iParent->getPropertyHeader( iName ); ABCA_ASSERT( pheader != NULL, "Nonexistent array property: " << iName ); m_property = iParent->getArrayProperty( iName ); ALEMBIC_ABC_SAFE_CALL_END_RESET(); }
//-***************************************************************************** void OCompoundProperty::init( AbcA::CompoundPropertyWriterPtr iParent, const std::string &iName, const Argument &iArg0, const Argument &iArg1, const Argument &iArg2 ) { ALEMBIC_ABC_SAFE_CALL_BEGIN( "OCompoundProperty::init()" ); ABCA_ASSERT( iParent, "invalid parent" ); Arguments args; iArg0.setInto( args ); iArg1.setInto( args ); iArg2.setInto( args ); getErrorHandler().setPolicy( args.getErrorHandlerPolicy() ); m_property = Alembic::Util::dynamic_pointer_cast< AbcA::CompoundPropertyWriter>( iParent->getProperty( iName ) ); if ( !m_property ) { m_property = iParent->createCompoundProperty( iName, args.getMetaData() ); } ALEMBIC_ABC_SAFE_CALL_END_RESET(); }