---
title: "setShear(_:forTime:)"
framework: modelio
role: symbol
role_heading: Instance Method
path: "modelio/mdltransform/setshear(_:fortime:)"
---

# setShear(_:forTime:)

Sets the x-, y-, and z-axis shear factors of the transform for the specified time sample.

## Declaration

```swift
func setShear(_ shear: vector_float3, forTime time: TimeInterval)
```

## Parameters

- `shear`: The shear factors to set for the transform relative to its parent coordinate space.
- `time`: The time sample with which to associate transform information.

## Discussion

Discussion Together with the translation, rotation, and scale factors, a shear vector defines the local coordinate space for any object affected by the transform, relative to a parent coordinate space. To work with the complete transform, use the localTransform(atTime:) and setLocalTransform(_:forTime:) methods. Setting a new shear synthesizes a complete transform matrix by combining the new translation with the translation(atTime:), rotation(atTime:), and scale(atTime:) factors for the specified time. If the new time is outside the range of the minimumTime and maximumTime properties, this method updates those values to reflect the range of time samples stored in the transform object.

## See Also

### Using Factors of an Animated Transform

- [translation(atTime:)](modelio/mdltransform/translation(attime:).md)
- [setTranslation(_:forTime:)](modelio/mdltransform/settranslation(_:fortime:).md)
- [rotation(atTime:)](modelio/mdltransform/rotation(attime:).md)
- [rotationMatrix(atTime:)](modelio/mdltransform/rotationmatrix(attime:).md)
- [setRotation(_:forTime:)](modelio/mdltransform/setrotation(_:fortime:).md)
- [scale(atTime:)](modelio/mdltransform/scale(attime:).md)
- [setScale(_:forTime:)](modelio/mdltransform/setscale(_:fortime:).md)
- [shear(atTime:)](modelio/mdltransform/shear(attime:).md)
- [setMatrix(_:forTime:)](modelio/mdltransform/setmatrix(_:fortime:).md)
