diff --git a/CHANGELOG b/CHANGELOG index bffb748e..d3396f5f 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,4 +1,13 @@ -Upcoming: +v0.7.0: + * Added missing functionality in: + - GL.Objects.Buffers (glBindBufferBase, glDrawElementsInstanced, + texture buffer target) + - GL.Objects.Programs (transform feedback) + * Fixed memory leaks during C-string handling. + * Deprecated old GL.Attributes.Set_Vertex_Attrib_Pointer in favor for + new subroutines there that provide more control. + * Small fixes in tests so that they work on Windows again. + * Made it work with GNAT Community 2018. * Changed to SemVer versioning (added revision number) * Improvements to GL.Object system * Fixed problems in uniforms setter (#105) diff --git a/README.md b/README.md index 7c5e4504..fe3c3747 100644 --- a/README.md +++ b/README.md @@ -36,12 +36,18 @@ bindings to the following OpenGL-related libraries: OpenGLAda supports MacOSX, Windows and X11-based systems. API documentation can be found on the [project's homepage][4]. +## Windows Installer + +There is an installer available for Windows + GNAT Community in the +[repository's *releases* section][21] which includes all optional dependencies +except FTGL (because that binding is deprecated). + ## Prerequisites In order to build OpenGLAda, you need to have: * A GNAT compiler¹. Compilers known to work well with OpenGLAda are - [GnuAda][12], [AdaCore GNAT GPL 2017][1], and [TDM-GCC][17]. More information + [GnuAda][12], [GNAT Community 2018][1], and [TDM-GCC][17]. More information is available on the [GCC website][5]. * [GPRBuild][2] (is bundled with AdaCore's GNAT distribution). TDM-GCC users can get it from [here][16] (**NOTE: The gprbuild bundled in this zip is @@ -68,8 +74,8 @@ To install OpenGLAda with all optional libraries, execute $ gprbuild [options] openglada.gpr $ gprinstall [options] openglada.gpr -Where *[options]* is the set of scenario variables you want to use. The -available variables are: +Where *[options]* is the set of scenario variables you want to use (generally +in the form of `-X`*name*`=`*value*`). The available variables are: * `Windowing_System`: Sets the backend windowing system. Used for GLFW and also for system-dependent parts of the API (GLX, WGL, CGL): @@ -197,4 +203,5 @@ logo that is used in the SOIL tests is distributed under the terms of the [16]: http://getadanow.com/#get_windows [17]: http://tdm-gcc.tdragon.net/ [19]: https://freetype.org/ - [20]: https://github.com/flyx/FreeTypeAda \ No newline at end of file + [20]: https://github.com/flyx/FreeTypeAda + [21]: https://github.com/flyx/OpenGLAda/releases \ No newline at end of file diff --git a/install/OpenGLAda.wix b/install/OpenGLAda.wix index 46570673..bad416a2 100644 --- a/install/OpenGLAda.wix +++ b/install/OpenGLAda.wix @@ -9,7 +9,7 @@ InstallerVersion="100" Languages="1033" Compressed="yes" SummaryCodepage="1252" /> - + diff --git a/src/generator/specs.adb b/src/generator/specs.adb index a8a354e1..014d3dd8 100644 --- a/src/generator/specs.adb +++ b/src/generator/specs.adb @@ -675,7 +675,6 @@ package body Specs is Put_Line (Target, "private with " & To_String (Spec_Data.Name) & ";"); end loop; Put_Line (Target, "procedure GL.Load_Function_Pointers is"); - Put_Line (Target, " pragma Preelaborate;"); Put_Line (Target, " use GL.API;"); Put_Line (Target, " generic"); Put_Line (Target, " type Function_Reference is private;"); @@ -824,4 +823,4 @@ package body Specs is end loop; Close (Target); end Write_Wrapper_Table; -end Specs; \ No newline at end of file +end Specs; diff --git a/src/gl/generated/gl-load_function_pointers.adb b/src/gl/generated/gl-load_function_pointers.adb index b0162a72..8215b245 100644 --- a/src/gl/generated/gl-load_function_pointers.adb +++ b/src/gl/generated/gl-load_function_pointers.adb @@ -9,7 +9,6 @@ private with GL.API.Singles; private with GL.API.UInts; private with GL.API; procedure GL.Load_Function_Pointers is - pragma Preelaborate; use GL.API; generic type Function_Reference is private; diff --git a/src/gl/implementation/gl-api-subprogram_reference.ads b/src/gl/implementation/gl-api-subprogram_reference.ads index 64045981..9b126357 100644 --- a/src/gl/implementation/gl-api-subprogram_reference.ads +++ b/src/gl/implementation/gl-api-subprogram_reference.ads @@ -3,4 +3,4 @@ function GL.API.Subprogram_Reference (Function_Name : String) return System.Address; -pragma Preelaborate (GL.API.Subprogram_Reference); \ No newline at end of file +pragma Preelaborate (GL.API.Subprogram_Reference); diff --git a/src/gl/implementation/gl-load_function_pointers.ads b/src/gl/implementation/gl-load_function_pointers.ads new file mode 100644 index 00000000..e5ad93fb --- /dev/null +++ b/src/gl/implementation/gl-load_function_pointers.ads @@ -0,0 +1,5 @@ +-- part of OpenGLAda, (c) 2017 Felix Krause +-- released under the terms of the MIT license, see the file "COPYING" + +procedure GL.Load_Function_Pointers; +pragma Preelaborate (GL.Load_Function_Pointers); diff --git a/tests/gl/gl_test-framebuffers.adb b/tests/gl/gl_test-framebuffers.adb index e3e1af82..2551b633 100644 --- a/tests/gl/gl_test-framebuffers.adb +++ b/tests/gl/gl_test-framebuffers.adb @@ -107,6 +107,7 @@ begin Display_Backend.Window_Opened loop Clear (Buffer_Bits'(others => True)); + GL.Objects.Textures.Set_Active_Unit (0); GL.Toggles.Enable (GL.Toggles.Texture_2D); -- don't let the color affect the texture rendering @@ -125,6 +126,8 @@ begin Token.Add_Vertex (Vector2'(-1.0, 1.0)); end; + GL.Toggles.Disable (GL.Toggles.Texture_2D); + GL.Flush; Display_Backend.Swap_Buffers;