59 typedef Sample this_type;
64 Abc::P3fArraySamplePtr getPositions()
const {
return m_positions; }
65 Abc::V3fArraySamplePtr getVelocities()
const {
return m_velocities; }
66 Abc::Int32ArraySamplePtr getFaceIndices()
const {
return m_indices; }
67 Abc::Int32ArraySamplePtr getFaceCounts()
const {
return m_counts; }
68 Abc::Box3d getSelfBounds()
const {
return m_selfBounds; }
72 return m_positions && m_indices && m_counts;
81 m_selfBounds.makeEmpty();
84 ALEMBIC_OPERATOR_BOOL( valid() );
87 friend class IPolyMeshSchema;
88 Abc::P3fArraySamplePtr m_positions;
89 Abc::V3fArraySamplePtr m_velocities;
90 Abc::Int32ArraySamplePtr m_indices;
91 Abc::Int32ArraySamplePtr m_counts;
92 Abc::Box3d m_selfBounds;
118 const std::string &iName,
124 init( iArg0, iArg1 );
136 init( iArg0, iArg1 );
153 {
return m_positionsProperty.getNumSamples(); }
157 MeshTopologyVariance getTopologyVariance()
const;
168 if ( m_positionsProperty.valid() )
170 return m_positionsProperty.getTimeSampling();
174 return getObject().getArchive().getTimeSampling( 0 );
179 void get( Sample &oSample,
182 ALEMBIC_ABC_SAFE_CALL_BEGIN(
"IPolyMeshSchema::get()" );
184 m_positionsProperty.get( oSample.m_positions, iSS );
185 m_indicesProperty.get( oSample.m_indices, iSS );
186 m_countsProperty.get( oSample.m_counts, iSS );
188 m_selfBoundsProperty.get( oSample.m_selfBounds, iSS );
190 if ( m_velocitiesProperty && m_velocitiesProperty.getNumSamples() > 0 )
192 m_velocitiesProperty.get( oSample.m_velocities, iSS );
197 ALEMBIC_ABC_SAFE_CALL_END();
207 IV2fGeomParam getUVsParam()
const
212 IN3fGeomParam getNormalsParam()
const
214 return m_normalsParam;
217 Abc::IInt32ArrayProperty getFaceCountsProperty()
const
219 return m_countsProperty;
222 Abc::IInt32ArrayProperty getFaceIndicesProperty()
const
224 return m_indicesProperty;
227 Abc::IP3fArrayProperty getPositionsProperty()
const
229 return m_positionsProperty;
232 Abc::IV3fArrayProperty getVelocitiesProperty()
const
234 return m_velocitiesProperty;
247 m_positionsProperty.reset();
248 m_velocitiesProperty.reset();
249 m_indicesProperty.reset();
250 m_countsProperty.reset();
253 m_normalsParam.reset();
255 IGeomBaseSchema<PolyMeshSchemaInfo>::reset();
262 return ( IGeomBaseSchema<PolyMeshSchemaInfo>::valid() &&
263 m_positionsProperty.valid() &&
264 m_indicesProperty.valid() &&
265 m_countsProperty.valid() );
270 void getFaceSetNames (std::vector <std::string> & oFaceSetNames);
271 IFaceSet getFaceSet(
const std::string &iFaceSetName );
272 bool hasFaceSet(
const std::string &iFaceSetName );
282 Abc::IP3fArrayProperty m_positionsProperty;
283 Abc::IV3fArrayProperty m_velocitiesProperty;
284 Abc::IInt32ArrayProperty m_indicesProperty;
285 Abc::IInt32ArrayProperty m_countsProperty;
287 IV2fGeomParam m_uvsParam;
288 IN3fGeomParam m_normalsParam;
292 bool m_faceSetsLoaded;
293 std::map <std::string, IFaceSet> m_faceSets;
295 void loadFaceSetNames();
IPolyMeshSchema(const ICompoundProperty &iParent, const std::string &iName, const Abc::Argument &iArg0=Abc::Argument(), const Abc::Argument &iArg1=Abc::Argument())
Definition IPolyMesh.h:117