diff --git a/Source/OpenTK/Fonts/IPrinterImplementation.cs b/Source/OpenTK/Fonts/IPrinterImplementation.cs index 42303747..d8f73e8d 100644 --- a/Source/OpenTK/Fonts/IPrinterImplementation.cs +++ b/Source/OpenTK/Fonts/IPrinterImplementation.cs @@ -1,4 +1,10 @@ -using System; +#region --- License --- +/* Copyright (c) 2006, 2007 Stefanos Apostolopoulos + * See license.txt for license info + */ +#endregion + +using System; using System.Collections.Generic; using System.Text; diff --git a/Source/OpenTK/Fonts/ITextPrinter.cs b/Source/OpenTK/Fonts/ITextPrinter.cs index f9cbbc53..3ee3b290 100644 --- a/Source/OpenTK/Fonts/ITextPrinter.cs +++ b/Source/OpenTK/Fonts/ITextPrinter.cs @@ -1,4 +1,10 @@ -using System; +#region --- License --- +/* Copyright (c) 2006, 2007 Stefanos Apostolopoulos + * See license.txt for license info + */ +#endregion + +using System; using System.Collections.Generic; using System.Text; using System.Drawing; diff --git a/Source/OpenTK/Math/Box2.cs b/Source/OpenTK/Math/Box2.cs index 5dded781..793d19bf 100644 --- a/Source/OpenTK/Math/Box2.cs +++ b/Source/OpenTK/Math/Box2.cs @@ -1,4 +1,10 @@ -using System; +#region --- License --- +/* Copyright (c) 2006, 2007 Stefanos Apostolopoulos + * See license.txt for license info + */ +#endregion + +using System; using System.Collections.Generic; using System.Text; using System.Runtime.InteropServices; diff --git a/Source/OpenTK/Math/Functions.cs b/Source/OpenTK/Math/Functions.cs index 68eb42a7..d212234b 100644 --- a/Source/OpenTK/Math/Functions.cs +++ b/Source/OpenTK/Math/Functions.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 Stefanos Apostolopoulos - * Contributions by Andy Gill. * See license.txt for license info + * + * Contributions by Andy Gill. */ #endregion diff --git a/Source/OpenTK/Math/Matrix4.cs b/Source/OpenTK/Math/Matrix4.cs index 057d3d30..ee390329 100644 --- a/Source/OpenTK/Math/Matrix4.cs +++ b/Source/OpenTK/Math/Matrix4.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 the OpenTK team - * Implemented by Andy Gill * See license.txt for license info + * + * Implemented by Andy Gill */ #endregion diff --git a/Source/OpenTK/Math/Quaternion.cs b/Source/OpenTK/Math/Quaternion.cs index 510d3984..fcbb45da 100644 --- a/Source/OpenTK/Math/Quaternion.cs +++ b/Source/OpenTK/Math/Quaternion.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 the OpenTK team - * Implemented by Andy Gill * See license.txt for license info + * + * Implemented by Andy Gill */ #endregion diff --git a/Source/OpenTK/Math/Vector2.cs b/Source/OpenTK/Math/Vector2.cs index 7f0596f7..81dbf6e2 100644 --- a/Source/OpenTK/Math/Vector2.cs +++ b/Source/OpenTK/Math/Vector2.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 Stefanos Apostolopoulos - * Contributions by Andy Gill. * See license.txt for license info + * + * Contributions by Andy Gill. */ #endregion diff --git a/Source/OpenTK/Math/Vector3.cs b/Source/OpenTK/Math/Vector3.cs index b025954f..7747eff2 100644 --- a/Source/OpenTK/Math/Vector3.cs +++ b/Source/OpenTK/Math/Vector3.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 Stefanos Apostolopoulos - * Contributions by Andy Gill. * See license.txt for license info + * + * Contributions by Andy Gill. */ #endregion diff --git a/Source/OpenTK/Math/Vector4.cs b/Source/OpenTK/Math/Vector4.cs index 24660a39..f1475a10 100644 --- a/Source/OpenTK/Math/Vector4.cs +++ b/Source/OpenTK/Math/Vector4.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 Stefanos Apostolopoulos - * Contributions by Andy Gill. * See license.txt for license info + * + * Contributions by Andy Gill. */ #endregion diff --git a/Source/OpenTK/OpenGL/GLHelper.cs b/Source/OpenTK/OpenGL/GLHelper.cs index c908a755..58db4ba4 100644 --- a/Source/OpenTK/OpenGL/GLHelper.cs +++ b/Source/OpenTK/OpenGL/GLHelper.cs @@ -1,7 +1,8 @@ #region --- License --- /* Copyright (c) 2006, 2007 Stefanos Apostolopoulos - * Contributions by Andy Gill. * See license.txt for license info + * + * Contributions by Andy Gill. */ #endregion @@ -688,6 +689,40 @@ namespace OpenTK.OpenGL #endregion + #region public static void ShaderSource(Int32 shader, System.String @string) + + public static void ShaderSource(Int32 shader, System.String @string) + { + unsafe + { + int length = @string.Length; + Delegates.glShaderSource((UInt32)shader, 1, new string[] { @string }, &length); + } + } + + #endregion + + #region public static void GetShaderInfoLog(Int32 shader, out string info) + + public static void GetShaderInfoLog(Int32 shader, out string info) + { + unsafe + { + int length; + GL.GetShader(shader, Version20.InfoLogLength, out length); + if (length == 0) + { + info = ""; + return; + } + StringBuilder sb = new StringBuilder(length); + Delegates.glGetShaderInfoLog((UInt32)shader, sb.Capacity, &length, sb); + info = sb.ToString(); + } + } + + #endregion + #endregion } }