Removed unused variables and relevant warnings.

This commit is contained in:
the_fiddler 2008-09-19 20:57:35 +00:00
parent fb86950099
commit 573622bf0b
8 changed files with 31 additions and 20 deletions

View file

@ -25,7 +25,7 @@ namespace Examples.OpenAL
const int buffer_size = (int)(0.5*44100);
const int buffer_count = 4;
static object openal_lock = new object(); // Should be global in your app.
//static object openal_lock = new object(); // Should be global in your app.
public static void Main()
{

View file

@ -16,7 +16,8 @@ namespace Examples.Tests
public class MathSpeed
{
public static void Main()
{
{
/*
Stopwatch watch = new Stopwatch();
Vector3 a = new Vector3(0.0f, 0.0f, 0.0f);
@ -31,7 +32,7 @@ namespace Examples.Tests
Vector3.Add(ref a, ref b, out res);
res = a + b;
res = Vector3.Zero;
/*
watch.Reset();
watch.Start();
for (int i = 100000000; --i != 0; )
@ -82,12 +83,12 @@ namespace Examples.Tests
*/
}
static Vector3 pos = new Vector3();
//static Vector3 pos = new Vector3();
static Vector3 Pos
{
get { return pos; }
set { pos = value; }
}
//static Vector3 Pos
//{
// get { return pos; }
// set { pos = value; }
//}
}
}

View file

@ -175,10 +175,11 @@ namespace Examples.Tutorial
}
// Move to the right, and print using the second font.
float width, height;
fonts[handles.Length / 2 - 1].MeasureString(text, out width, out height);
//float width, height;
//fonts[handles.Length / 2 - 1].MeasureString(text, out width, out height);
RectangleF rect = fonts[handles.Length / 2 - 1].MeasureText(text);
GL.LoadIdentity();
GL.Translate(width + 32.0f, 0, 0);
GL.Translate(rect.Width + 32.0f, 0, 0);
for (int i = handles.Length / 2; i < handles.Length; i++)
{
printer.Draw(handles[i]);

View file

@ -30,8 +30,8 @@ namespace Examples.Tutorial
float angle = 0.0f;
Shapes.Shape shape = new Examples.Shapes.Plane(16, 16, 2.0f, 2.0f);
TextureFont sans = new TextureFont(new Font(FontFamily.GenericSansSerif, 32, FontStyle.Regular,
GraphicsUnit.Pixel));
//TextureFont sans = new TextureFont(new Font(FontFamily.GenericSansSerif, 32, FontStyle.Regular,
// GraphicsUnit.Pixel));
#region Constructor

View file

@ -27,7 +27,7 @@ namespace Examples.Tutorial
#region --- Private Fields ---
Shapes.Shape cube = new Examples.Shapes.Cube();
Shapes.Shape plane = new Examples.Shapes.Plane(16, 16, 2.0f, 2.0f);
//Shapes.Shape plane = new Examples.Shapes.Plane(16, 16, 2.0f, 2.0f);
struct Vbo
{

View file

@ -13,7 +13,12 @@ namespace Examples.WinForms
{
public partial class DerivedGLControl : GLControl
{
Color clearColor;
Color clearColor;
public DerivedGLControl()
{
this.InitializeComponent();
}
public Color ClearColor
{

View file

@ -27,7 +27,7 @@ namespace Examples.WinForms
GLControl glControl = new GLControl(GraphicsMode.Default);
Type glClass;
Type delegatesClass;
Type importsClass;
//Type importsClass;
int supported, all; // Number of supported extensions.
string driver;
@ -37,7 +37,7 @@ namespace Examples.WinForms
glClass = typeof(GL);
delegatesClass = glClass.GetNestedType("Delegates", BindingFlags.Static | BindingFlags.NonPublic);
importsClass = glClass.GetNestedType("Imports", BindingFlags.Static | BindingFlags.NonPublic);
//importsClass = glClass.GetNestedType("Imports", BindingFlags.Static | BindingFlags.NonPublic);
glControl.CreateControl();
Application.Idle += StartAsync;

View file

@ -1433,7 +1433,9 @@ namespace OpenTK.Platform.Windows
#endregion
#region PixelFormatDescriptor
#pragma warning disable 0169
/// <summary>
/// Describes a pixel format. It is used when interfacing with the WINAPI to create a new Context.
/// Found in WinGDI.h
@ -1467,7 +1469,9 @@ namespace OpenTK.Platform.Windows
internal int LayerMask;
internal int VisibleMask;
internal int DamageMask;
}
}
#pragma warning restore 0169
#endregion