daily update on 20240104 by nitload youmu, double threading not work

This commit is contained in:
Nitload
2024-01-04 08:58:12 +08:00
parent 14eaab455f
commit 2767c91293
138 changed files with 9692 additions and 11011 deletions
@@ -71,7 +71,7 @@ namespace StgSharp
InternalIO.InternalWriteLog(log, LogType.Warning);
}
}
InternalIO.InternalInitGL(4, 6);
InternalIO.InternalInitGL(majorVersion, minorVersion);
}
/// <summary>
@@ -96,7 +96,7 @@ namespace StgSharp
return Marshal.GetDelegateForFunctionPointer<TDele>(funcPtr);
}
catch (Exception ex)
catch (Exception)
{
throw;
}
@@ -114,7 +114,7 @@ namespace StgSharp
return Marshal.GetDelegateForFunctionPointer(funcPtr, T);
}
catch (Exception ex)
catch (Exception)
{
throw;
}
+172 -194
View File
@@ -13,182 +13,175 @@ using System.Text;
namespace StgSharp
{
// public class StgSharpDemoForm : Form
// {
// Uniform<float, float, float> color;
// ElementBuffer ebo;
// Uniform<int> ourTexture;
// Uniform<int> ourTexture2;
// Shader shader;
// Texture texture;
// VertexArray vao;
// VertexBuffer vbo;
//
// public static unsafe void ProcessInput(IntPtr windowPtr)
// {
// if (InternalIO.glfw.GetKey(windowPtr, (int)Operation.Key.ESCAPE)
// == KeyStatus.PRESS)
// {
// InternalIO.glfw.SetWindowShouldClose(windowPtr, 1);
// }
// }
//
// public override void Deinit(object[] args, IglFunc GL)
// {
// /**/
// vao.Dispose();
// vbo.Dispose();
// ebo.Dispose();
// /**/
//
// InternalIO.glfw.Terminate();
// }
//
// public unsafe void FormSizeCallback(IntPtr window, int width, int height)
// {
// GL.Viewport(0, 0, width, height);
// }
//
// public override void Init(object[] args)
// {
//
// InternalIO.InternalWriteLog("\n\n\n", "Program start", LogType.Info);
//
// Platform.InitGL(4, 6);
//
// InitForm(800, 600, "Hello, STG#!", IntPtr.Zero, null);
// MakeAsCurrentContext();
// SetSizeLimit(800, 600, 800, 600);
// GL.SetFrameBufferSizeCallback(windowID, FormSizeCallback);
//
// this.LoadGLapi(null);
//
// shader = CreateShader();
// shader.CompileVertexShader(
// File.ReadAllText("Shader\\vertex.vert")
// );
// shader.CompileFragmentShader(
// File.ReadAllText("Shader\\fragment.frag")
// );
// shader.Link();
//
// Triangle tri = new Triangle(
// -0.5f, -0.3f, 0.0f,
// 0.5f, -0.5f, 0.0f,
// 0.0f, 0.5f, 0.0f
// );
//
// Rectangle rec = new Rectangle(
// -0.5f, 0.5f, 0.0f,
// 0.5f, 0.5f, 0.0f,
// 0.5f, -0.5f, 0.0f,
// -0.5f, -0.5f, 0.0f
// );
//
// Polygon5 polygon = new Polygon5(
// -0.4f, 0.5f, 0.0f,
// 0.5f, 0.5f, 0.0f,
// 0.6f, -0.5f, 0.0f,
// 0, -1, 0,
// -0.7f, -0.5f, 0.0f
// );
//
//
// vao = new VertexArray(1);
// vbo = new VertexBuffer(2);
// ebo = new ElementBuffer(1);
// texture = CreateTexture(2);
//
//
// float[] texCoord = {
// 0.0f, 0.0f,
// 1.0f, 0.0f,
// 1.0f, 1.0f,
// 0.0f, 1.0f };
//
// GL.BindVertexArray(vao[0]);
//
// ebo.SetValue(0, rec.Indices, BufferUsage.STATIC_DRAW);
//
// vbo.SetValue(0, rec.VertexBuffer, BufferUsage.STATIC_DRAW);
// GL.SetVertexAttribute(0, 3, typeof(float), false, 4 * sizeof(float), 0);
//
// vbo.SetValueArray(1, texCoord, BufferUsage.STATIC_DRAW);
// GL.SetVertexAttribute(2, 2, typeof(float), false, 2 * sizeof(float), 0);
//
// /**/
// GL.BindBuffer(BufferType.ARRAY_BUFFER, 0);
// vao.BindNull();
// /**/
//
// texture.Bind2D(0);
// texture.Set2dWrapProperty(Wrap.Repeat, Wrap.Repeat);
// texture.Set2dFilterProperty(Filter.Nearest, Filter.Nearest);
// texture.LoadTexture(0, "Shader\\Image1.png", null);
//
// texture.Bind2D(1);
// texture.Set2dWrapProperty(Wrap.Repeat, Wrap.Repeat);
// texture.Set2dFilterProperty(Filter.Nearest, Filter.Nearest);
// texture.LoadTexture(1, "Shader\\awesomeface.png", null);
//
//
// //color = GetUniform<float, float, float>(shader, "color");
//
// shader.Use();
// /**/
// //ourTexture = GetUniform<int>(shader, "ourTexture");
// GL.SetValue(ourTexture, 0);
// //ourTexture2 = GetUniform<int>(shader, "ourTexture2");
// GL.SetValue(ourTexture2, 1);
// /**/
//
// }
//
// public override void OnRenderFrame(object[] args, IglFunc GL)
// {
// }
//
// public override void OnUpdateFrame(object[] args, IglFunc GL)
// {
//
// ProcessInput(windowID);
//
// GL.ClearColor(0.333f, 0.555f, 0.555f, 1.0f);
// //GL.api.Clear(GLconst.COLOR_BUFFER_BIT);
// GL.Clear(MaskBufferBit.COLOR);
//
// vao.Bind(0);
// shader.Use();
//
// /**/
// texture.Activate(TextureUnit.Unit0);
// texture.Bind2D(0);
// texture.Activate(TextureUnit.Unit1);
// texture.Bind2D(1);
// /**/
//
// float time = (float)InternalIO.glfw.GetTime();
// GL.SetValue(color,
// 0.5f + MathF.Sin(time),
// 0.5f + MathF.Sin(time/* + 0.667f * 3.14f/**/),
// 0.5f + MathF.Sin(time/* - 0.667f * 3.14f/**/)
// );
//
// vao.Bind(0);
//
//
// AlignFrame(this, () =>
// {
// GL.DrawElements(GepmetryType.TRIANGLES, 6, typeof(uint), IntPtr.Zero);
//
// vao.BindNull();
//
// InternalIO.glfw.SwapBuffers(windowID);
// InternalIO.glfw.PollEvents();
// });
//
// }
// }
public class StgSharpDemoForm : Form
{
Uniform<float, float, float> color;
ElementBuffer ebo;
Uniform<int> ourTexture;
Uniform<int> ourTexture2;
Shader shader;
Texture texture;
VertexArray vao;
VertexBuffer vbo;
public static unsafe void ProcessInput(IntPtr windowPtr)
{
if (InternalIO.glfw.GetKey(windowPtr, (int)Operation.Key.ESCAPE)
== KeyStatus.PRESS)
{
InternalIO.glfw.SetWindowShouldClose(windowPtr, 1);
}
}
public override void Deinit(object[] args)
{
/**/
vao.Dispose();
vbo.Dispose();
ebo.Dispose();
/**/
InternalIO.glfw.Terminate();
}
public unsafe void FormSizeCallback(IntPtr window, uint width, uint height)
{
gl.Viewport(0, 0, width, height);
}
public override void Init(object[] args)
{
InternalIO.InternalWriteLog("\n\n\n", "Program start", LogType.Info);
Platform.InitGL(4, 6);
SetRenderThreads(1);
SetMetadata(800, 600, "Hello, STG#!", IntPtr.Zero, null);
MakeAsCurrentContext();
SetSizeLimit(800, 600, 800, 600);
gl.SetFrameBufferSizeCallback(windowID, FormSizeCallback);
this.LoadGLapi(null);
shader = CreateShader();
shader.CompileVertexShader(
File.ReadAllText("Shader\\vertex.vert")
);
shader.CompileFragmentShader(
File.ReadAllText("Shader\\fragment.frag")
);
shader.Link();
Triangle tri = new Triangle(
-0.5f, -0.3f, 0.0f,
0.5f, -0.5f, 0.0f,
0.0f, 0.5f, 0.0f
);
Rectangle rec = new Rectangle(
-0.5f, 0.5f, 0.0f,
0.5f, 0.5f, 0.0f,
0.5f, -0.5f, 0.0f,
-0.5f, -0.5f, 0.0f
);
Polygon5 polygon = new Polygon5(
-0.4f, 0.5f, 0.0f,
0.5f, 0.5f, 0.0f,
0.6f, -0.5f, 0.0f,
0, -1, 0,
-0.7f, -0.5f, 0.0f
);
vao = CreateVertexArray(1);
vbo = CreateVertexBuffer(2);
ebo = CreateElementBuffer(1);
texture = CreateTexture(2);
float[] texCoord = {
0.0f, 0.0f,
1.0f, 0.0f,
1.0f, 1.0f,
0.0f, 1.0f };
gl.BindVertexArray(vao[0]);
ebo.SetValue(0, rec.Indices, BufferUsage.STATIC_DRAW);
vbo.SetValue(0, rec.VertexBuffer, BufferUsage.STATIC_DRAW);
gl.SetVertexAttribute(0, 3, typeof(float), false, 4 * sizeof(float), 0);
vbo.SetValueArray(1, texCoord, BufferUsage.STATIC_DRAW);
gl.SetVertexAttribute(2, 2, typeof(float), false, 2 * sizeof(float), 0);
/**/
gl.BindBuffer(BufferType.ARRAY_BUFFER, 0);
vao.BindNull();
/**/
texture.Bind2D(0);
texture.Set2dWrapProperty(Wrap.Repeat, Wrap.Repeat);
texture.Set2dFilterProperty(Filter.Nearest, Filter.Nearest);
texture.LoadTexture(0, "Shader\\Image1.png", null);
texture.Bind2D(1);
texture.Set2dWrapProperty(Wrap.Repeat, Wrap.Repeat);
texture.Set2dFilterProperty(Filter.Nearest, Filter.Nearest);
texture.LoadTexture(1, "Shader\\awesomeface.png", null);
//color = GetUniform<float, float, float>(shader, "color");
shader.Use();
/**/
color = shader.GetUniform<float, float, float>("color");
ourTexture = shader.GetUniform<int>("ourTexture");
gl.SetValue(ourTexture, 0);
ourTexture2 = shader.GetUniform<int>("ourTexture2");
gl.SetValue(ourTexture2, 1);
/**/
}
public override void Main(params object[] args)
{
ProcessInput(windowID);
gl.ClearColor(0.333f, 0.555f, 0.555f, 1.0f);
//GL.api.Clear(GLconst.COLOR_BUFFER_BIT);
gl.Clear(MaskBufferBit.COLOR);
vao.Bind(0);
shader.Use();
/**/
texture.Activate(TextureUnit.Unit0);
texture.Bind2D(0);
texture.Activate(TextureUnit.Unit1);
texture.Bind2D(1);
/**/
float time = (float)InternalIO.glfw.GetTime();
gl.SetValue(color,
0.5f + MathF.Sin(time),
0.5f + MathF.Sin(time/* + 0.667f * 3.14f/**/),
0.5f + MathF.Sin(time/* - 0.667f * 3.14f/**/)
);
vao.Bind(0);
gl.DrawElements(GepmetryType.TRIANGLES, 6, typeof(uint), IntPtr.Zero);
vao.BindNull();
InternalIO.glfw.SwapBuffers(windowID);
InternalIO.glfw.PollEvents();
}
}
internal static class Program
{
@@ -197,24 +190,9 @@ namespace StgSharp
{
try
{
DynamicArrayList<int> list = new DynamicArrayList<int>();
for (int i = 0; i < 100; i++)
{
list.Add(i + 1);
}
list.ShowStructure();
for (int i = 0; i < 100; i++)
{
Console.WriteLine(list[i]);
}
for (int i = 99; i >= 0; i--)
{
Console.WriteLine(list.Length);
list.RemoveAt(i);
}
Console.WriteLine(list.Length);
StgSharpDemoForm demoForm = new StgSharpDemoForm();
demoForm.Init();
demoForm.Show();
}
catch (Exception ex)
{
@@ -55,7 +55,6 @@
<ItemGroup>
<Folder Include="Entities\" />
<Folder Include="Math\" />
</ItemGroup>
<ItemGroup>
@@ -14,7 +14,7 @@ using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("StgSharpDebug")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+659420aa6c98d2cef990b65d1c5999c6968f3699")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+14eaab455f9eeb6990fa39994b2d2c8b1da39b36")]
[assembly: System.Reflection.AssemblyProductAttribute("StgSharpDebug")]
[assembly: System.Reflection.AssemblyTitleAttribute("StgSharpDebug")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
@@ -1 +1 @@
0ab12d2c59e99bed4d91307c0f5814fb6bd5b6c00fee74f06034c9eec82824d1
e0231297871b2d608de3b3cf16e3198b5d98b3105fd07342ec0a23f9d1f8c505
@@ -1 +1 @@
9e267d6382351e5a6029e566efd636dd8c97791311edd2b33766cc1dbf39e8a8
c4733ebee684f6cd7f99fafc226bf8367e01a10aced514e0e00c669239b5c71d
@@ -8,7 +8,9 @@ D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharp
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\bin\x64\Debug\net6.0\StgSharpDebug.pdb
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\bin\x64\Debug\net6.0\StgSharpDebug.xml
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\StgSharpDebug.exe
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\awesomeface.png
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\fragment.frag
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\Image1.png
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\vertex.vert
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\StgSharpDebug.deps.json
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\StgSharpDebug.runtimeconfig.json
@@ -19,10 +21,8 @@ D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharp
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.AssemblyInfoInputs.cache
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.AssemblyInfo.cs
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.csproj.CoreCompileInputs.cache
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.sourcelink.json
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.dll
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.xml
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.pdb
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.genruntimeconfig.cache
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\Image1.png
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\Output\x64\Debug\net6.0\Shader\awesomeface.png
D:\NitloadIndustry\研究项目\1-Flagship\TH2020\ProjectFile\源代码\StgSharpDebug\obj\x64\Debug\net6.0\StgSharpDebug.sourcelink.json
@@ -1 +1 @@
{"documents":{"D:\\NitloadIndustry\\研究项目\\1-Flagship\\TH2020\\ProjectFile\\*":"https://raw.githubusercontent.com/Nitload-NSI/CCD_Github/659420aa6c98d2cef990b65d1c5999c6968f3699/*"}}
{"documents":{"D:\\NitloadIndustry\\研究项目\\1-Flagship\\TH2020\\ProjectFile\\*":"https://raw.githubusercontent.com/Nitload-NSI/CCD_Github/14eaab455f9eeb6990fa39994b2d2c8b1da39b36/*"}}
@@ -16,7 +16,7 @@
<summary>
Function handler to load an opengl function by serching its name.
</summary>
<param name="funcname">the name of the Opengl function</param>
<param name="name">the name of the Opengl function</param>
<returns>An intptr value representing the pointer to the function</returns>
</member>
<member name="T:StgSharp.Graphics.Form">
@@ -29,6 +29,11 @@
Height of this form, represent in <see cref="T:System.Int32"/>
</summary>
</member>
<member name="P:StgSharp.Graphics.Form.GL">
<summary>
OpenGL package used by current form context.
</summary>
</member>
<member name="P:StgSharp.Graphics.Form.IsDoubleRendering">
<summary>
Representing
@@ -39,6 +44,11 @@
Width of this form, represent in <see cref="T:System.Int32"/>
</summary>
</member>
<member name="P:StgSharp.Graphics.Form.Width">
<summary>
Width of this form, represent in <see cref="T:System.Int32"/>
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.Init(System.Object[])">
<summary>
Necessary operation to init this form.
@@ -57,19 +67,17 @@
Init this form and render it on screen, and respond with operation
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.SetRenderThreads(System.Boolean)">
<member name="M:StgSharp.Graphics.Form.SetRenderThreads(System.Int32)">
<summary>
Define how current form render in one frame.
</summary>
<param name="totalThread">
Please define
<param name="requireDoubleRendering">
Please define this befor calling any OpenGL api and other graphic methods.
</param>
</member>
<member name="M:StgSharp.Graphics.Form.InitForm(System.Int32,System.Int32,System.String,System.IntPtr,StgSharp.Graphics.Form)">
<member name="M:StgSharp.Graphics.Form.SetMetadata(System.Int32,System.Int32,System.String,System.IntPtr,StgSharp.Graphics.Form)">
<summary>
Constructor of a Form, creats an instance of a form and
initilize all the customizing operations.
Set all necessary metadata to current form instance
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.MakeAsCurrentContext">
@@ -115,59 +123,32 @@
Maximum size of current form. In form of a <see cref="T:StgSharp.Math.Vec2d"/> of (width,height)
</param>
</member>
<member name="M:StgSharp.Graphics.Form.Texture.LoadTexture(System.Int32,System.String,StgSharp.Graphics.ImageLoader)">
<member name="M:StgSharp.Graphics.Form.CreateElementBuffer(System.UInt32)">
<summary>
Create a set of <see cref="T:StgSharp.Graphics.ElementBuffer"/>.
</summary>
<param name="name"></param>
<param name="index"></param>
<param name="loader"></param>
<param name="count">Amount of EBO to be created.</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.Form.CreateVertexArray(System.UInt32)">
<summary>
Create a set of <see cref="T:StgSharp.Graphics.VertexArray"/>.
</summary>
<param name="count">Amount of VAO to be crated.</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.Form.CreateVertexBuffer(System.UInt32)">
<summary>
Create aset of <see cref="T:StgSharp.Graphics.VertexBuffer"/>.
</summary>
<param name="count">Amount of Object to be created.</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.Form.CreateShader">
<summary>
Create an instance of <see cref="T:StgSharp.Graphics.Form.Shader"/> program
</summary>
<returns>New instance of <see cref="T:StgSharp.Graphics.Form.Shader"/> instance. </returns>
</member>
<member name="F:StgSharp.Graphics.Form.Shader.programID">
<summary>
A <see cref="T:System.UInt32"/> value represent this shader.
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.#ctor(StgSharp.Graphics.IglFunc)">
<summary>
Inti a shader with no program attached.
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.CompileVertexShader(System.String)">
<summary>
Compile the vertex shader to be attached to this shader.
</summary>
<param name="shaderCode">GLSL code of vertex shader.</param>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.CompileFragmentShader(System.String)">
<summary>
Compile the fragment shader to be attached to this shader.
</summary>
<param name="shaderCode">GLSL code of fragment shader.</param>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.Link">
<summary>
Link the shader to current context.
</summary>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.GetUniform``1(System.String)">
<summary>
Get a uniform form current shader,
the value type of the uniform should be provided.
</summary>
<param name="name"></param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.Form.Shader.Use">
<summary>
Let the current context use this shader.
Create an instance of <see cref="T:StgSharp.Graphics.Shader"/> program
</summary>
<returns>New instance of <see cref="T:StgSharp.Graphics.Shader"/> instance. </returns>
</member>
<member name="T:StgSharp.Graphics.FrameTimer">
<summary>
@@ -186,11 +167,39 @@
</summary>
<param name="timer"><see cref="T:StgSharp.Graphics.FrameTimer"/> to be converted</param>
</member>
<member name="T:StgSharp.Graphics.ElementBuffer">
<summary>
A collecion of handle to Element Buffer Object in OpenGL.
Each <see cref="T:System.UInt32"/> value indexed from instance of this class this
is the only handle to one Element Buffer Object.
</summary>
</member>
<member name="T:StgSharp.Graphics.IBufferObject">
<summary>
Interface of all kinds OpenGL buffer onjects
</summary>
</member>
<member name="P:StgSharp.Graphics.IBufferObject.Item(System.Int32)">
<summary>
Get the only handle to one of the Object instance
</summary>
<param name="index"></param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.IBufferObject.Bind(System.Int32)">
<summary>
Bind a buffer instance to OpenGL
</summary>
<param name="index">Index of handle of the object in this instance to be bind</param>
</member>
<member name="M:StgSharp.Graphics.Texture.LoadTexture(System.Int32,System.String,StgSharp.Graphics.ImageLoader)">
<summary>
</summary>
<param name="name"></param>
<param name="index"></param>
<param name="loader"></param>
</member>
<member name="M:StgSharp.Graphics.VertexBuffer.Unbind">
<summary>
@@ -228,77 +237,67 @@
<param name="name">Name of the OpenGL api</param>
<returns>The funtion pointer of the api in form of <see cref="T:System.IntPtr"/></returns>
</member>
<member name="M:StgSharp.Graphics.GLonRender.StgSharp#Graphics#IglFunc#SetValue(StgSharp.Graphics.Uniform{System.Single},System.Single)">
<member name="F:StgSharp.Graphics.Shader.programID">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are float.
A <see cref="T:System.UInt32"/> value represent this shader.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="v0">The value to be set</param>
</member>
<member name="M:StgSharp.Graphics.GLonRender.StgSharp#Graphics#IglFunc#SetValue(StgSharp.Graphics.Uniform{System.Int32},System.Int32)">
<member name="M:StgSharp.Graphics.Shader.#ctor(StgSharp.Graphics.IglFunc)">
<summary>
Set data value to a int <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are int.
Inti a shader with no program attached.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="i0">The value to be set</param>
</member>
<member name="M:StgSharp.Graphics.GLonRender.StgSharp#Graphics#IglFunc#SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single},System.Single,System.Single)">
<member name="M:StgSharp.Graphics.Shader.CompileVertexShader(System.String)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`2"/>,
all types of parameters are float.
Compile the vertex shader to be attached to this shader.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`2"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
<param name="shaderCode">GLSL code of vertex shader.</param>
</member>
<member name="M:StgSharp.Graphics.GLonRender.StgSharp#Graphics#IglFunc#SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single},System.Single,System.Single,System.Single)">
<member name="M:StgSharp.Graphics.Shader.CompileFragmentShader(System.String)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`3"/>,
all types of parameters are float.
Compile the fragment shader to be attached to this shader.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`3"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
<param name="v2">The third value to be set</param>
<param name="shaderCode">GLSL code of fragment shader.</param>
</member>
<member name="M:StgSharp.Graphics.GLonRender.StgSharp#Graphics#IglFunc#SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single,System.Single},System.Single,System.Single,System.Single,System.Single)">
<member name="M:StgSharp.Graphics.Shader.Link">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`4"/>,
all types of parameters are float.
Link the shader to current context.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`4"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
<param name="v2">The third value to be set</param>
<param name="v3">The forth value to be set</param>
</member>
<member name="M:StgSharp.Graphics.GLonRender.SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single,System.Single},StgSharp.Math.Vec4d)">
<member name="M:StgSharp.Graphics.Shader.GetUniform``1(System.String)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`4"/>,
all types of parameters are float.
Get a uniform form current shader,
the value type of the uniform should be provided.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`4"/> target</param>
<param name="vec">A <see cref="T:StgSharp.Math.Vec4d"/> packing four parameters of the uniform </param>
<param name="name">Name of the Uniform in shader code</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.GLonRender.SetValue(StgSharp.Graphics.Uniform{StgSharp.Math.Vec4d},StgSharp.Math.Vec4d)">
<member name="M:StgSharp.Graphics.Shader.GetUniform``2(System.String)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are <see cref="T:StgSharp.Math.Vec4d"/>.
Get a uniform form current shader,
the value type of the uniform should be provided.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="vec">A <see cref="T:StgSharp.Math.Vec4d"/> value of the uniform </param>
<param name="name">Name of the Uniform in shader code</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.IglFunc.AlignFrame(StgSharp.Graphics.Form)">
<member name="M:StgSharp.Graphics.Shader.GetUniform``3(System.String)">
<summary>
Align a sets of code to frame update of a <see cref="T:StgSharp.Graphics.Form"/>.
Usually, a call of <see cref="M:StgSharp.Graphics.IglFunc.AfterAlign(StgSharp.Graphics.Form,System.Action)"/> is required.
This method is used as sigle thread method. If more than one
alignment is requested, a <see cref="T:System.InvalidOperationException"/> will throw.
Get a uniform form current shader,
the value type of the uniform should be provided.
</summary>
<param name="form">The form used as frame update benchmark.</param>
<exception cref="T:System.InvalidOperationException">More than one alingment attached to one form timer</exception>
<param name="name">Name of the Uniform in shader code</param>
<returns></returns>
</member>
<member name="M:StgSharp.Graphics.Shader.Use">
<summary>
Let the current context use this shader.
</summary>
</member>
<member name="M:StgSharp.Graphics.IglFunc.ActiveTexture(System.UInt32)">
<summary>
Same function as OpenGL api glActiveTexture
</summary>
<param name="type">type of texture to activate</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.AfterAlign(StgSharp.Graphics.Form,System.Action)">
<summary>
@@ -312,11 +311,15 @@
<param name="action">Operation after frame update alignment.</param>
<exception cref="T:System.InvalidOperationException">The action binded to a wrong alignment.</exception>
</member>
<member name="M:StgSharp.Graphics.IglFunc.ActiveTexture(System.UInt32)">
<member name="M:StgSharp.Graphics.IglFunc.AlignFrame(StgSharp.Graphics.Form)">
<summary>
Same function as OpenGL api glActiveTexture
Align a sets of code to frame update of a <see cref="T:StgSharp.Graphics.Form"/>.
Usually, a call of <see cref="M:StgSharp.Graphics.IglFunc.AfterAlign(StgSharp.Graphics.Form,System.Action)"/> is required.
This method is used as sigle thread method. If more than one
alignment is requested, a <see cref="T:System.InvalidOperationException"/> will throw.
</summary>
<param name="type">type of texture to activate</param>
<param name="form">The form used as frame update benchmark.</param>
<exception cref="T:System.InvalidOperationException">More than one alingment attached to one form timer</exception>
</member>
<member name="M:StgSharp.Graphics.IglFunc.AttachShader(System.UInt32,System.UInt32)">
<summary>
@@ -381,43 +384,49 @@
<summary>
Creates a form and its associated
</summary>
<param name="handle">The instance of created form</param>
<param name="width">Required width</param>
<param name="height">Required width</param>
<param name="tittle">Tittle of the window </param>
<param name="monitor"></param>
<param name="share"></param>
<returns>The instance of created form</returns>
<exception cref="T:System.Exception"></exception>
</member>
<member name="M:StgSharp.Graphics.IglFunc.DeleteBuffers(System.Int32,System.UInt32*)">
<member name="M:StgSharp.Graphics.IglFunc.DeleteBuffer(System.UInt32)">
<summary>
Same function as OpenGL api, glDeleteBuffer.
Same function as OpenGL api, glDeleteBuffer. This method can delete one buffer in one call
</summary>
<param name="handle">a handle representing the buffer to be deleted</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.DeleteBuffers(System.UInt32,System.UInt32[])">
<summary>
Same function as OpenGL api, glDeleteBuffer. This method can delete a sets of buffers in one call.
</summary>
<param name="count">Amount of bufferd to be deleted</param>
<param name="ptr">Pointer of buffer to be deleted</param>
<param name="handle">Array of buffers to be deleted</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.DeleteVertexArrays(System.Int32,System.UInt32*)">
<member name="M:StgSharp.Graphics.IglFunc.DeleteVertexArrays(System.UInt32,System.UInt32[])">
<summary>
Same function as OpenGL api, glDeleteVertexArrays
</summary>
<param name="count">Amount of vao to be deleted</param>
<param name="ptr">pointer of vao sign array</param>
<param name="arrays">A array representing a colletion of vertex objects.</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.GenBuffers(System.Int32,System.UInt32*)">
<member name="M:StgSharp.Graphics.IglFunc.GenBuffers(System.UInt32,System.UInt32*)">
<summary>
Same fucntion as the OpenGL api glGenBuffers
</summary>
<param name="count"></param>
<param name="ptr"></param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.GenTextures(System.Int32,System.UInt32*)">
<member name="M:StgSharp.Graphics.IglFunc.GenTextures(System.UInt32,System.UInt32*)">
<summary>
Same fucnction as OpenGL api glGenTextures.
</summary>
<param name="count">amount of textures to generate</param>
<param name="ptr">pointer to texture signs' array</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.GenVertexArrays(System.Int32,System.UInt32*)">
<member name="M:StgSharp.Graphics.IglFunc.GenVertexArrays(System.UInt32,System.UInt32*)">
<summary>
Same fucntion as OpenGL api, glGenVertexArray
</summary>
@@ -446,7 +455,69 @@
<param name="id">The only signiture stands for the <see cref="T:StgSharp.Graphics.Form"/> to be controlled</param>
<param name="handler">Method hadler </param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetVertexAttribute(System.UInt32,System.Int32,System.Type,System.Boolean,System.Int32,System.Int32)">
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single,System.Single},System.Single,System.Single,System.Single,System.Single)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`4"/>,
all types of parameters are float.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`4"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
<param name="v2">The third value to be set</param>
<param name="v3">The forth value to be set</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single,System.Single},StgSharp.Math.Vec4d)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`4"/>,
all types of parameters are float.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`4"/> target</param>
<param name="vec">A <see cref="T:StgSharp.Math.Vec4d"/> packing four parameters of the uniform </param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single,System.Single},System.Single,System.Single,System.Single)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`3"/>,
all types of parameters are float.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`3"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
<param name="v2">The third value to be set</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Single,System.Single},System.Single,System.Single)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`2"/>,
all types of parameters are float.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`2"/> target</param>
<param name="v0">The first value to be set</param>
<param name="v1">The second value to be set</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Single},System.Single)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are float.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="v0">The value to be set</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{System.Int32},System.Int32)">
<summary>
Set data value to a int <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are int.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="i0">The value to be set</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetValue(StgSharp.Graphics.Uniform{StgSharp.Math.Vec4d},StgSharp.Math.Vec4d)">
<summary>
Set data value to a float <see cref="T:StgSharp.Graphics.Uniform`1"/>,
all types of parameters are <see cref="T:StgSharp.Math.Vec4d"/>.
</summary>
<param name="uniform">The <see cref="T:StgSharp.Graphics.Uniform`1"/> target</param>
<param name="vec">A <see cref="T:StgSharp.Math.Vec4d"/> value of the uniform </param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.SetVertexAttribute(System.UInt32,System.Int32,System.Type,System.Boolean,System.UInt32,System.Int32)">
<summary>
Set how a shader parameter read data from a VBO.
</summary>
@@ -457,7 +528,7 @@
<param name="stride">Pixels stride of each sets of data</param>
<param name="pointer"></param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.TextureImage2d(System.UInt32,System.Int32,System.UInt32,System.Int32,System.Int32,System.UInt32,System.UInt32,System.Void*)">
<member name="M:StgSharp.Graphics.IglFunc.TextureImage2d(System.UInt32,System.Int32,System.UInt32,System.UInt32,System.UInt32,System.UInt32,System.UInt32,System.Void*)">
<summary>
Same function as OpenGL api glTexImage2d
</summary>
@@ -484,7 +555,7 @@
</summary>
<param name="program">Sign of program to be used</param>
</member>
<member name="M:StgSharp.Graphics.IglFunc.Viewport(System.Int32,System.Int32,System.Int32,System.Int32)">
<member name="M:StgSharp.Graphics.IglFunc.Viewport(System.Int32,System.Int32,System.UInt32,System.UInt32)">
<summary>
Same function as the OpenGL api, glViewPort
</summary>
@@ -662,6 +733,7 @@
</summary>
<param name="count">Amount of elements to be prepared.</param>
</member>
<!-- Badly formed XML comment ignored for member "M:StgSharp.Logic.DynamicArrayList`1.#ctor(System.Int32,`0)" -->
<member name="P:StgSharp.Logic.DynamicArrayList`1.Length">
<summary>
Length of this <see cref="T:StgSharp.Logic.DynamicArrayList`1"/>
@@ -741,6 +813,18 @@
remove the last member of the list
</summary>
</member>
<member name="T:StgSharp.Math.GLclampf">
<summary>
OpenGL numeric type.
An IEEE-754 floating-point value, clamped to the range [0,1].
</summary>
</member>
<member name="T:StgSharp.Math.GLclampd">
<summary>
OpenGL numeric type.
An IEEE-754 double precision floating-point value, clamped to the range [0,1].
</summary>
</member>
<member name="T:StgSharp.Math.Vec2d">
<summary>
A two dimension vector defined by two elements.