since constructors support each other, adding explicit operators for minor reduction in typing required

This commit is contained in:
SignpostMarv
2012-09-06 12:00:58 +01:00
parent 5be4c13f36
commit 112fd49427
2 changed files with 21 additions and 0 deletions

View File

@@ -566,6 +566,17 @@ namespace OpenMetaverse
return Cross(value1, value2);
}
/// <summary>
/// Explicit casting for Vector3d > Vector3
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
public static explicit operator Vector3(Vector3d value)
{
Vector3d foo = (Vector3d)Vector3.Zero;
return new Vector3(value);
}
#endregion Operators
/// <summary>A vector with a value of 0,0,0</summary>