Commit graph

547 commits

Author SHA1 Message Date
Stefanos A ac65eb7b09 Added MonoDevelop artifacts 2013-11-27 00:05:26 +01:00
Stefanos A 82b0b477da Emit native signatures
The patcher uses those signatures to implement wrapper functionality
for the various wrapper types that exist in OpenTK.
2013-11-27 00:02:26 +01:00
Stefanos A 4149cdfa88 Do not emit method bodies. 2013-11-26 01:31:29 +01:00
Stefanos A. 84a1e5a739 Initial work on Pin<> statements (WIP) 2013-11-25 20:00:22 +01:00
Stefanos A. c8e753d2da Moved address parameter to last place
This way, it is the last item on the evaluation stack before calling the
unmanaged function pointer. This simplifies the calli rewrite procedure.
2013-11-25 00:18:43 +01:00
Stefanos A. 2045f3e98e Add slots into entry point table 2013-11-24 13:55:13 +01:00
Stefanos A. 7b93a87bb0 Generate entry point tables 2013-11-24 13:54:52 +01:00
Stefanos A 8ee2152709 Moved delegate loaders to the Delegates class 2013-11-23 17:23:26 +01:00
Stefanos A 0fea0a19b7 Added support for lazy binding loading 2013-11-22 20:06:49 +01:00
Stefanos A 2ace001203 Implemented direct binding loading
OpenTK normally uses reflection to load bindings, instead of generating
huge constructors. Although reflection is faster on first load (thanks
to reduced JIT overhead), it fails to work correctly with monolinker.
This branch explores the performance of a direct binding.
2013-11-22 17:32:17 +01:00
Stefanos A 02120f429f Do not trim 's' from Groups 2013-11-20 08:16:06 +01:00
Stefanos A 635bb85313 Reverted 'h' suffix detection
This causes too many breaking changes in the NV namespace.
2013-11-18 18:32:36 +01:00
Stefanos A ac0fab7760 More compatibility overloads for OpenGL 2013-11-18 18:32:36 +01:00
Stefanos A 5d4c42672f Improved suffix detection. Support index-based parameter overloading. 2013-11-18 18:32:34 +01:00
Stefanos A 3d50554903 Added OpenGL overloads for OpenTK-1.0 compatibility 2013-11-18 13:28:44 +01:00
Stefanos A e572f418af Added compatibility overloads for ES 2.0 2013-11-18 01:10:01 +01:00
Stefanos A 0865b0f200 Allow overriding of function names 2013-11-17 23:56:51 +01:00
Stefanos A fbcae3b2fe Removed debugging code 2013-11-17 21:27:22 +01:00
Stefanos A b652145977 Handle overloads with different element counts 2013-11-17 21:27:09 +01:00
Stefanos A c175a486fc Improved and documented IEquatable vs IComparable 2013-11-17 21:26:28 +01:00
Stefanos A 13d3bdb47f OpenGL overrides for compatibility
Added overrides to maintain backwards compatibility with
OpenTK.Graphics.OpenGL.GL. These were generated
through the apitest tool.
2013-11-17 01:49:07 +01:00
Stefanos A f8a81f396e Cleaned up ending trim regex
Trim regex will now correctly match GetInteger64 and other functions
ending in "64". It also uses a correct ending anchor to avoid matches
in the middle of a function name.
2013-11-17 01:49:07 +01:00
Stefanos A fd910e6a6c Added int/uint to the c# typemap 2013-11-17 01:49:07 +01:00
Stefanos A afd076a83d Speed up enum code generator
Scan through the list of wrappers once, instead of multiple times, in
order to find out which functions use which enums. This speeds up enum
generation tremendously.
2013-11-17 01:49:07 +01:00
Stefanos A f9deeaead7 Improved compatibility with OpenTK 1.0
Added overloads for enumerations with name changes. Reduced differences
between ES and GL APIs.
2013-11-15 01:59:50 +01:00
Stefanos A cdd6259fee Removed debug leftovers 2013-11-14 23:38:17 +01:00
Stefanos A 431202d830 Corrected convenience wrappers for Get* and Delete*
GetBoolean, GetInteger6, GetFixedvOES and Delete* are now matched in
the convenience wrapper generator. Methods returning vectors of fixed
size (e.g. 4 ints) are no longer matched.
2013-11-14 17:40:06 +01:00
Stefanos A 2e14ca59b2 AMD_performance_monitors is not const-correct
Workaround fo  bug in rhe specification of AMD_performance_monitors.
Upstream bug report here:
https://www.khronos.org/bugzilla/show_bug.cgi?id=1035
2013-11-14 16:17:20 +01:00
Stefanos A 4fd6347de7 Mark untyped overloads as obsolete 2013-11-14 14:10:19 +01:00
Stefanos A 11070bb52a Added support for obsolete attribute
Functions marked with the obsolete attribute will now add [Obsolete] to
the generated output.
2013-11-14 13:46:42 +01:00
Stefanos A 5b4d3edf39 ES11 compatibility overloads (WIP1) 2013-11-14 11:34:46 +01:00
Stefanos A c5591e9968 Clear qualifier path when changing type
This fixes a bug where overriding an enum parameter with a non-enum
parameter would result in the wrong qualifier path.
2013-11-14 11:33:52 +01:00
Stefanos A ce7a7c7cf3 New Add() methods analogous to FunctionCollection 2013-11-14 11:32:25 +01:00
Stefanos A 5f7008d746 Improved override/overload lookup
The lookup for function overrides and overloads now tries to work
around extension case mismatches (e.g. IBM vs Ibm). This fixes a few
specific cases of missing overrides.
2013-11-14 11:31:36 +01:00
Stefanos A d28c428e99 Correctly set generator mode. 2013-11-14 09:28:27 +01:00
Stefanos A. 4fd5cc30d5 Corrected option parsing 2013-11-13 14:29:06 +01:00
thefiddler 1792f7bf29 Added Version20 overload to StencilFuncSeparate
Compatibility fix for OpenTK 1.0
2013-11-12 23:39:43 +01:00
thefiddler 4f6c2ac2b4 Support multiple overloads
It is now possible to specify multiple overloads for the same function.
This is helpful for maintaining backwards compatibility with previous
releases.
2013-11-12 23:38:09 +01:00
thefiddler 8360b7a2ba Generate overloads without strong enums for 1.0 compat
OpenTK 1.0 and Xamarin Android/iOS do not use strongly-typed enums for
OpenGL ES. Generate overloads with the "All" enum in order to maintain
compatibility.
2013-11-11 10:03:24 +01:00
thefiddler 4d717dcdda Allow '+' and '-' cmdline options for compatibility settings 2013-11-11 10:02:08 +01:00
thefiddler 8e9a9355b0 Allow overriding of Settings.Compatibility 2013-11-11 10:01:30 +01:00
thefiddler 0fcf3a2f40 Minor code cleanup 2013-11-11 10:01:15 +01:00
thefiddler af16be42d5 Corrected Parameter.IsEnum property 2013-11-11 10:00:54 +01:00
thefiddler dde7c645c4 Removed unused code 2013-11-11 10:00:32 +01:00
Stefanos A. d0e025b86d Restrict convenience overloads
Only Get*, Gen*, Delete* and New* functions get convenience overloads.
This avoids issues with functions such as Rect() that have similar
signatures but cannot use such overloads.

This restriction will be relaxed in the future.
2013-11-10 19:03:49 +01:00
Stefanos A. 293c020151 Added WrapperTypes.ConvenienceArrayType
These are convenience parameters for function receiving a size and an
array parameter, like DeleteTextures(int n, int[] ids). The generator
will now add overloads taking a single parameter, such as
DeleteTexture(int id).
2013-11-10 18:29:53 +01:00
Stefanos A. af7fdea449 Return types must be cls-compliant
CreateCLSCompliantWrappers must always change return types into
cls-compliant types. The reason is that we cannot overload on return
type alone, so we should always choose the compliant version.
2013-11-10 15:35:47 +01:00
Stefanos A. 6098fa05ce Plural name to singular in convenience overloads 2013-11-10 10:16:47 +01:00
Stefanos A. 11c1071625 Corrected declarations in convenience overloads 2013-11-10 10:08:04 +01:00
Stefanos A. 089c108ea0 Corrected indentation 2013-11-10 09:20:54 +01:00