( self )
| 98 | self.assertEqual( ms["notVel"].data, m["notVel"].data ) |
| 99 | |
| 100 | def testSamePrimVars( self ) : |
| 101 | |
| 102 | m = IECoreScene.MeshPrimitive.createBox( imath.Box3f( imath.V3f( -1 ), imath.V3f( 1 ) ) ) |
| 103 | IECoreScene.MeshNormalsOp()( input = m, copyInput = False ) |
| 104 | m["vel"] = IECoreScene.PrimitiveVariable( IECoreScene.PrimitiveVariable.Interpolation.Vertex, IECore.V3fVectorData( [ imath.V3f( 0.5 ) ] * 8, IECore.GeometricData.Interpretation.Vector ) ) |
| 105 | m["sameVel"] = m["vel"] |
| 106 | |
| 107 | ms = IECoreScene.TransformOp()( input=m, primVarsToModify = IECore.StringVectorData( [ "vel", "sameVel" ] ), matrix = IECore.M44fData( imath.M44f().scale( imath.V3f( 1, 2, 3 ) ) ) ) |
| 108 | |
| 109 | self.assertEqual( ms["vel"].data, IECore.V3fVectorData( [ x * imath.V3f( 1, 2, 3 ) for x in m["vel"].data ], IECore.GeometricData.Interpretation.Vector ) ) |
| 110 | self.assertEqual( ms["vel"].data, ms["sameVel"].data ) |
| 111 | |
| 112 | def testIdenticalPrimVarsCanBeExcluded( self ) : |
| 113 |
nothing calls this directly
no test coverage detected