A bit of cleanup on the Vector ToStrings

This commit is contained in:
Andy Korth 2013-01-08 12:04:21 -06:00
parent 4230c6b4f0
commit 6500e176df
10 changed files with 19 additions and 19 deletions

View file

@ -24,7 +24,7 @@ namespace Examples.Tests
Matrix4 translation = new Matrix4(new Vector4(1, 0, 0, 2), new Vector4(0, 1, 0, 3), new Vector4(0, 0, 1, -1), new Vector4(0, 0, 0, 1)); Matrix4 translation = new Matrix4(new Vector4(1, 0, 0, 2), new Vector4(0, 1, 0, 3), new Vector4(0, 0, 1, -1), new Vector4(0, 0, 0, 1));
Vector4 point = new Vector4(x, y, z, 1); Vector4 point = new Vector4(x, y, z, 1);
Vector4 result = Vector4.Transform(point, createdTranslation); Vector4 result = Vector4.Transform(point, translation);
Trace.WriteLine("Result should be: (3, 4, 0, 1) : " + result); Trace.WriteLine("Result should be: (3, 4, 0, 1) : " + result);

View file

@ -1053,14 +1053,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current Vector2. /// Returns a System.String that represents the current Vector2.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{2} {1})", X, Y, listSeparator);
return String.Format("({0}{2} {1})", X, Y, separator);
} }
#endregion #endregion

View file

@ -957,14 +957,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current instance. /// Returns a System.String that represents the current instance.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{2} {1})", X, Y, listSeparator);
return String.Format("({0}{2} {1})", X, Y, separator);
} }
#endregion #endregion

View file

@ -312,11 +312,11 @@ namespace OpenTK
#region ToString() #region ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary>Returns a string that contains this Half2's numbers in human-legible form.</summary> /// <summary>Returns a string that contains this Half2's numbers in human-legible form.</summary>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{2} {1})", X, Y, listSeparator);
return String.Format("({0}{2} {1})", X, Y, separator);
} }
#endregion ToString() #endregion ToString()

View file

@ -1335,14 +1335,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current Vector3. /// Returns a System.String that represents the current Vector3.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{3} {1}{3} {2})", X, Y, Z, listSeparator);
return String.Format("({0}{3} {1}{3} {2})", X, Y, Z, separator);
} }
#endregion #endregion

View file

@ -1348,14 +1348,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current Vector3. /// Returns a System.String that represents the current Vector3.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{3} {1}{3} {2})", X, Y, Z, listSeparator);
return String.Format("({0}{3} {1}{3} {2})", X, Y, Z, separator);
} }
#endregion #endregion

View file

@ -355,11 +355,11 @@ namespace OpenTK
#region ToString() #region ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary>Returns a string that contains this Half3's numbers in human-legible form.</summary> /// <summary>Returns a string that contains this Half3's numbers in human-legible form.</summary>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{3} {1}{3} {2})", X.ToString(), Y.ToString(), Z.ToString(), listSeparator);
return String.Format("({0}{3} {1}{3} {2})", X.ToString(), Y.ToString(), Z.ToString(), separator);
} }
#endregion ToString() #endregion ToString()

View file

@ -1168,14 +1168,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current Vector4. /// Returns a System.String that represents the current Vector4.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{4} {1}{4} {2}{4} {3})", X, Y, Z, W, listSeparator);
return String.Format("({0}{4} {1}{4} {2}{4} {3})", X, Y, Z, W, separator);
} }
#endregion #endregion

View file

@ -1187,14 +1187,14 @@ namespace OpenTK
#region public override string ToString() #region public override string ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary> /// <summary>
/// Returns a System.String that represents the current Vector4d. /// Returns a System.String that represents the current Vector4d.
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{4} {1}{4} {2}{4} {3})", X, Y, Z, W, listSeparator);
return String.Format("({0}{4} {1}{4} {2}{4} {3})", X, Y, Z, W, separator);
} }
#endregion #endregion

View file

@ -386,11 +386,11 @@ namespace OpenTK
#region ToString() #region ToString()
private static string listSeparator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator;
/// <summary>Returns a string that contains this Half4's numbers in human-legible form.</summary> /// <summary>Returns a string that contains this Half4's numbers in human-legible form.</summary>
public override string ToString() public override string ToString()
{ {
string separator = System.Globalization.CultureInfo.CurrentCulture.TextInfo.ListSeparator; return String.Format("({0}{4} {1}{4} {2}{4} {3})", X.ToString(), Y.ToString(), Z.ToString(), W.ToString(), listSeparator);
return String.Format("({0}{4} {1}{4} {2}{4} {3})", X.ToString(), Y.ToString(), Z.ToString(), W.ToString(), separator);
} }
#endregion ToString() #endregion ToString()