mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-07-08 13:10:35 +00:00
Removed unused variables and relevant warnings.
This commit is contained in:
parent
437273f215
commit
c084833d48
|
@ -25,7 +25,7 @@ namespace Examples.OpenAL
|
||||||
const int buffer_size = (int)(0.5*44100);
|
const int buffer_size = (int)(0.5*44100);
|
||||||
const int buffer_count = 4;
|
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()
|
public static void Main()
|
||||||
{
|
{
|
||||||
|
|
|
@ -16,7 +16,8 @@ namespace Examples.Tests
|
||||||
public class MathSpeed
|
public class MathSpeed
|
||||||
{
|
{
|
||||||
public static void Main()
|
public static void Main()
|
||||||
{
|
{
|
||||||
|
/*
|
||||||
Stopwatch watch = new Stopwatch();
|
Stopwatch watch = new Stopwatch();
|
||||||
|
|
||||||
Vector3 a = new Vector3(0.0f, 0.0f, 0.0f);
|
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);
|
Vector3.Add(ref a, ref b, out res);
|
||||||
res = a + b;
|
res = a + b;
|
||||||
res = Vector3.Zero;
|
res = Vector3.Zero;
|
||||||
/*
|
|
||||||
watch.Reset();
|
watch.Reset();
|
||||||
watch.Start();
|
watch.Start();
|
||||||
for (int i = 100000000; --i != 0; )
|
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
|
//static Vector3 Pos
|
||||||
{
|
//{
|
||||||
get { return pos; }
|
// get { return pos; }
|
||||||
set { pos = value; }
|
// set { pos = value; }
|
||||||
}
|
//}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -175,10 +175,11 @@ namespace Examples.Tutorial
|
||||||
}
|
}
|
||||||
|
|
||||||
// Move to the right, and print using the second font.
|
// Move to the right, and print using the second font.
|
||||||
float width, height;
|
//float width, height;
|
||||||
fonts[handles.Length / 2 - 1].MeasureString(text, out width, out height);
|
//fonts[handles.Length / 2 - 1].MeasureString(text, out width, out height);
|
||||||
|
RectangleF rect = fonts[handles.Length / 2 - 1].MeasureText(text);
|
||||||
GL.LoadIdentity();
|
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++)
|
for (int i = handles.Length / 2; i < handles.Length; i++)
|
||||||
{
|
{
|
||||||
printer.Draw(handles[i]);
|
printer.Draw(handles[i]);
|
||||||
|
|
|
@ -30,8 +30,8 @@ namespace Examples.Tutorial
|
||||||
float angle = 0.0f;
|
float angle = 0.0f;
|
||||||
|
|
||||||
Shapes.Shape shape = new Examples.Shapes.Plane(16, 16, 2.0f, 2.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,
|
//TextureFont sans = new TextureFont(new Font(FontFamily.GenericSansSerif, 32, FontStyle.Regular,
|
||||||
GraphicsUnit.Pixel));
|
// GraphicsUnit.Pixel));
|
||||||
|
|
||||||
#region Constructor
|
#region Constructor
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ namespace Examples.Tutorial
|
||||||
#region --- Private Fields ---
|
#region --- Private Fields ---
|
||||||
|
|
||||||
Shapes.Shape cube = new Examples.Shapes.Cube();
|
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
|
struct Vbo
|
||||||
{
|
{
|
||||||
|
|
|
@ -13,7 +13,12 @@ namespace Examples.WinForms
|
||||||
{
|
{
|
||||||
public partial class DerivedGLControl : GLControl
|
public partial class DerivedGLControl : GLControl
|
||||||
{
|
{
|
||||||
Color clearColor;
|
Color clearColor;
|
||||||
|
|
||||||
|
public DerivedGLControl()
|
||||||
|
{
|
||||||
|
this.InitializeComponent();
|
||||||
|
}
|
||||||
|
|
||||||
public Color ClearColor
|
public Color ClearColor
|
||||||
{
|
{
|
||||||
|
|
|
@ -27,7 +27,7 @@ namespace Examples.WinForms
|
||||||
GLControl glControl = new GLControl(GraphicsMode.Default);
|
GLControl glControl = new GLControl(GraphicsMode.Default);
|
||||||
Type glClass;
|
Type glClass;
|
||||||
Type delegatesClass;
|
Type delegatesClass;
|
||||||
Type importsClass;
|
//Type importsClass;
|
||||||
int supported, all; // Number of supported extensions.
|
int supported, all; // Number of supported extensions.
|
||||||
string driver;
|
string driver;
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ namespace Examples.WinForms
|
||||||
|
|
||||||
glClass = typeof(GL);
|
glClass = typeof(GL);
|
||||||
delegatesClass = glClass.GetNestedType("Delegates", BindingFlags.Static | BindingFlags.NonPublic);
|
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();
|
glControl.CreateControl();
|
||||||
Application.Idle += StartAsync;
|
Application.Idle += StartAsync;
|
||||||
|
|
|
@ -1433,7 +1433,9 @@ namespace OpenTK.Platform.Windows
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region PixelFormatDescriptor
|
#region PixelFormatDescriptor
|
||||||
|
|
||||||
|
#pragma warning disable 0169
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Describes a pixel format. It is used when interfacing with the WINAPI to create a new Context.
|
/// Describes a pixel format. It is used when interfacing with the WINAPI to create a new Context.
|
||||||
/// Found in WinGDI.h
|
/// Found in WinGDI.h
|
||||||
|
@ -1467,7 +1469,9 @@ namespace OpenTK.Platform.Windows
|
||||||
internal int LayerMask;
|
internal int LayerMask;
|
||||||
internal int VisibleMask;
|
internal int VisibleMask;
|
||||||
internal int DamageMask;
|
internal int DamageMask;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#pragma warning restore 0169
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue