Added scale to IObject3D extensions
This commit is contained in:
parent
169c5a624a
commit
b86371c8ca
1 changed files with 12 additions and 0 deletions
|
|
@ -58,6 +58,18 @@ namespace MatterHackers.MatterControl.DesignTools.Operations
|
|||
return objectToTranslate;
|
||||
}
|
||||
|
||||
|
||||
public static IObject3D Scale(this IObject3D objectToTranslate, double x = 0, double y = 0, double z = 0, string name = "")
|
||||
{
|
||||
return objectToTranslate.Scale(new Vector3(x, y, z), name);
|
||||
}
|
||||
|
||||
public static IObject3D Scale(this IObject3D objectToTranslate, Vector3 translation, string name = "")
|
||||
{
|
||||
objectToTranslate.Matrix *= Matrix4X4.CreateScale(translation);
|
||||
return objectToTranslate;
|
||||
}
|
||||
|
||||
public static IObject3D Minus(this IObject3D a, IObject3D b)
|
||||
{
|
||||
var resultsA = a.Clone();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue