opengl-bindings 1.6.13 → 1.6.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ChangeLog +20 -0
- data/LICENSE.txt +1 -1
- data/README.md +95 -40
- data/lib/glfw.rb +73 -18
- data/lib/glfw33.rb +716 -0
- data/lib/glu.rb +1 -1
- data/lib/glut.rb +1 -1
- data/lib/opengl.rb +1 -1
- data/lib/opengl_common.rb +1 -1
- data/lib/opengl_es.rb +1 -1
- data/lib/opengl_es_ext.rb +1 -1
- data/lib/opengl_es_ext_command.rb +209 -9
- data/lib/opengl_es_ext_enum.rb +100 -9
- data/lib/opengl_ext.rb +1 -1
- data/lib/opengl_ext_command.rb +116 -69
- data/lib/opengl_ext_enum.rb +27 -9
- data/sample/glfw_build.bat +12 -9
- data/sample/glfw_build.sh +3 -3
- metadata +20 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fe04e11bb81eb11d48c6d16731b8d759668fb1260f0d7a6d4fd9fcf58afc5cd4
|
4
|
+
data.tar.gz: c466a60d4176b2be705f2f15bdd4d203316fc160586e4613edcc384b34e72516
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed806ca800e516018b89afb66a77d7589b426f93f68026e350f4e589cbe9f3783cf72f0b0476ebb3b2f3dfaa092fc9283fde14700839a2717dcb5cdf1240d810
|
7
|
+
data.tar.gz: 8be4cf96175bd0cba6e1e916c1446d89fb07439ee059114614f38663851e8e90fc436bb4fe234f6b268531714ba181927aa23c13591cf5e4fd2224d2ee61e9c4
|
data/ChangeLog
CHANGED
@@ -1,3 +1,23 @@
|
|
1
|
+
2025-01-01 vaiorabbit <http://twitter.com/vaiorabbit>
|
2
|
+
|
3
|
+
* glfw.rb: Fixed warnings
|
4
|
+
|
5
|
+
2024-02-25 vaiorabbit <http://twitter.com/vaiorabbit>
|
6
|
+
|
7
|
+
* GLFW 3.4
|
8
|
+
|
9
|
+
2024-01-05 vaiorabbit <http://twitter.com/vaiorabbit>
|
10
|
+
|
11
|
+
* Updated using latest gl.xml
|
12
|
+
|
13
|
+
2023-12-16 vaiorabbit <http://twitter.com/vaiorabbit>
|
14
|
+
|
15
|
+
* GLFW 3.3.9
|
16
|
+
|
17
|
+
2023-11-11 vaiorabbit <http://twitter.com/vaiorabbit>
|
18
|
+
|
19
|
+
* Updated using latest gl.xml
|
20
|
+
|
1
21
|
2022-12-10 vaiorabbit <http://twitter.com/vaiorabbit>
|
2
22
|
|
3
23
|
* Updated gl.xml.
|
data/LICENSE.txt
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
Ruby-OpenGL : Yet another OpenGL wrapper for Ruby (and wrapper code generator)
|
2
|
-
Copyright (c) 2013-
|
2
|
+
Copyright (c) 2013-2025 vaiorabbit <http://twitter.com/vaiorabbit>
|
3
3
|
|
4
4
|
This software is provided 'as-is', without any express or implied
|
5
5
|
warranty. In no event will the authors be held liable for any damages
|
data/README.md
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
...and wrapper code generator.
|
6
6
|
|
7
7
|
* Created : 2013-08-28
|
8
|
-
* Last modified :
|
8
|
+
* Last modified : 2025-01-01
|
9
9
|
|
10
10
|
---
|
11
11
|
|
@@ -73,7 +73,7 @@ module GL
|
|
73
73
|
|
74
74
|
<img src="https://raw.githubusercontent.com/vaiorabbit/ruby-opengl/master/doc/simple_rb.jpg" width="200"> <img src="https://raw.githubusercontent.com/vaiorabbit/ruby-opengl/master/doc/nehe_lesson36_rb.jpg" width="200"> <img src="https://raw.githubusercontent.com/vaiorabbit/ruby-opengl/master/doc/brick_rb.jpg" width="200"> <img src="https://raw.githubusercontent.com/vaiorabbit/ruby-opengl/master/doc/glxs_rb.jpg" width="200">
|
75
75
|
|
76
|
-
* Uses Fiddle (One of the Ruby
|
76
|
+
* Uses Fiddle (One of the Ruby libraries that wraps libffi)
|
77
77
|
* Unlike opengl ( https://rubygems.org/gems/opengl ), you don't need to build C extension library
|
78
78
|
|
79
79
|
* Uses Khronos XML API registry ( https://github.com/KhronosGroup/OpenGL-Registry )
|
@@ -148,7 +148,6 @@ https://github.com/vaiorabbit/ruby-opengl
|
|
148
148
|
|
149
149
|
* Fiddle
|
150
150
|
* A libffi wrapper
|
151
|
-
* Standard library since Ruby 2.0.0
|
152
151
|
* I recommend you to use Ruby 2.1.2 and later, which fixed Fiddle's memory leak issue (https://bugs.ruby-lang.org/issues/9599).
|
153
152
|
|
154
153
|
### For sample ###
|
@@ -167,27 +166,24 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
167
166
|
## Tested Environment ##
|
168
167
|
|
169
168
|
* Ruby
|
170
|
-
* ruby 3.
|
169
|
+
* ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [x64-mingw-ucrt]
|
170
|
+
* ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [arm64-darwin24]
|
171
171
|
|
172
|
-
* Windows
|
173
|
-
* NVIDIA GeForce RTX 2060 SUPER
|
174
|
-
* OpenGL 4.5
|
172
|
+
* Windows 11 Pro (Version 24H2, OS Build 26100.2605)
|
175
173
|
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
174
|
+
> ruby report_env.rb
|
175
|
+
Version : 4.5.0 NVIDIA 560.94
|
176
|
+
Vendor : NVIDIA Corporation
|
177
|
+
Renderer : NVIDIA GeForce RTX 4080 Laptop GPU/PCIe/SSE2
|
178
|
+
Shader : 4.50 NVIDIA
|
181
179
|
|
182
|
-
* macOS
|
183
|
-
* Mac mini (M1 2020)
|
184
|
-
* OpenGL 4.1
|
180
|
+
* macOS 15.2 / Mac mini (M1 2020)
|
185
181
|
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
182
|
+
$ ruby report_env.rb
|
183
|
+
Version : 4.1 Metal - 89.3
|
184
|
+
Vendor : Apple
|
185
|
+
Renderer : Apple M1
|
186
|
+
Shader : 4.10
|
191
187
|
|
192
188
|
* Arch Linux kernel 4.1.2-2-ARCH, Nvidia Driver, x86_64
|
193
189
|
* NVIDIA GeForce GTS 450
|
@@ -207,6 +203,8 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
207
203
|
<summary>Older versions</summary>
|
208
204
|
|
209
205
|
* Ruby
|
206
|
+
* ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin23]
|
207
|
+
* ruby 3.2.0 (2022-12-25 revision a528908271) [arm64-darwin21]
|
210
208
|
* ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [arm64-darwin20]
|
211
209
|
* ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x64-mingw32]
|
212
210
|
* ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [arm64-darwin20]
|
@@ -237,6 +235,16 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
237
235
|
* ruby 2.0.0p353 (2013-11-22 revision 43784) [x86_64-darwin13.0.0]
|
238
236
|
* ruby 2.0.0p247 (2013-06-27) [i386-mingw32]
|
239
237
|
|
238
|
+
* Windows 10 Home, 64-bit (Version 1909, OS Build 18363.778)
|
239
|
+
* NVIDIA GeForce RTX 2060 SUPER
|
240
|
+
* OpenGL 4.5
|
241
|
+
|
242
|
+
> ruby report_env.rb
|
243
|
+
Version : 4.5.0 NVIDIA 436.30
|
244
|
+
Vendor : NVIDIA Corporation
|
245
|
+
Renderer : GeForce RTX 2060 SUPER/PCIe/SSE2
|
246
|
+
Shader : 4.50 NVIDIA
|
247
|
+
|
240
248
|
* Windows 10 Home, 64-bit (Version 1511, OS Build 10586.164)
|
241
249
|
* NVIDIA GeForce GTX 960
|
242
250
|
* OpenGL 4.5
|
@@ -282,6 +290,16 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
282
290
|
Renderer : Intel Iris OpenGL Engine
|
283
291
|
Shader : 4.10
|
284
292
|
|
293
|
+
* macOS 12.5.1, 64-bit
|
294
|
+
* Mac mini (M1 2020)
|
295
|
+
* OpenGL 4.1
|
296
|
+
|
297
|
+
$ ruby report_env.rb
|
298
|
+
Version : 4.1 Metal - 76.3
|
299
|
+
Vendor : Apple
|
300
|
+
Renderer : Apple M1
|
301
|
+
Shader : 4.10
|
302
|
+
|
285
303
|
</details>
|
286
304
|
|
287
305
|
* You can use any lib/path names by passing as arguments like:
|
@@ -321,7 +339,7 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
321
339
|
* https://github.com/mirichi/dxsdl2r
|
322
340
|
* mittsu - A direct port of THREE.js from JavaScript/WebGL to Ruby/OpenGL
|
323
341
|
* https://rubygems.org/gems/mittsu
|
324
|
-
* https://github.com/
|
342
|
+
* https://github.com/danini-the-panini/mittsu
|
325
343
|
* opencl-bindings - A Ruby binding for OpenCL 1.2
|
326
344
|
* https://rubygems.org/gems/opencl-bindings
|
327
345
|
* https://github.com/vaiorabbit/ruby-opencl
|
@@ -340,7 +358,7 @@ Use GLFW or GLUT for creating windows and OpenGL rendering contexts.
|
|
340
358
|
|
341
359
|
The zlib/libpng License ( http://opensource.org/licenses/Zlib ).
|
342
360
|
|
343
|
-
Copyright (c) 2013-
|
361
|
+
Copyright (c) 2013-2025 vaiorabbit <http://twitter.com/vaiorabbit>
|
344
362
|
|
345
363
|
This software is provided 'as-is', without any express or implied
|
346
364
|
warranty. In no event will the authors be held liable for any damages
|
@@ -501,7 +519,6 @@ https://github.com/vaiorabbit/ruby-opengl
|
|
501
519
|
|
502
520
|
* Fiddle
|
503
521
|
* libffi のラッパーです
|
504
|
-
* Ruby 2.0.0 以降で標準ライブラリになりました
|
505
522
|
* Fiddle のメモリリーク問題 (https://bugs.ruby-lang.org/issues/9599) が修正された Ruby 2.1.2 以降での利用を推奨します
|
506
523
|
|
507
524
|
### サンプル用 ###
|
@@ -520,6 +537,46 @@ GLFW か GLUT を用意してください。ウィンドウやレンダリング
|
|
520
537
|
## テストした環境 ##
|
521
538
|
|
522
539
|
* Ruby
|
540
|
+
* ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [x64-mingw-ucrt]
|
541
|
+
* ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [arm64-darwin24]
|
542
|
+
|
543
|
+
* Windows 11 Pro (Version 24H2, OS Build 26100.2605)
|
544
|
+
|
545
|
+
> ruby report_env.rb
|
546
|
+
Version : 4.5.0 NVIDIA 560.94
|
547
|
+
Vendor : NVIDIA Corporation
|
548
|
+
Renderer : NVIDIA GeForce RTX 4080 Laptop GPU/PCIe/SSE2
|
549
|
+
Shader : 4.50 NVIDIA
|
550
|
+
|
551
|
+
* macOS 15.2 / Mac mini (M1 2020)
|
552
|
+
|
553
|
+
$ ruby report_env.rb
|
554
|
+
Version : 4.1 Metal - 89.3
|
555
|
+
Vendor : Apple
|
556
|
+
Renderer : Apple M1
|
557
|
+
Shader : 4.10
|
558
|
+
|
559
|
+
* Arch Linux kernel 4.1.2-2-ARCH, Nvidia Driver, x86_64
|
560
|
+
* NVIDIA GeForce GTS 450
|
561
|
+
* OpenGL 4.5.0
|
562
|
+
|
563
|
+
$ ruby report_env.rb
|
564
|
+
Version: 4.5.0 NVIDIA 352.21
|
565
|
+
|
566
|
+
* Arch Linux kernel 4.1.4-1-ARCH, Nouveau Driver, x86_64
|
567
|
+
* NVIDIA GeForce GTS 450
|
568
|
+
* OpenGL 3.0
|
569
|
+
|
570
|
+
$ ruby report_env.rb
|
571
|
+
Version: 3.0 Mesa 10.6.3
|
572
|
+
|
573
|
+
<details>
|
574
|
+
<summary>以前のバージョン</summary>
|
575
|
+
|
576
|
+
* Ruby
|
577
|
+
* ruby 3.2.0 (2022-12-25 revision a528908271) [arm64-darwin21]
|
578
|
+
* ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [arm64-darwin20]
|
579
|
+
* ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x64-mingw32]
|
523
580
|
* ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [arm64-darwin20]
|
524
581
|
* ruby 3.0.1p64 (2021-04-05 revision 0fb782ee38) [arm64-darwin20]
|
525
582
|
* ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [x64-mingw32]
|
@@ -572,6 +629,13 @@ GLFW か GLUT を用意してください。ウィンドウやレンダリング
|
|
572
629
|
> ruby report_env.rb
|
573
630
|
4.3.0
|
574
631
|
|
632
|
+
* Windows 7 Home Premium, 64-bit (Service Pack 1)
|
633
|
+
* NVIDIA GeForce GTX 560
|
634
|
+
* OpenGL 4.3
|
635
|
+
|
636
|
+
> ruby report_env.rb
|
637
|
+
4.3.0
|
638
|
+
|
575
639
|
* Mac OS X 10.8.4, 64-bit
|
576
640
|
* NVIDIA GeForce 320M on Mac mini (Mid 2010)
|
577
641
|
* OpenGL 2.1
|
@@ -596,26 +660,17 @@ GLFW か GLUT を用意してください。ウィンドウやレンダリング
|
|
596
660
|
Renderer : Intel Iris OpenGL Engine
|
597
661
|
Shader : 4.10
|
598
662
|
|
599
|
-
*
|
600
|
-
*
|
601
|
-
* OpenGL 4.
|
602
|
-
|
603
|
-
$ ruby report_env.rb
|
604
|
-
Version: 4.5.0 NVIDIA 352.21
|
605
|
-
|
606
|
-
* Arch Linux kernel 4.1.4-1-ARCH, Nouveau Driver, x86_64
|
607
|
-
* NVIDIA GeForce GTS 450
|
608
|
-
* OpenGL 3.0
|
663
|
+
* macOS 12.5.1, 64-bit
|
664
|
+
* Mac mini (M1 2020)
|
665
|
+
* OpenGL 4.1
|
609
666
|
|
610
667
|
$ ruby report_env.rb
|
611
|
-
Version:
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
* GLFW.load_lib( 'libglfw.so', '/usr/lib' )
|
616
|
-
* GLU.load_lib( 'libGLU.so', '/usr/lib' )
|
617
|
-
* GLUT.load_lib( 'libglut.so', '/usr/lib' )
|
668
|
+
Version : 4.1 Metal - 76.3
|
669
|
+
Vendor : Apple
|
670
|
+
Renderer : Apple M1
|
671
|
+
Shader : 4.10
|
618
672
|
|
673
|
+
</details>
|
619
674
|
|
620
675
|
## メモ ##
|
621
676
|
|
data/lib/glfw.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# -*- coding: utf-8 -*-
|
2
|
-
# A GLFW wrapper (for version 3.
|
2
|
+
# A GLFW wrapper (for version 3.4)
|
3
3
|
require 'fiddle/import'
|
4
4
|
|
5
5
|
module GLFW
|
@@ -24,7 +24,6 @@ module GLFW
|
|
24
24
|
rescue
|
25
25
|
file, line = __FILE__, __LINE__+3
|
26
26
|
end
|
27
|
-
args_str="*args"
|
28
27
|
module_eval(<<-EOS, file, line)
|
29
28
|
def #{name}(*args, &block)
|
30
29
|
GLFW_FUNCTIONS_MAP['#{name}'].call(*args,&block)
|
@@ -245,17 +244,21 @@ module GLFW
|
|
245
244
|
GLFW_GAMEPAD_AXIS_RIGHT_TRIGGER = 5 # Available since GLFW 3.3
|
246
245
|
GLFW_GAMEPAD_AXIS_LAST = GLFW_GAMEPAD_AXIS_RIGHT_TRIGGER # Available since GLFW 3.3
|
247
246
|
|
248
|
-
GLFW_NO_ERROR
|
249
|
-
GLFW_NOT_INITIALIZED
|
250
|
-
GLFW_NO_CURRENT_CONTEXT
|
251
|
-
GLFW_INVALID_ENUM
|
252
|
-
GLFW_INVALID_VALUE
|
253
|
-
GLFW_OUT_OF_MEMORY
|
254
|
-
GLFW_API_UNAVAILABLE
|
255
|
-
GLFW_VERSION_UNAVAILABLE
|
256
|
-
GLFW_PLATFORM_ERROR
|
257
|
-
GLFW_FORMAT_UNAVAILABLE
|
258
|
-
GLFW_NO_WINDOW_CONTEXT
|
247
|
+
GLFW_NO_ERROR = 0 # Available since GLFW 3.3
|
248
|
+
GLFW_NOT_INITIALIZED = 0x00010001
|
249
|
+
GLFW_NO_CURRENT_CONTEXT = 0x00010002
|
250
|
+
GLFW_INVALID_ENUM = 0x00010003
|
251
|
+
GLFW_INVALID_VALUE = 0x00010004
|
252
|
+
GLFW_OUT_OF_MEMORY = 0x00010005
|
253
|
+
GLFW_API_UNAVAILABLE = 0x00010006
|
254
|
+
GLFW_VERSION_UNAVAILABLE = 0x00010007
|
255
|
+
GLFW_PLATFORM_ERROR = 0x00010008
|
256
|
+
GLFW_FORMAT_UNAVAILABLE = 0x00010009
|
257
|
+
GLFW_NO_WINDOW_CONTEXT = 0x0001000A # Available since GLFW 3.2
|
258
|
+
GLFW_CURSOR_UNAVAILABLE = 0x0001000B # Available since GLFW 3.4
|
259
|
+
GLFW_FEATURE_UNAVAILABLE = 0x0001000C # Available since GLFW 3.4
|
260
|
+
GLFW_FEATURE_UNIMPLEMENTED = 0x0001000D # Available since GLFW 3.4
|
261
|
+
GLFW_PLATFORM_UNAVAILABLE = 0x0001000E # Available since GLFW 3.4
|
259
262
|
|
260
263
|
GLFW_FOCUSED = 0x00020001
|
261
264
|
GLFW_ICONIFIED = 0x00020002
|
@@ -269,6 +272,9 @@ module GLFW
|
|
269
272
|
GLFW_TRANSPARENT_FRAMEBUFFER = 0x0002000A # Available since GLFW 3.3
|
270
273
|
GLFW_HOVERED = 0x0002000B # Available since GLFW 3.3
|
271
274
|
GLFW_FOCUS_ON_SHOW = 0x0002000C # Available since GLFW 3.3
|
275
|
+
GLFW_MOUSE_PASSTHROUGH = 0x0002000D # Available since GLFW 3.4
|
276
|
+
GLFW_POSITION_X = 0x0002000E # Available since GLFW 3.4
|
277
|
+
GLFW_POSITION_Y = 0x0002000F # Available since GLFW 3.4
|
272
278
|
|
273
279
|
GLFW_RED_BITS = 0x00021001
|
274
280
|
GLFW_GREEN_BITS = 0x00021002
|
@@ -293,12 +299,14 @@ module GLFW
|
|
293
299
|
GLFW_CONTEXT_REVISION = 0x00022004
|
294
300
|
GLFW_CONTEXT_ROBUSTNESS = 0x00022005
|
295
301
|
GLFW_OPENGL_FORWARD_COMPAT = 0x00022006
|
296
|
-
|
302
|
+
GLFW_CONTEXT_DEBUG = 0x00022007 # Renamed from GLFW_OPENGL_DEBUG_CONTEXT since GLFW 3.4
|
303
|
+
GLFW_OPENGL_DEBUG_CONTEXT = GLFW_CONTEXT_DEBUG # Legacy name for compatibility added since GLFW 3.4
|
297
304
|
GLFW_OPENGL_PROFILE = 0x00022008
|
298
305
|
GLFW_CONTEXT_RELEASE_BEHAVIOR = 0x00022009
|
299
306
|
GLFW_CONTEXT_NO_ERROR = 0x0002200A
|
300
307
|
GLFW_CONTEXT_CREATION_API = 0x0002200B # Available since GLFW 3.2
|
301
308
|
GLFW_SCALE_TO_MONITOR = 0x0002200C # Available since GLFW 3.3
|
309
|
+
GLFW_SCALE_FRAMEBUFFER = 0x0002200D # Available since GLFW 3.4
|
302
310
|
|
303
311
|
GLFW_COCOA_RETINA_FRAMEBUFFER = 0x00023001 # Available since GLFW 3.3
|
304
312
|
GLFW_COCOA_FRAME_NAME = 0x00023002 # Available since GLFW 3.3
|
@@ -306,6 +314,9 @@ module GLFW
|
|
306
314
|
|
307
315
|
GLFW_X11_CLASS_NAME = 0x00024001 # Available since GLFW 3.3
|
308
316
|
GLFW_X11_INSTANCE_NAME = 0x00024002 # Available since GLFW 3.3
|
317
|
+
GLFW_WIN32_KEYBOARD_MENU = 0x00025001 # Available since GLFW 3.4
|
318
|
+
GLFW_WIN32_SHOWDEFAULT = 0x00025002 # Available since GLFW 3.4
|
319
|
+
GLFW_WAYLAND_APP_ID = 0x00026001 # Available since GLFW 3.4
|
309
320
|
|
310
321
|
GLFW_NO_API = 0 # Available since GLFW 3.2
|
311
322
|
GLFW_OPENGL_API = 0x00030001
|
@@ -328,6 +339,7 @@ module GLFW
|
|
328
339
|
GLFW_CURSOR_NORMAL = 0x00034001
|
329
340
|
GLFW_CURSOR_HIDDEN = 0x00034002
|
330
341
|
GLFW_CURSOR_DISABLED = 0x00034003
|
342
|
+
GLFW_CURSOR_CAPTURED = 0x00034004 # Available since GLFW 3.4
|
331
343
|
|
332
344
|
GLFW_ANY_RELEASE_BEHAVIOR = 0
|
333
345
|
GLFW_RELEASE_BEHAVIOR_FLUSH = 0x00035001
|
@@ -337,21 +349,56 @@ module GLFW
|
|
337
349
|
GLFW_EGL_CONTEXT_API = 0x00036002 # Available since GLFW 3.2
|
338
350
|
GLFW_OSMESA_CONTEXT_API = 0x00036003 # Available since GLFW 3.3
|
339
351
|
|
352
|
+
GLFW_ANGLE_PLATFORM_TYPE_NONE = 0x00037001 # Available since GLFW 3.4
|
353
|
+
GLFW_ANGLE_PLATFORM_TYPE_OPENGL = 0x00037002 # Available since GLFW 3.4
|
354
|
+
GLFW_ANGLE_PLATFORM_TYPE_OPENGLES = 0x00037003 # Available since GLFW 3.4
|
355
|
+
GLFW_ANGLE_PLATFORM_TYPE_D3D9 = 0x00037004 # Available since GLFW 3.4
|
356
|
+
GLFW_ANGLE_PLATFORM_TYPE_D3D11 = 0x00037005 # Available since GLFW 3.4
|
357
|
+
GLFW_ANGLE_PLATFORM_TYPE_VULKAN = 0x00037007 # Available since GLFW 3.4
|
358
|
+
GLFW_ANGLE_PLATFORM_TYPE_METAL = 0x00037008 # Available since GLFW 3.4
|
359
|
+
|
360
|
+
GLFW_WAYLAND_PREFER_LIBDECOR = 0x00038001 # Available since GLFW 3.3.9
|
361
|
+
GLFW_WAYLAND_DISABLE_LIBDECOR = 0x00038002 # Available since GLFW 3.3.9
|
362
|
+
|
363
|
+
GLFW_ANY_POSITION = 0x80000000 # Available since GLFW 3.4
|
364
|
+
|
340
365
|
GLFW_ARROW_CURSOR = 0x00036001
|
341
366
|
GLFW_IBEAM_CURSOR = 0x00036002
|
342
367
|
GLFW_CROSSHAIR_CURSOR = 0x00036003
|
343
|
-
|
344
|
-
|
345
|
-
|
368
|
+
GLFW_POINTING_HAND_CURSOR = 0x00036004 # Renamed from GLFW_HAND_CURSOR since GLFW 3.4
|
369
|
+
GLFW_RESIZE_EW_CURSOR = 0x00036005 # Renamed from GLFW_HRESIZE_CURSOR since GLFW 3.4
|
370
|
+
GLFW_RESIZE_NS_CURSOR = 0x00036006 # Renamed from GLFW_VRESIZE_CURSOR since GLFW 3.4
|
371
|
+
GLFW_RESIZE_NWSE_CURSOR = 0x00036007 # Available since GLFW 3.4
|
372
|
+
GLFW_RESIZE_NESW_CURSOR = 0x00036008 # Available since GLFW 3.4
|
373
|
+
GLFW_RESIZE_ALL_CURSOR = 0x00036009 # Available since GLFW 3.4
|
374
|
+
GLFW_NOT_ALLOWED_CURSOR = 0x0003600A # Available since GLFW 3.4
|
375
|
+
|
376
|
+
GLFW_HRESIZE_CURSOR = GLFW_RESIZE_EW_CURSOR # Legacy name for compatibility added since GLFW 3.4
|
377
|
+
GLFW_VRESIZE_CURSOR = GLFW_RESIZE_NS_CURSOR # Legacy name for compatibility added since GLFW 3.4
|
378
|
+
GLFW_HAND_CURSOR = GLFW_POINTING_HAND_CURSOR # Legacy name for compatibility added since GLFW 3.4
|
346
379
|
|
347
380
|
GLFW_CONNECTED = 0x00040001
|
348
381
|
GLFW_DISCONNECTED = 0x00040002
|
349
382
|
|
350
383
|
GLFW_JOYSTICK_HAT_BUTTONS = 0x00050001 # Available since GLFW 3.3
|
384
|
+
GLFW_ANGLE_PLATFORM_TYPE = 0x00050002 # Available since GLFW 3.4
|
385
|
+
GLFW_PLATFORM = 0x00050003 # Available since GLFW 3.4
|
386
|
+
|
351
387
|
|
352
388
|
GLFW_COCOA_CHDIR_RESOURCES = 0x00051001 # Available since GLFW 3.3
|
353
389
|
GLFW_COCOA_MENUBAR = 0x00051002 # Available since GLFW 3.3
|
354
390
|
|
391
|
+
GLFW_X11_XCB_VULKAN_SURFACE = 0x00052001 # Available since GLFW 3.4
|
392
|
+
|
393
|
+
GLFW_WAYLAND_LIBDECOR = 0x00053001 # Available since GLFW 3.3.9
|
394
|
+
|
395
|
+
GLFW_ANY_PLATFORM = 0x00060000 # Available since GLFW 3.4
|
396
|
+
GLFW_PLATFORM_WIN32 = 0x00060001 # Available since GLFW 3.4
|
397
|
+
GLFW_PLATFORM_COCOA = 0x00060002 # Available since GLFW 3.4
|
398
|
+
GLFW_PLATFORM_WAYLAND = 0x00060003 # Available since GLFW 3.4
|
399
|
+
GLFW_PLATFORM_X11 = 0x00060004 # Available since GLFW 3.4
|
400
|
+
GLFW_PLATFORM_NULL = 0x00060005 # Available since GLFW 3.4
|
401
|
+
|
355
402
|
GLFW_DONT_CARE = -1
|
356
403
|
|
357
404
|
# typedefs
|
@@ -464,6 +511,10 @@ module GLFW
|
|
464
511
|
return self.create_callback_closure( sym, proc, &blk )
|
465
512
|
end
|
466
513
|
|
514
|
+
# NOTE : Memory allocation callbacks addin in GLFW 3.4
|
515
|
+
# (GLFWallocatefun, GLFWreallocatefun, GLFWdeallocatefun and struct GLFWallocator)
|
516
|
+
# will not be supported in this bindings.
|
517
|
+
|
467
518
|
# struct
|
468
519
|
GLFWvidmode = struct(["int width",
|
469
520
|
"int height",
|
@@ -522,6 +573,8 @@ module GLFW
|
|
522
573
|
'const char* glfwGetVersionString()',
|
523
574
|
'int glfwGetError(const char**)', # Available since GLFW 3.3
|
524
575
|
'void* glfwSetErrorCallback(void*)',
|
576
|
+
'int glfwGetPlatform()', # Available since GLFW 3.4
|
577
|
+
'int glfwPlatformSupported(int)', # Available since GLFW 3.4
|
525
578
|
'void** glfwGetMonitors(int*)',
|
526
579
|
'void* glfwGetPrimaryMonitor()',
|
527
580
|
'void glfwGetMonitorPos(void*, int*, int*)',
|
@@ -544,6 +597,7 @@ module GLFW
|
|
544
597
|
'void glfwDestroyWindow(void*)', # Available since GLFW 3.0
|
545
598
|
'int glfwWindowShouldClose(void*)', # Available since GLFW 3.0
|
546
599
|
'void glfwSetWindowShouldClose(void* window, int)', # Available since GLFW 3.0
|
600
|
+
'const char* glfwGetWindowTitle(void*)', # Available since GLFW 3.4
|
547
601
|
'void glfwSetWindowTitle(void*, const char*)',
|
548
602
|
'void glfwSetWindowIcon(void*, int, void*)', # Available since GLFW 3.2
|
549
603
|
'void glfwGetWindowPos(void*, int*, int*)', # Available since GLFW 3.0
|
@@ -648,6 +702,7 @@ module GLFW
|
|
648
702
|
when :OPENGL_PLATFORM_MACOSX
|
649
703
|
@@lib_signature << 'unsigned int glfwGetCocoaMonitor(void*)'
|
650
704
|
@@lib_signature << 'void* glfwGetCocoaWindow(void*)'
|
705
|
+
@@lib_signature << 'void* glfwGetCocoaView(void*)'
|
651
706
|
@@lib_signature << 'void* glfwGetNSGLContext(void*)'
|
652
707
|
when :OPENGL_PLATFORM_LINUX
|
653
708
|
@@lib_signature << 'void* glfwGetX11Display()'
|
@@ -687,7 +742,7 @@ end
|
|
687
742
|
|
688
743
|
=begin
|
689
744
|
Ruby-OpenGL : Yet another OpenGL wrapper for Ruby (and wrapper code generator)
|
690
|
-
Copyright (c) 2013-
|
745
|
+
Copyright (c) 2013-2025 vaiorabbit <http://twitter.com/vaiorabbit>
|
691
746
|
|
692
747
|
This software is provided 'as-is', without any express or implied
|
693
748
|
warranty. In no event will the authors be held liable for any damages
|